1package: 2 annotation @A: @java.lang.annotation.Target(value={TYPE_USE}) 3 annotation @B: @java.lang.annotation.Target(value={TYPE_USE}) 4 annotation @C: @java.lang.annotation.Target(value={TYPE_USE}) 5 annotation @D: @java.lang.annotation.Target(value={TYPE_USE}) 6 annotation @D1: @java.lang.annotation.Target(value={TYPE_USE}) 7 annotation @E: @java.lang.annotation.Target(value={TYPE_USE}) 8 int value 9 annotation @F: @java.lang.annotation.Target(value={TYPE_USE}) 10 annotation @F1: @java.lang.annotation.Target(value={TYPE_USE}) 11 annotation @G: @java.lang.annotation.Target(value={TYPE_USE}) 12 int value 13 annotation @H: @java.lang.annotation.Target(value={TYPE_USE}) 14 annotation @I: @java.lang.annotation.Target(value={TYPE_USE}) 15 annotation @I1: @java.lang.annotation.Target(value={TYPE_USE}) 16 int value 17 annotation @J: @java.lang.annotation.Target(value={TYPE_USE}) 18 annotation @K: @java.lang.annotation.Target(value={TYPE_USE}) 19 annotation @L: @java.lang.annotation.Target(value={TYPE_USE}) 20 annotation @M: @java.lang.annotation.Target(value={TYPE_USE}) 21 annotation @N: @java.lang.annotation.Target(value={TYPE_USE}) 22 annotation @O: @java.lang.annotation.Target(value={TYPE_USE}) 23 annotation @P: @java.lang.annotation.Target(value={TYPE_USE}) 24 annotation @X: @java.lang.annotation.Target(value={TYPE_USE}) 25 26package annotator.tests: 27 // Try to insert a receiver parameter on a method declaration in an 28 // anonymous inner class. This is illegal, so should do nothing. 29 class InnerReceivers$1: 30 method m()V: 31 receiver: @X 32 33 class InnerReceivers$1$Inner: 34 method m()V: 35 receiver: @A 36 method m1()V: 37 receiver: @B 38 39 class InnerReceivers: 40 method m()V: 41 receiver: @C 42 method m1()V: 43 receiver: @D 44 method m2()V: 45 receiver: @D1 46 47 class InnerReceivers$Inner1: 48 method m()V: 49 receiver: @E(0) 50 inner-type 1, 0: @E(1) 51 inner-type 1, 0, 3, 0: @E(2) 52 inner-type 1, 0, 3, 1: @E(3) 53 // The following two annotations are in incorrect locations and 54 // should not be inserted. 55 inner-type 3, 0: @X 56 inner-type 3, 1: @X 57 method m1()V: 58 receiver: @F 59 method m2()V: 60 receiver: @F1 61 62 class InnerReceivers$Inner1$Inner2: 63 method m()V: 64 receiver: @G(0) 65 inner-type 1, 0: @G(1) 66 inner-type 1, 0, 3, 0: @G(2) 67 inner-type 1, 0, 3, 1: @G(3) 68 inner-type 1, 0, 1, 0: @G(4) 69 method m1()V: 70 receiver: @H 71 72 class InnerReceivers$StaticInner1: 73 method m()V: 74 receiver: @I 75 // Incorrect location, should not be inserted 76 inner-type 1, 0: @X 77 method m1()V: 78 receiver: @J 79 method m2()V: 80 receiver: @K 81 82 class InnerReceivers$StaticInner3: 83 method m()V: 84 receiver: @I1(0) 85 inner-type 3, 0: @I1(1) 86 inner-type 3, 1: @I1(2) 87 // Incorrect location, should not be inserted 88 inner-type 1, 0: @X 89 method m1()V: 90 receiver: @J 91 method m2()V: 92 receiver: @K 93 94 class Outer$StaticInner2: 95 method m()V: 96 receiver: @L 97 // Incorrect location, should not be inserted 98 inner-type 1, 0: @X 99 method m1()V: 100 receiver: @M 101 method m2()V: 102 receiver: @N 103 104 class Outer$StaticInner2$StaticInner3: 105 method m()V: 106 receiver: @O 107 // Incorrect location, should not be inserted 108 inner-type 1, 0: @X 109