File tree Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -711,15 +711,16 @@ private function getNodeKey(Expr $node): string
711
711
{
712
712
$ key = $ this ->exprPrinter ->printExpr ($ node );
713
713
714
+ $ attributes = $ node ->getAttributes ();
714
715
if (
715
716
$ node instanceof Node \FunctionLike
716
- && $ node -> hasAttribute ( ArrayMapArgVisitor::ATTRIBUTE_NAME )
717
- && $ node -> hasAttribute ( 'startFilePos ' )
717
+ && (( $ attributes [ ArrayMapArgVisitor::ATTRIBUTE_NAME ] ?? null ) !== null )
718
+ && (( $ attributes [ 'startFilePos ' ] ?? null ) !== null )
718
719
) {
719
- $ key .= '/* ' . $ node -> getAttribute ( 'startFilePos ' ) . '*/ ' ;
720
+ $ key .= '/* ' . $ attributes [ 'startFilePos ' ] . '*/ ' ;
720
721
}
721
722
722
- if ($ node -> getAttribute ( self ::KEEP_VOID_ATTRIBUTE_NAME ) === true ) {
723
+ if (( $ attributes [ self ::KEEP_VOID_ATTRIBUTE_NAME ] ?? null ) === true ) {
723
724
$ key .= '/* ' . self ::KEEP_VOID_ATTRIBUTE_NAME . '*/ ' ;
724
725
}
725
726
You can’t perform that action at this time.
0 commit comments