Library/Operators/BaseOperator.php
public function getExpectedNonLiteral(CompilationContext $compilationContext, $expression, $init = true)
    {
        $isExpecting = $this->expecting;
        $symbolVariable = $this->expectingVariable;

        if ($isExpecting) {
            if (\is_object($symbolVariable)) {
                if ('variable' == $symbolVariable->getType() && !$symbolVariable->isLocalOnly()) {
                    if (!$init) {
                        return $symbolVariable;
                    }
                    $symbolVariable->initVariant($compilationContext);
                } else {
                    $symbolVariable = $compilationContext->symbolTable->getTempVariableForWrite('variable', $compilationContext, $expression);
                }
            } else {
                $symbolVariable = $compilationContext->symbolTable->getTempVariableForWrite('variable', $compilationContext, $expression);
            }
        }

        return $symbolVariable;
    }
public function getExpectedNonLiteral(CompilationContext $compilationContext, $expression, $init = true)
    {
        $isExpecting = $this->expecting;
        $symbolVariable = $this->expectingVariable;

        if ($isExpecting) {
            if (\is_object($symbolVariable)) {
                if ('variable' == $symbolVariable->getType() && !$symbolVariable->isLocalOnly()) {
                    if (!$init) {
                        return $symbolVariable;
                    }
                    $symbolVariable->initVariant($compilationContext);
                } else {
                    $symbolVariable = $compilationContext->symbolTable->getTempVariableForWrite('variable', $compilationContext, $expression);
                }
            } else {
                $symbolVariable = $compilationContext->symbolTable->getTempVariableForWrite('variable', $compilationContext, $expression);
            }
        }

        return $symbolVariable;
    }
public function getExpectedNonLiteral ( CompilationContext $ compilationContext , $ expression , $ init = true ) { $ isExpecting = $ this -> expecting ; $ symbolVariable = $ this -> expectingVariable ; if ( $ isExpecting ) { if ( \ is_object ( $ symbolVariable ) ) { if ( 'variable' == $ symbolVariable -> getType ( ) && ! $ symbolVariable -> isLocalOnly ( ) ) { if ( ! $ init ) { return $ symbolVariable ; } $ symbolVariable -> initVariant ( $ compilationContext ) ; } else { $ symbolVariable = $ compilationContext -> symbolTable -> getTempVariableForWrite ( 'variable' , $ compilationContext , $ expression ) ; } } else { $ symbolVariable = $ compilationContext -> symbolTable -> getTempVariableForWrite ( 'variable' , $ compilationContext , $ expression ) ; } } return $ symbolVariable ; }
Returns the expected variable for assignment or creates a temporary variable to
store the result. This method returns a variable that is always stored in the heap.

@param CompilationContext $compilationContext
@param array              $expression
@param bool               $init

@return Variable
Returns the expected variable for assignment or creates a temporary variable to store the result . This method returns a variable that is always stored in the heap .