Yes, you are right.
I just tried out naming a member variable of the inner clas
with the same name as the outer class.
Code compiles fine.
public class Q28fd {
int x = 1;
class Inner{
int x=3;
public void m() { System.out.println(" x = "+ x ) ; }
}
public static void main(String args[]) {
Q28fd.Inner i = new Q28fd().new Inner();
i.m();
}
}
Output : x = 3