diff options
Diffstat (limited to 'tests/bugs174')
-rw-r--r-- | tests/bugs174/pr413378/Code.java | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/tests/bugs174/pr413378/Code.java b/tests/bugs174/pr413378/Code.java new file mode 100644 index 000000000..f591dac45 --- /dev/null +++ b/tests/bugs174/pr413378/Code.java @@ -0,0 +1,38 @@ +class Child extends Parent{ + + public String mParent = "John"; + + public Child(String parent) { + this.mParent = parent; + } + + public String getParent() + { + return this.mParent; + } +} + +class Parent { + private String mName = "John"; + private int mAge = 50; + + public int getAge(){ + return mAge; + } +} + +aspect MyTest { + + public Child.new(String parent, int age) { + this(parent); + + System.out.println("Get Age:" + super.getAge()); + System.out.println("Child Name:" + this.mParent); + } +} + +public class Code { + public static void main(String []argv) { + new Child("Andy",5); + } +} |