protected function isValidPropertyNode(ASTNode $node = null)
{
if ($node === null) {
return false;
}
$parent = $node->getParent();
while (!$parent->isInstanceOf('PropertyPostfix')) {
if ($parent->isInstanceOf('CompoundVariable')) {
return false;
}
$parent = $parent->getParent();
if (is_null($parent)) {
return false;
}
}
return true;
}