mirror of
https://github.com/github/codeql.git
synced 2026-04-25 00:35:20 +02:00
Basic extraction of record patterns
This commit is contained in:
@@ -2541,3 +2541,10 @@ class NotNullExpr extends UnaryExpr, @notnullexpr {
|
||||
|
||||
override string getAPrimaryQlClass() { result = "NotNullExpr" }
|
||||
}
|
||||
|
||||
/** A record pattern expr, as in `if (x instanceof SomeRecord(int field))`. */
|
||||
class RecordPatternExpr extends Expr, @recordpatternexpr {
|
||||
override string toString() { result = this.getType().toString() + "(...)" }
|
||||
|
||||
override string getAPrimaryQlClass() { result = "RecordPatternExpr" }
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user