Community
Participate
Working Groups
See https://www.eclipse.org/eclipse/platform-text/development/bug-incomplete.htm
Created attachment 278627 [details] source code to reproduce issue
Created attachment 278628 [details] source code to reproduce issue
when there is an anonymous class where both parent class and outer class has a method with same name but parent class method is private, openjdk/oracle jdk 1.8 gives following compile error: [ERROR] /Workspace/gwtcleanmvn/src/main/java/com/aunlu/test2/MainTest.java:[14,33] method test in class com.aunlu.test2.AbstractTest cannot be applied to given types; [ERROR] required: boolean [ERROR] found: no arguments [ERROR] reason: actual and formal argument lists differ in length however, eclipse compiler does not give any compile error and when compiled class is run, it seems application calls outer class method. build-id: Eclipse IDE for Enterprise Java Developers. Version: 2019-03 (4.11.0) Build id: 20190314-1200 java version "1.8.0_212" Java(TM) SE Runtime Environment (build 1.8.0_212-b10) Java HotSpot(TM) 64-Bit Server VM (build 25.212-b10, mixed mode)
reopening after providing details
I can reproduce now. Here ecj seems to violate the "comb rule" from JLS ยง15.12.1., which is illustrated in example 6.5.7.1-1. [1] ecj correctly reports all errors indicated in that example. Interestingly, ecj starts reporting an error against MainTest, when we remove the private method in AbstractTest. That method definitely shouldn't have an impact. To reproduce, the class need not be anonymous, any local class in that context will do. [1] https://docs.oracle.com/javase/specs/jls/se12/html/jls-6.html#jls-6.5.7.1
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet. If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant. -- The automated Eclipse Genie.