Pretty-print AST: handle instanceof with record pattern

This commit is contained in:
Chris Smowton
2023-11-02 13:48:34 +00:00
parent f037030c26
commit 5b734fe937

View File

@@ -385,7 +385,12 @@ private class PpInstanceOfExpr extends PpAst, InstanceOfExpr {
or
i = 3 and result = " " and this.isPattern()
or
i = 4 and result = this.getLocalVariableDeclExpr().getName()
i = 4 and
(
result = this.getPattern().asBindingPattern().getName()
or
result = this.getPattern().asRecordPattern().toString()
)
}
override PpAst getChild(int i) {