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 @@ -710,15 +710,16 @@ private function getNodeKey(Expr $node): string
710710 {
711711 $ key = $ this ->exprPrinter ->printExpr ($ node );
712712
713+ $ attributes = $ node ->getAttributes ();
713714 if (
714715 $ node instanceof Node \FunctionLike
715- && $ node -> hasAttribute ( ArrayMapArgVisitor::ATTRIBUTE_NAME )
716- && $ node -> hasAttribute ( 'startFilePos ' )
716+ && (( $ attributes [ ArrayMapArgVisitor::ATTRIBUTE_NAME ] ?? null ) !== null )
717+ && (( $ attributes [ 'startFilePos ' ] ?? null ) !== null )
717718 ) {
718- $ key .= '/* ' . $ node -> getAttribute ( 'startFilePos ' ) . '*/ ' ;
719+ $ key .= '/* ' . $ attributes [ 'startFilePos ' ] . '*/ ' ;
719720 }
720721
721- if ($ node -> getAttribute ( self ::KEEP_VOID_ATTRIBUTE_NAME ) === true ) {
722+ if (( $ attributes [ self ::KEEP_VOID_ATTRIBUTE_NAME ] ?? null ) === true ) {
722723 $ key .= '/* ' . self ::KEEP_VOID_ATTRIBUTE_NAME . '*/ ' ;
723724 }
724725
You can’t perform that action at this time.
0 commit comments