PhpSandbox\ValidatorVisitor::isMagicConst PHP Method

isMagicConst() protected method

Test the current PhpParser_Node node to see if it is a magic constant, and return the name if it is and null if it is not
protected isMagicConst ( PhpParser\Node $node ) : string | null
$node PhpParser\Node The sandboxed $node to test
return string | null Return string name of node, or null if it is not a magic constant
    protected function isMagicConst(Node $node)
    {
        return $node instanceof Node\Scalar\MagicConst ? $node->getName() : null;
    }