function PrettyPrinterAbstract::staticDereferenceLhsRequiresParens
Determines whether the LHS of a static operation must be wrapped in parentheses.
Parameters
Node $node LHS of dereferencing operation:
Return value
bool Whether parentheses are required
3 calls to PrettyPrinterAbstract::staticDereferenceLhsRequiresParens()
- PrettyPrinterAbstract::dereferenceLhsRequiresParens in vendor/
nikic/ php-parser/ lib/ PhpParser/ PrettyPrinterAbstract.php - Determines whether the LHS of an array/object operation must be wrapped in parentheses.
- PrettyPrinterAbstract::pFixup in vendor/
nikic/ php-parser/ lib/ PhpParser/ PrettyPrinterAbstract.php - Print node with fixups.
- Standard::pStaticDereferenceLhs in vendor/
nikic/ php-parser/ lib/ PhpParser/ PrettyPrinter/ Standard.php
File
-
vendor/
nikic/ php-parser/ lib/ PhpParser/ PrettyPrinterAbstract.php, line 1175
Class
Namespace
PhpParserCode
protected function staticDereferenceLhsRequiresParens(Node $node) : bool {
return !($node instanceof Expr\Variable || $node instanceof Node\Name || $node instanceof Expr\ArrayDimFetch || $node instanceof Expr\PropertyFetch || $node instanceof Expr\NullsafePropertyFetch || $node instanceof Expr\StaticPropertyFetch || $node instanceof Expr\FuncCall || $node instanceof Expr\MethodCall || $node instanceof Expr\NullsafeMethodCall || $node instanceof Expr\StaticCall || $node instanceof Expr\Array_ || $node instanceof Scalar\String_ || $node instanceof Expr\ClassConstFetch);
}