Exakat\Analyzer\Structures\ConstantConditions::analyze PHP Method

analyze() public method

public analyze ( )
    public function analyze()
    {
        $this->atomIs('While')->outIs('CONDITION')->is('constant', true)->back('first');
        $this->prepareQuery();
        $this->atomIs('Dowhile')->outIs('CONDITION')->is('constant', true)->back('first');
        $this->prepareQuery();
        $this->atomIs('Ifthen')->outIs('CONDITION')->is('constant', true)->back('first');
        $this->prepareQuery();
        $this->atomIs('Ternary')->outIs('CONDITION')->is('constant', true)->back('first');
        $this->prepareQuery();
        $this->atomIs('For')->outIs(array('FINAL', 'INCREMENT'))->is('constant', true)->back('first');
        $this->prepareQuery();
        /*
            One of the variable inside the condition should be modified at some point : in the condition, or in the loop.
        
            Function calls are kept, but they should be characterized as non-determinist
            (calling with the same arguments may yield different result, such as random or fread)
        */
    }
ConstantConditions