ircmaxell/php-cfg

No name in Stmt_Property operand

quanyang opened this issue · 1 comments

Example Code:

Class Test{
    public $a;
    private $b = 2;
    static protected $c = 3;
    Function a() {
    }
}

Truncated Output:

Block#2
    Stmt_Property
        defaultVar: LITERAL(1)
        defaultBlock: Block#7
    Stmt_Property
        defaultVar: LITERAL(2)
        defaultBlock: Block#8
    Stmt_Property
        defaultVar: LITERAL(3)
        defaultBlock: Block#9
    Stmt_ClassMethod<a>

Same with issue #16

nikic commented

Fixed with 5333ef9.

As this was consequently missing everywhere Anthony probably didn't intend getVariableNames() to be used like this, but well...