aboutsummaryrefslogtreecommitdiffstats
path: root/tests/bugs163
diff options
context:
space:
mode:
authoraclement <aclement>2008-10-14 19:02:55 +0000
committeraclement <aclement>2008-10-14 19:02:55 +0000
commitb454292b74a07a5b5316183209ddac2343ae3e8e (patch)
tree845ee9c23fea31bf21cd6d9717e8a3315c2818f5 /tests/bugs163
parent410753eaa6ed20c3e0120fc1d161bf8f6c724a3b (diff)
downloadaspectj-b454292b74a07a5b5316183209ddac2343ae3e8e.tar.gz
aspectj-b454292b74a07a5b5316183209ddac2343ae3e8e.zip
250493: testcase
Diffstat (limited to 'tests/bugs163')
-rw-r--r--tests/bugs163/pr250493/Bridged.java33
1 files changed, 33 insertions, 0 deletions
diff --git a/tests/bugs163/pr250493/Bridged.java b/tests/bugs163/pr250493/Bridged.java
new file mode 100644
index 000000000..2e3e349e4
--- /dev/null
+++ b/tests/bugs163/pr250493/Bridged.java
@@ -0,0 +1,33 @@
+import java.lang.reflect.Method;
+import java.util.*;
+
+interface Super<T> {
+ public T getterA();
+}
+
+public class Bridged implements Super<String> {
+ public String getterA() {
+ return "";
+ }
+
+ // Print BRIDGE status of all getter* methods
+ public static void main(String[] argv) {
+ Method[] ms = Bridged.class.getMethods();
+ List results = new ArrayList();
+ for (int i = 0; i < ms.length; i++) {
+ if (ms[i].getName().startsWith("getter")) {
+ results.add(ms[i].getName()+"()"+ms[i].getReturnType().getName()+ " isBridged?"+((ms[i].getModifiers() & 0x0040) != 0));
+ }
+ }
+ Collections.sort(results);
+ for (Iterator iterator = results.iterator(); iterator.hasNext();) {
+ String entry = (String) iterator.next();
+ System.out.println(entry);
+ }
+ }
+}
+
+aspect X {
+ public T Super<T>.getterB() { return null; }
+}
+