Open
Description
Prettier 3.0.3
PHP Plugin 0.22.2
Input:
$unit = $unitNode?->print($context);
Output:
Error: test.php: SyntaxError: Parse Error : syntax error, unexpected 'print' (T_PRINT) on line 549
Error: 549 | $unit = $unitNode?->print($context);
Expected behavior:
It seems that print
is the culprit. I would expect that I can call a print
method the same way any other method with the conditional chaining before. This code seems to work in contrast:
$unit = $unitNode?->test($context);
Metadata
Metadata
Assignees
Labels
No labels