]> source.dussan.org Git - aspectj.git/commitdiff
Fix for Bugzilla Bug 52107
authoraclement <aclement>
Thu, 26 Feb 2004 13:34:28 +0000 (13:34 +0000)
committeraclement <aclement>
Thu, 26 Feb 2004 13:34:28 +0000 (13:34 +0000)
   NoSuchMethodError accessing field declared on interface

tests/ajcTests.xml
tests/ajcTestsFailing.xml
weaver/src/org/aspectj/weaver/ResolvedTypeMunger.java

index 2081e9e7c582bff26c3bd56a82c5556cc2f22692..35b7d15f990bafb73412c6d74a9148600902ed0b 100644 (file)
         </compile>
     </ajc-test>
     
+       <ajc-test dir="bugs/fieldsOnInterfaces"
+               pr="52107"
+               title="declare String field on interface">
+               <compile files="StringFieldOnInterface.java">
+                       <message kind="warning" line="16" text="this affected type is not exposed"/>
+               <message kind="warning" line="17" text="this affected type is not exposed"/>
+               </compile>         
+       </ajc-test>
+
+       <ajc-test dir="bugs/fieldsOnInterfaces"
+               pr="52107"
+               title="declare int field on interface">
+               <compile files="IntFieldOnInterface.java">
+               <message kind="warning" line="27" text="this affected type is not exposed"/>
+               <message kind="warning" line="28" text="this affected type is not exposed"/>
+               </compile>
+       </ajc-test>
+       
+       <ajc-test dir="bugs/fieldsOnInterfaces"
+               pr="52107"
+               title="declare Object field on interface">
+               <compile files="ObjectFieldOnInterface.java">
+                       <message kind="warning" line="20" text="this affected type is not exposed"/>
+               <message kind="warning" line="21" text="this affected type is not exposed"/>
+               </compile>
+       </ajc-test>
+    
 </suite>
index cd8ba3e476cf6f7715a2cb41476edf8b035ae066..c2fb46b054957ea5becf0e41505d18a491820f82 100644 (file)
         <run class="InterfaceInitializerOrder"/>
     </ajc-test>
 
-       <ajc-test dir="bugs/fieldsOnInterfaces"
-               pr="52107"
-               title="declare String field on interface">
-               <compile files="StringFieldOnInterface.java"/>
-               <run class="StringFieldOnInterface"/>
-               </ajc-test>
-
-       <ajc-test dir="bugs/fieldsOnInterfaces"
-               pr="52107"
-               title="declare int field on interface">
-               <compile files="IntFieldOnInterface.java"/>
-               <run class="IntFieldOnInterface"/>
-               </ajc-test>
-       
-       <ajc-test dir="bugs/fieldsOnInterfaces"
-               pr="52107"
-               title="declare Object field on interface">
-               <compile files="ObjectFieldOnInterface.java"/>
-               <run class="ObjectFieldOnInterface"/>
-               </ajc-test>
-
 </suite>
index ec4b76b2d2801d51f56816a42ebfc977dd3de991..55e0a4e3e58601ba1c85a1fc1bee55e41b7f1a31 100644 (file)
@@ -54,7 +54,7 @@ public abstract class ResolvedTypeMunger {
        //System.err.println("matching: " + this + " to " + matchType + " onType = " + onType);
                if (matchType.equals(onType)) { 
                        if (!onType.isExposedToWeaver()) {
-                               if (onType.getWeaverState() != null) {
+                               if (onType.getWeaverState() == null) {
                                        if (matchType.getWorld().getLint().typeNotExposedToWeaver.isEnabled()) {
                                                matchType.getWorld().getLint().typeNotExposedToWeaver.signal(
                                                        matchType.getName(), signature.getSourceLocation());