Skip to content

Commit 17ef056

Browse files
authored
QL: Merge pull request #30 from github/qldoc-nodes
Add AST nodes for QLDoc
2 parents 63c7b21 + 855683e commit 17ef056

5 files changed

Lines changed: 142 additions & 55 deletions

File tree

ql/src/codeql_ql/ast/Ast.qll

Lines changed: 90 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,9 @@ class AstNode extends TAstNode {
5757
*/
5858
string getAPrimaryQlClass() { result = "???" }
5959

60+
/** Gets the QLDoc comment for this AST node, if any. */
61+
QLDoc getQLDoc() { none() }
62+
6063
/**
6164
* Gets the predicate that contains this AST node.
6265
*/
@@ -77,13 +80,56 @@ class TopLevel extends TTopLevel, AstNode {
7780
* Gets a member from contained in this top-level module.
7881
* Includes private members.
7982
*/
80-
ModuleMember getAMember() { toGenerated(result) = file.getChild(_).getChild(_) }
83+
ModuleMember getAMember() { result = getMember(_) }
84+
85+
ModuleMember getMember(int i) { toGenerated(result) = file.getChild(i).getChild(_) }
86+
87+
/** Gets a top-level import in this module. */
88+
Import getAnImport() { result = this.getAMember() }
89+
90+
/** Gets a top-level class in this module. */
91+
Class getAClass() { result = this.getAMember() }
92+
93+
/** Gets a top-level predicate in this module. */
94+
ClasslessPredicate getAPredicate() { result = this.getAMember() }
95+
96+
/** Gets a module defined at the top-level of this module. */
97+
Module getAModule() { result = this.getAMember() }
98+
99+
/** Gets a `newtype` defined at the top-level of this module. */
100+
NewType getANewType() { result = this.getAMember() }
81101

82102
override ModuleMember getAChild(string pred) {
83-
pred = directMember("getAMember") and result = this.getAMember()
103+
pred = directMember("getQLDoc") and result = this.getQLDoc()
104+
or
105+
pred = directMember("getAnImport") and result = this.getAnImport()
106+
or
107+
pred = directMember("getAClass") and result = this.getAClass()
108+
or
109+
pred = directMember("getAPredicate") and result = this.getAPredicate()
110+
or
111+
pred = directMember("getAModule") and result = this.getAModule()
112+
or
113+
pred = directMember("getANewType") and result = this.getANewType()
114+
}
115+
116+
QLDoc getQLDocFor(ModuleMember m) {
117+
exists(int i | i > 0 and result = this.getMember(i) and m = this.getMember(i + 1))
84118
}
85119

86120
override string getAPrimaryQlClass() { result = "TopLevel" }
121+
122+
override QLDoc getQLDoc() { toGenerated(result) = file.getChild(0).getChild(0) }
123+
}
124+
125+
class QLDoc extends TQLDoc, AstNode {
126+
Generated::Qldoc qldoc;
127+
128+
QLDoc() { this = TQLDoc(qldoc) }
129+
130+
string getContents() { result = qldoc.getValue() }
131+
132+
override string getAPrimaryQlClass() { result = "QLDoc" }
87133
}
88134

89135
/**
@@ -135,7 +181,7 @@ class Select extends TSelect, AstNode {
135181
* A QL predicate.
136182
* Either a classless predicate, a class predicate, or a characteristic predicate.
137183
*/
138-
class Predicate extends TPredicate, AstNode {
184+
class Predicate extends TPredicate, AstNode, Declaration {
139185
/**
140186
* Gets the body of the predicate.
141187
*/
@@ -144,7 +190,7 @@ class Predicate extends TPredicate, AstNode {
144190
/**
145191
* Gets the name of the predicate.
146192
*/
147-
string getName() { none() }
193+
override string getName() { none() }
148194

149195
/**
150196
* Gets the `i`th parameter of the predicate.
@@ -389,7 +435,7 @@ class VarDef extends TVarDef, AstNode {
389435
/**
390436
* A variable declaration, with a type and a name.
391437
*/
392-
class VarDecl extends TVarDecl, VarDef {
438+
class VarDecl extends TVarDecl, VarDef, Declaration {
393439
Generated::VarDecl var;
394440

395441
VarDecl() { this = TVarDecl(var) }
@@ -428,6 +474,8 @@ class VarDecl extends TVarDecl, VarDef {
428474
or
429475
pred = directMember("getTypeExpr") and result = this.getTypeExpr()
430476
}
477+
478+
override string toString() { result = this.getName() }
431479
}
432480

433481
/**
@@ -501,6 +549,14 @@ class Module extends TModule, ModuleDeclaration {
501549
toGenerated(result) = mod.getChild(_).(Generated::ModuleMember).getChild(_)
502550
}
503551

552+
AstNode getMember(int i) {
553+
toGenerated(result) = mod.getChild(i).(Generated::ModuleMember).getChild(_)
554+
}
555+
556+
QLDoc getQLDocFor(AstNode m) {
557+
exists(int i | result = this.getMember(i) and m = this.getMember(i + 1))
558+
}
559+
504560
/** Gets the module expression that this module is an alias for, if any. */
505561
ModuleExpr getAlias() {
506562
toGenerated(result) = mod.getAFieldOrChild().(Generated::ModuleAliasBody).getChild()
@@ -528,7 +584,21 @@ class Declaration extends TDeclaration, AstNode {
528584
/** Gets the name of this declaration. */
529585
string getName() { none() }
530586

531-
final override string toString() { result = this.getName() }
587+
override string toString() { result = this.getAPrimaryQlClass() + " " + this.getName() }
588+
589+
override QLDoc getQLDoc() {
590+
result = any(TopLevel m).getQLDocFor(this)
591+
or
592+
result = any(Module m).getQLDocFor(this)
593+
or
594+
result = any(Class c).getQLDocFor(this)
595+
}
596+
597+
override AstNode getAChild(string pred) {
598+
result = super.getAChild(pred)
599+
or
600+
pred = directMember("getQLDoc") and result = this.getQLDoc()
601+
}
532602
}
533603

534604
/** An entity that can be declared in a module. */
@@ -556,6 +626,16 @@ class Class extends TClass, TypeDeclaration, ModuleDeclaration {
556626
toGenerated(result) = cls.getChild(_).(Generated::ClassMember).getChild(_)
557627
}
558628

629+
AstNode getMember(int i) {
630+
toGenerated(result) = cls.getChild(i).(Generated::ClassMember).getChild(_) or
631+
toGenerated(result) =
632+
cls.getChild(i).(Generated::ClassMember).getChild(_).(Generated::Field).getChild()
633+
}
634+
635+
QLDoc getQLDocFor(AstNode m) {
636+
exists(int i | result = this.getMember(i) and m = this.getMember(i + 1))
637+
}
638+
559639
/**
560640
* Gets a predicate in this class.
561641
*/
@@ -667,6 +747,8 @@ class NewTypeBranch extends TNewTypeBranch, TypeDeclaration {
667747
/** Gets the body of this branch. */
668748
Formula getBody() { toGenerated(result) = branch.getChild(_).(Generated::Body).getChild() }
669749

750+
override QLDoc getQLDoc() { toGenerated(result) = branch.getChild(_) }
751+
670752
NewType getNewType() { result.getABranch() = this }
671753

672754
override AstNode getAChild(string pred) {
@@ -675,6 +757,8 @@ class NewTypeBranch extends TNewTypeBranch, TypeDeclaration {
675757
pred = directMember("getBody") and result = this.getBody()
676758
or
677759
exists(int i | pred = indexedMember("getField", i) and result = this.getField(i))
760+
or
761+
pred = directMember("getQLDoc") and result = this.getQLDoc()
678762
}
679763
}
680764

ql/src/codeql_ql/ast/internal/AstNodes.qll

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ import TreeSitter
44
cached
55
newtype TAstNode =
66
TTopLevel(Generated::Ql file) or
7+
TQLDoc(Generated::Qldoc qldoc) or
78
TClasslessPredicate(Generated::ClasslessPredicate pred) or
89
TVarDecl(Generated::VarDecl decl) or
910
TClass(Generated::Dataclass dc) or
@@ -118,6 +119,8 @@ Generated::AstNode toGenerated(AST::AstNode n) {
118119
or
119120
n = TTopLevel(result)
120121
or
122+
n = TQLDoc(result)
123+
or
121124
n = TClasslessPredicate(result)
122125
or
123126
n = TVarDecl(result)
@@ -161,9 +164,9 @@ Generated::AstNode toGenerated(AST::AstNode n) {
161164

162165
class TPredicate = TCharPred or TClasslessPredicate or TClassPredicate;
163166

164-
class TModuleMember = TModuleDeclaration or TImport or TSelect;
167+
class TModuleMember = TModuleDeclaration or TImport or TSelect or TQLDoc;
165168

166-
class TDeclaration = TTypeDeclaration or TModuleDeclaration;
169+
class TDeclaration = TTypeDeclaration or TModuleDeclaration or TPredicate or TVarDecl;
167170

168171
class TTypeDeclaration = TClass or TNewType or TNewTypeBranch;
169172

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
| Foo.qll:5:26:5:30 | PredicateCall | Foo.qll:3:1:3:26 | foo |
2-
| Foo.qll:10:21:10:25 | PredicateCall | Foo.qll:8:3:8:28 | ClassPredicate |
3-
| Foo.qll:14:30:14:40 | MemberCall | Foo.qll:10:3:10:27 | ClassPredicate |
4-
| Foo.qll:17:27:17:42 | MemberCall | Foo.qll:8:3:8:28 | ClassPredicate |
5-
| Foo.qll:29:5:29:16 | PredicateCall | Foo.qll:20:3:20:54 | myThing2 |
6-
| Foo.qll:29:5:29:16 | PredicateCall | Foo.qll:26:3:26:32 | alias2 |
7-
| Foo.qll:31:5:31:12 | PredicateCall | Foo.qll:22:3:22:32 | myThing0 |
8-
| Foo.qll:31:5:31:12 | PredicateCall | Foo.qll:24:3:24:32 | alias0 |
1+
| Foo.qll:5:26:5:30 | PredicateCall | Foo.qll:3:1:3:26 | ClasslessPredicate foo |
2+
| Foo.qll:10:21:10:25 | PredicateCall | Foo.qll:8:3:8:28 | ClassPredicate bar |
3+
| Foo.qll:14:30:14:40 | MemberCall | Foo.qll:10:3:10:27 | ClassPredicate baz |
4+
| Foo.qll:17:27:17:42 | MemberCall | Foo.qll:8:3:8:28 | ClassPredicate bar |
5+
| Foo.qll:29:5:29:16 | PredicateCall | Foo.qll:20:3:20:54 | ClasslessPredicate myThing2 |
6+
| Foo.qll:29:5:29:16 | PredicateCall | Foo.qll:26:3:26:32 | ClasslessPredicate alias2 |
7+
| Foo.qll:31:5:31:12 | PredicateCall | Foo.qll:22:3:22:32 | ClasslessPredicate myThing0 |
8+
| Foo.qll:31:5:31:12 | PredicateCall | Foo.qll:24:3:24:32 | ClasslessPredicate alias0 |

ql/test/printAst/printAst.expected

Lines changed: 38 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,12 @@ nodes
33
| Foo.qll:1:1:1:17 | Import | semmle.order | 1 |
44
| Foo.qll:1:1:27:2 | TopLevel | semmle.label | [TopLevel] TopLevel |
55
| Foo.qll:1:1:27:2 | TopLevel | semmle.order | 1 |
6-
| Foo.qll:3:1:7:1 | Foo | semmle.label | [Class] Foo |
7-
| Foo.qll:3:1:7:1 | Foo | semmle.order | 3 |
6+
| Foo.qll:3:1:7:1 | Class Foo | semmle.label | [Class] Class Foo |
7+
| Foo.qll:3:1:7:1 | Class Foo | semmle.order | 3 |
88
| Foo.qll:3:19:3:22 | TypeExpr | semmle.label | [TypeExpr] TypeExpr |
99
| Foo.qll:3:19:3:22 | TypeExpr | semmle.order | 4 |
10-
| Foo.qll:4:3:4:17 | CharPred | semmle.label | [CharPred] CharPred |
11-
| Foo.qll:4:3:4:17 | CharPred | semmle.order | 5 |
10+
| Foo.qll:4:3:4:17 | CharPred Foo | semmle.label | [CharPred] CharPred Foo |
11+
| Foo.qll:4:3:4:17 | CharPred Foo | semmle.order | 5 |
1212
| Foo.qll:4:11:4:11 | Integer | semmle.label | [Integer] Integer |
1313
| Foo.qll:4:11:4:11 | Integer | semmle.order | 6 |
1414
| Foo.qll:4:11:4:15 | ComparisonFormula | semmle.label | [ComparisonFormula] ComparisonFormula |
@@ -19,8 +19,8 @@ nodes
1919
| Foo.qll:4:15:4:15 | Integer | semmle.order | 9 |
2020
| Foo.qll:6:3:6:8 | TypeExpr | semmle.label | [TypeExpr] TypeExpr |
2121
| Foo.qll:6:3:6:8 | TypeExpr | semmle.order | 10 |
22-
| Foo.qll:6:3:6:38 | ClassPredicate | semmle.label | [ClassPredicate] ClassPredicate |
23-
| Foo.qll:6:3:6:38 | ClassPredicate | semmle.order | 10 |
22+
| Foo.qll:6:3:6:38 | ClassPredicate toString | semmle.label | [ClassPredicate] ClassPredicate toString |
23+
| Foo.qll:6:3:6:38 | ClassPredicate toString | semmle.order | 10 |
2424
| Foo.qll:6:23:6:28 | result | semmle.label | [ResultAccess] result |
2525
| Foo.qll:6:23:6:28 | result | semmle.order | 12 |
2626
| Foo.qll:6:23:6:36 | ComparisonFormula | semmle.label | [ComparisonFormula] ComparisonFormula |
@@ -29,8 +29,8 @@ nodes
2929
| Foo.qll:6:30:6:30 | ComparisonOp | semmle.order | 14 |
3030
| Foo.qll:6:32:6:36 | String | semmle.label | [String] String |
3131
| Foo.qll:6:32:6:36 | String | semmle.order | 15 |
32-
| Foo.qll:9:7:11:1 | foo | semmle.label | [ClasslessPredicate] foo |
33-
| Foo.qll:9:7:11:1 | foo | semmle.order | 16 |
32+
| Foo.qll:9:7:11:1 | ClasslessPredicate foo | semmle.label | [ClasslessPredicate] ClasslessPredicate foo |
33+
| Foo.qll:9:7:11:1 | ClasslessPredicate foo | semmle.order | 16 |
3434
| Foo.qll:9:21:9:23 | TypeExpr | semmle.label | [TypeExpr] TypeExpr |
3535
| Foo.qll:9:21:9:23 | TypeExpr | semmle.order | 17 |
3636
| Foo.qll:9:21:9:25 | f | semmle.label | [VarDecl] f |
@@ -65,8 +65,8 @@ nodes
6565
| Foo.qll:10:69:10:73 | inner | semmle.order | 32 |
6666
| Foo.qll:10:69:10:84 | MemberCall | semmle.label | [MemberCall] MemberCall |
6767
| Foo.qll:10:69:10:84 | MemberCall | semmle.order | 32 |
68-
| Foo.qll:13:1:27:1 | calls | semmle.label | [ClasslessPredicate] calls |
69-
| Foo.qll:13:1:27:1 | calls | semmle.order | 34 |
68+
| Foo.qll:13:1:27:1 | ClasslessPredicate calls | semmle.label | [ClasslessPredicate] ClasslessPredicate calls |
69+
| Foo.qll:13:1:27:1 | ClasslessPredicate calls | semmle.order | 34 |
7070
| Foo.qll:13:17:13:19 | TypeExpr | semmle.label | [TypeExpr] TypeExpr |
7171
| Foo.qll:13:17:13:19 | TypeExpr | semmle.order | 35 |
7272
| Foo.qll:13:17:13:21 | f | semmle.label | [VarDecl] f |
@@ -174,42 +174,42 @@ nodes
174174
| printAst.ql:1:1:1:29 | TopLevel | semmle.label | [TopLevel] TopLevel |
175175
| printAst.ql:1:1:1:29 | TopLevel | semmle.order | 86 |
176176
edges
177-
| Foo.qll:1:1:27:2 | TopLevel | Foo.qll:1:1:1:17 | Import | semmle.label | getAMember() |
177+
| Foo.qll:1:1:27:2 | TopLevel | Foo.qll:1:1:1:17 | Import | semmle.label | getAnImport() |
178178
| Foo.qll:1:1:27:2 | TopLevel | Foo.qll:1:1:1:17 | Import | semmle.order | 1 |
179-
| Foo.qll:1:1:27:2 | TopLevel | Foo.qll:3:1:7:1 | Foo | semmle.label | getAMember() |
180-
| Foo.qll:1:1:27:2 | TopLevel | Foo.qll:3:1:7:1 | Foo | semmle.order | 3 |
181-
| Foo.qll:1:1:27:2 | TopLevel | Foo.qll:9:7:11:1 | foo | semmle.label | getAMember() |
182-
| Foo.qll:1:1:27:2 | TopLevel | Foo.qll:9:7:11:1 | foo | semmle.order | 16 |
183-
| Foo.qll:1:1:27:2 | TopLevel | Foo.qll:13:1:27:1 | calls | semmle.label | getAMember() |
184-
| Foo.qll:1:1:27:2 | TopLevel | Foo.qll:13:1:27:1 | calls | semmle.order | 34 |
185-
| Foo.qll:3:1:7:1 | Foo | Foo.qll:3:19:3:22 | TypeExpr | semmle.label | getASuperType() |
186-
| Foo.qll:3:1:7:1 | Foo | Foo.qll:3:19:3:22 | TypeExpr | semmle.order | 4 |
187-
| Foo.qll:3:1:7:1 | Foo | Foo.qll:4:3:4:17 | CharPred | semmle.label | getCharPred() |
188-
| Foo.qll:3:1:7:1 | Foo | Foo.qll:4:3:4:17 | CharPred | semmle.order | 5 |
189-
| Foo.qll:3:1:7:1 | Foo | Foo.qll:6:3:6:38 | ClassPredicate | semmle.label | getClassPredicate(_) |
190-
| Foo.qll:3:1:7:1 | Foo | Foo.qll:6:3:6:38 | ClassPredicate | semmle.order | 10 |
191-
| Foo.qll:4:3:4:17 | CharPred | Foo.qll:4:11:4:15 | ComparisonFormula | semmle.label | getBody() |
192-
| Foo.qll:4:3:4:17 | CharPred | Foo.qll:4:11:4:15 | ComparisonFormula | semmle.order | 6 |
179+
| Foo.qll:1:1:27:2 | TopLevel | Foo.qll:3:1:7:1 | Class Foo | semmle.label | getAClass() |
180+
| Foo.qll:1:1:27:2 | TopLevel | Foo.qll:3:1:7:1 | Class Foo | semmle.order | 3 |
181+
| Foo.qll:1:1:27:2 | TopLevel | Foo.qll:9:7:11:1 | ClasslessPredicate foo | semmle.label | getAPredicate() |
182+
| Foo.qll:1:1:27:2 | TopLevel | Foo.qll:9:7:11:1 | ClasslessPredicate foo | semmle.order | 16 |
183+
| Foo.qll:1:1:27:2 | TopLevel | Foo.qll:13:1:27:1 | ClasslessPredicate calls | semmle.label | getAPredicate() |
184+
| Foo.qll:1:1:27:2 | TopLevel | Foo.qll:13:1:27:1 | ClasslessPredicate calls | semmle.order | 34 |
185+
| Foo.qll:3:1:7:1 | Class Foo | Foo.qll:3:19:3:22 | TypeExpr | semmle.label | getASuperType() |
186+
| Foo.qll:3:1:7:1 | Class Foo | Foo.qll:3:19:3:22 | TypeExpr | semmle.order | 4 |
187+
| Foo.qll:3:1:7:1 | Class Foo | Foo.qll:4:3:4:17 | CharPred Foo | semmle.label | getCharPred() |
188+
| Foo.qll:3:1:7:1 | Class Foo | Foo.qll:4:3:4:17 | CharPred Foo | semmle.order | 5 |
189+
| Foo.qll:3:1:7:1 | Class Foo | Foo.qll:6:3:6:38 | ClassPredicate toString | semmle.label | getClassPredicate(_) |
190+
| Foo.qll:3:1:7:1 | Class Foo | Foo.qll:6:3:6:38 | ClassPredicate toString | semmle.order | 10 |
191+
| Foo.qll:4:3:4:17 | CharPred Foo | Foo.qll:4:11:4:15 | ComparisonFormula | semmle.label | getBody() |
192+
| Foo.qll:4:3:4:17 | CharPred Foo | Foo.qll:4:11:4:15 | ComparisonFormula | semmle.order | 6 |
193193
| Foo.qll:4:11:4:15 | ComparisonFormula | Foo.qll:4:11:4:11 | Integer | semmle.label | getLeftOperand() |
194194
| Foo.qll:4:11:4:15 | ComparisonFormula | Foo.qll:4:11:4:11 | Integer | semmle.order | 6 |
195195
| Foo.qll:4:11:4:15 | ComparisonFormula | Foo.qll:4:13:4:13 | ComparisonOp | semmle.label | getOperator() |
196196
| Foo.qll:4:11:4:15 | ComparisonFormula | Foo.qll:4:13:4:13 | ComparisonOp | semmle.order | 8 |
197197
| Foo.qll:4:11:4:15 | ComparisonFormula | Foo.qll:4:15:4:15 | Integer | semmle.label | getRightOperand() |
198198
| Foo.qll:4:11:4:15 | ComparisonFormula | Foo.qll:4:15:4:15 | Integer | semmle.order | 9 |
199-
| Foo.qll:6:3:6:38 | ClassPredicate | Foo.qll:6:3:6:8 | TypeExpr | semmle.label | getReturnTypeExpr() |
200-
| Foo.qll:6:3:6:38 | ClassPredicate | Foo.qll:6:3:6:8 | TypeExpr | semmle.order | 10 |
201-
| Foo.qll:6:3:6:38 | ClassPredicate | Foo.qll:6:23:6:36 | ComparisonFormula | semmle.label | getBody() |
202-
| Foo.qll:6:3:6:38 | ClassPredicate | Foo.qll:6:23:6:36 | ComparisonFormula | semmle.order | 12 |
199+
| Foo.qll:6:3:6:38 | ClassPredicate toString | Foo.qll:6:3:6:8 | TypeExpr | semmle.label | getReturnTypeExpr() |
200+
| Foo.qll:6:3:6:38 | ClassPredicate toString | Foo.qll:6:3:6:8 | TypeExpr | semmle.order | 10 |
201+
| Foo.qll:6:3:6:38 | ClassPredicate toString | Foo.qll:6:23:6:36 | ComparisonFormula | semmle.label | getBody() |
202+
| Foo.qll:6:3:6:38 | ClassPredicate toString | Foo.qll:6:23:6:36 | ComparisonFormula | semmle.order | 12 |
203203
| Foo.qll:6:23:6:36 | ComparisonFormula | Foo.qll:6:23:6:28 | result | semmle.label | getLeftOperand() |
204204
| Foo.qll:6:23:6:36 | ComparisonFormula | Foo.qll:6:23:6:28 | result | semmle.order | 12 |
205205
| Foo.qll:6:23:6:36 | ComparisonFormula | Foo.qll:6:30:6:30 | ComparisonOp | semmle.label | getOperator() |
206206
| Foo.qll:6:23:6:36 | ComparisonFormula | Foo.qll:6:30:6:30 | ComparisonOp | semmle.order | 14 |
207207
| Foo.qll:6:23:6:36 | ComparisonFormula | Foo.qll:6:32:6:36 | String | semmle.label | getRightOperand() |
208208
| Foo.qll:6:23:6:36 | ComparisonFormula | Foo.qll:6:32:6:36 | String | semmle.order | 15 |
209-
| Foo.qll:9:7:11:1 | foo | Foo.qll:9:21:9:25 | f | semmle.label | getParameter(_) |
210-
| Foo.qll:9:7:11:1 | foo | Foo.qll:9:21:9:25 | f | semmle.order | 17 |
211-
| Foo.qll:9:7:11:1 | foo | Foo.qll:10:3:10:85 | ComparisonFormula | semmle.label | getBody() |
212-
| Foo.qll:9:7:11:1 | foo | Foo.qll:10:3:10:85 | ComparisonFormula | semmle.order | 19 |
209+
| Foo.qll:9:7:11:1 | ClasslessPredicate foo | Foo.qll:9:21:9:25 | f | semmle.label | getParameter(_) |
210+
| Foo.qll:9:7:11:1 | ClasslessPredicate foo | Foo.qll:9:21:9:25 | f | semmle.order | 17 |
211+
| Foo.qll:9:7:11:1 | ClasslessPredicate foo | Foo.qll:10:3:10:85 | ComparisonFormula | semmle.label | getBody() |
212+
| Foo.qll:9:7:11:1 | ClasslessPredicate foo | Foo.qll:10:3:10:85 | ComparisonFormula | semmle.order | 19 |
213213
| Foo.qll:9:21:9:25 | f | Foo.qll:9:21:9:23 | TypeExpr | semmle.label | getTypeExpr() |
214214
| Foo.qll:9:21:9:25 | f | Foo.qll:9:21:9:23 | TypeExpr | semmle.order | 17 |
215215
| Foo.qll:10:3:10:85 | ComparisonFormula | Foo.qll:10:3:10:3 | f | semmle.label | getLeftOperand() |
@@ -240,10 +240,10 @@ edges
240240
| Foo.qll:10:27:10:50 | ComparisonFormula | Foo.qll:10:46:10:50 | String | semmle.order | 30 |
241241
| Foo.qll:10:69:10:84 | MemberCall | Foo.qll:10:69:10:73 | inner | semmle.label | getBase() |
242242
| Foo.qll:10:69:10:84 | MemberCall | Foo.qll:10:69:10:73 | inner | semmle.order | 32 |
243-
| Foo.qll:13:1:27:1 | calls | Foo.qll:13:17:13:21 | f | semmle.label | getParameter(_) |
244-
| Foo.qll:13:1:27:1 | calls | Foo.qll:13:17:13:21 | f | semmle.order | 35 |
245-
| Foo.qll:13:1:27:1 | calls | Foo.qll:14:3:26:14 | Disjunction | semmle.label | getBody() |
246-
| Foo.qll:13:1:27:1 | calls | Foo.qll:14:3:26:14 | Disjunction | semmle.order | 37 |
243+
| Foo.qll:13:1:27:1 | ClasslessPredicate calls | Foo.qll:13:17:13:21 | f | semmle.label | getParameter(_) |
244+
| Foo.qll:13:1:27:1 | ClasslessPredicate calls | Foo.qll:13:17:13:21 | f | semmle.order | 35 |
245+
| Foo.qll:13:1:27:1 | ClasslessPredicate calls | Foo.qll:14:3:26:14 | Disjunction | semmle.label | getBody() |
246+
| Foo.qll:13:1:27:1 | ClasslessPredicate calls | Foo.qll:14:3:26:14 | Disjunction | semmle.order | 37 |
247247
| Foo.qll:13:17:13:21 | f | Foo.qll:13:17:13:19 | TypeExpr | semmle.label | getTypeExpr() |
248248
| Foo.qll:13:17:13:21 | f | Foo.qll:13:17:13:19 | TypeExpr | semmle.order | 35 |
249249
| Foo.qll:14:3:14:10 | PredicateCall | Foo.qll:14:9:14:9 | f | semmle.label | getArgument(_) |
@@ -342,7 +342,7 @@ edges
342342
| Foo.qll:26:3:26:14 | ComparisonFormula | Foo.qll:26:8:26:8 | ComparisonOp | semmle.order | 84 |
343343
| Foo.qll:26:3:26:14 | ComparisonFormula | Foo.qll:26:10:26:14 | Boolean | semmle.label | getRightOperand() |
344344
| Foo.qll:26:3:26:14 | ComparisonFormula | Foo.qll:26:10:26:14 | Boolean | semmle.order | 85 |
345-
| printAst.ql:1:1:1:29 | TopLevel | printAst.ql:1:1:1:28 | Import | semmle.label | getAMember() |
345+
| printAst.ql:1:1:1:29 | TopLevel | printAst.ql:1:1:1:28 | Import | semmle.label | getAnImport() |
346346
| printAst.ql:1:1:1:29 | TopLevel | printAst.ql:1:1:1:28 | Import | semmle.order | 86 |
347347
graphProperties
348348
| semmle.graphKind | tree |
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
| Test.qll:12:3:12:33 | ClassPredicate | Wrong.test overrides $@ but does not have an override annotation. | Test.qll:4:3:4:40 | ClassPredicate | Super.test |
1+
| Test.qll:12:3:12:33 | ClassPredicate test | Wrong.test overrides $@ but does not have an override annotation. | Test.qll:4:3:4:40 | ClassPredicate test | Super.test |

0 commit comments

Comments
 (0)