Skip to content

Commit 6d5f962

Browse files
committed
Accept test changes (implicit annotations, restoration of annotation type accesses)
1 parent d96bca0 commit 6d5f962

File tree

3 files changed

+47
-2
lines changed

3 files changed

+47
-2
lines changed

java/ql/integration-tests/all-platforms/kotlin/annotation-id-consistency/PrintAst.expected

Lines changed: 35 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,24 +21,57 @@ User.java:
2121
test.kt:
2222
# 0| [CompilationUnit] test
2323
# 3| 1: [Interface] Ann1
24+
#-----| -3: (Annotations)
25+
# 0| 1: [Annotation] Retention
26+
# 0| 1: [VarAccess] RetentionPolicy.RUNTIME
27+
# 0| -1: [TypeAccess] RetentionPolicy
2428
# 3| 1: [Method] x
29+
# 3| 3: [TypeAccess] int
2530
# 3| 2: [Method] y
31+
# 3| 3: [TypeAccess] Ann2
2632
# 5| 2: [Interface] Ann2
33+
#-----| -3: (Annotations)
34+
# 0| 1: [Annotation] Retention
35+
# 0| 1: [VarAccess] RetentionPolicy.RUNTIME
36+
# 0| -1: [TypeAccess] RetentionPolicy
2737
# 5| 1: [Method] z
38+
# 5| 3: [TypeAccess] String
2839
# 5| 2: [Method] w
40+
# 5| 3: [TypeAccess] Class<?>
41+
# 5| 0: [WildcardTypeAccess] ? ...
2942
# 5| 3: [Method] v
43+
# 5| 3: [TypeAccess] int[]
3044
# 5| 4: [Method] u
45+
# 5| 3: [TypeAccess] Ann3[]
46+
# 5| 0: [TypeAccess] Ann3
3147
# 5| 5: [Method] t
48+
# 5| 3: [TypeAccess] Class<?>[]
49+
# 5| 0: [TypeAccess] Class<?>
50+
# 5| 0: [WildcardTypeAccess] ? ...
3251
# 7| 3: [Interface] Ann3
52+
#-----| -3: (Annotations)
53+
# 0| 1: [Annotation] Retention
54+
# 0| 1: [VarAccess] RetentionPolicy.RUNTIME
55+
# 0| -1: [TypeAccess] RetentionPolicy
3356
# 7| 1: [Method] a
57+
# 7| 3: [TypeAccess] int
3458
# 9| 4: [GenericType,Interface,ParameterizedType] GenericAnnotation
59+
#-----| -3: (Annotations)
60+
# 0| 1: [Annotation] Retention
61+
# 0| 1: [VarAccess] RetentionPolicy.RUNTIME
62+
# 0| -1: [TypeAccess] RetentionPolicy
3563
#-----| -2: (Generic Parameters)
3664
# 9| 0: [TypeVariable] T
3765
# 9| 1: [Method] x
66+
# 9| 3: [TypeAccess] Class<T>
67+
# 9| 0: [TypeAccess] T
3868
# 9| 2: [Method] y
69+
# 9| 3: [TypeAccess] Class<T>[]
70+
# 9| 0: [TypeAccess] Class<T>
71+
# 9| 0: [TypeAccess] T
3972
# 11| 6: [Class] Annotated
4073
#-----| -3: (Annotations)
41-
# 11| 2: [Annotation] Ann1
74+
# 11| 1: [Annotation] Ann1
4275
# 0| 1: [IntegerLiteral] 1
4376
# 0| 1: [Annotation] Ann2
4477
# 0| 1: [StringLiteral] "Hello"
@@ -58,7 +91,7 @@ test.kt:
5891
# 0| 0: [TypeAccess] String
5992
# 0| 1: [TypeLiteral] int.class
6093
# 0| 0: [TypeAccess] int
61-
# 12| 3: [Annotation] GenericAnnotation<>
94+
# 12| 2: [Annotation] GenericAnnotation<>
6295
# 13| 1: [Constructor] Annotated
6396
# 11| 5: [BlockStmt] { ... }
6497
# 11| 0: [SuperConstructorInvocationStmt] super(...)

java/ql/test/kotlin/library-tests/annotation_classes/PrintAst.expected

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -141,6 +141,7 @@ def.kt:
141141
#-----| 1: (Annotations)
142142
# 21| 1: [Annotation] JvmName
143143
# 0| 1: [StringLiteral] "a"
144+
# 21| 3: [TypeAccess] int
144145
# 23| 3: [Interface] Annot1k
145146
#-----| -3: (Annotations)
146147
# 0| 1: [Annotation] Retention
@@ -149,11 +150,19 @@ def.kt:
149150
# 23| 2: [Annotation] Annot0k
150151
# 0| 1: [IntegerLiteral] 0
151152
# 25| 1: [Method] a
153+
# 25| 3: [TypeAccess] int
152154
# 26| 2: [Method] b
155+
# 26| 3: [TypeAccess] String
153156
# 27| 3: [Method] c
157+
# 27| 3: [TypeAccess] Class<?>
158+
# 27| 0: [WildcardTypeAccess] ? ...
154159
# 28| 4: [Method] d
160+
# 28| 3: [TypeAccess] Y
155161
# 29| 5: [Method] e
162+
# 29| 3: [TypeAccess] Y[]
163+
# 29| 0: [TypeAccess] Y
156164
# 30| 6: [Method] f
165+
# 30| 3: [TypeAccess] Annot0k
157166
# 33| 4: [Class] X
158167
# 33| 1: [Constructor] X
159168
# 33| 5: [BlockStmt] { ... }

java/ql/test/kotlin/library-tests/collection-literals/PrintAst.expected

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,4 +6,7 @@ test.kt:
66
# 0| 1: [VarAccess] RetentionPolicy.RUNTIME
77
# 0| -1: [TypeAccess] RetentionPolicy
88
# 1| 1: [Method] arr1
9+
# 1| 3: [TypeAccess] String[]
10+
# 1| 0: [TypeAccess] String
911
# 1| 2: [Method] arr2
12+
# 1| 3: [TypeAccess] int[]

0 commit comments

Comments
 (0)