Haanga_Compiler::set_context PHP Method

set_context() public method

These two functions are useful to detect if a variable separated by dot (foo.bar) is an array or object. To avoid overhead we decide it at compile time, rather than ask over and over at rendering time. foo.bar: + If foo exists at compile time, and it is an array, it would be foo['bar'] otherwise it'd be foo->bar. + If foo don't exists at compile time, it would be foo->bar if the compiler option dot_as_object is TRUE (by default) otherwise it'd be foo['bar']
Author: crodas @author gallir (ideas)
public set_context ( $varname, $value )
    function set_context($varname, $value)
    {
        $this->context[$varname] = $value;
    }