[llvm-commits] CVS: llvm-java/test/Programs/SingleSource/UnitTests/Call.java Makefile
Alkis Evlogimenos
alkis at cs.uiuc.edu
Fri Dec 10 12:10:04 PST 2004
Changes in directory llvm-java/test/Programs/SingleSource/UnitTests:
Call.java added (r1.1)
Makefile updated: 1.25 -> 1.26
---
Log message:
Add new testcase
---
Diffs of the changes: (+27 -0)
Index: llvm-java/test/Programs/SingleSource/UnitTests/Call.java
diff -c /dev/null llvm-java/test/Programs/SingleSource/UnitTests/Call.java:1.1
*** /dev/null Fri Dec 10 14:10:03 2004
--- llvm-java/test/Programs/SingleSource/UnitTests/Call.java Fri Dec 10 14:09:53 2004
***************
*** 0 ****
--- 1,26 ----
+ interface CallInterface {
+ public int i1();
+ }
+
+ abstract class CallAbstract {
+ protected abstract int a1();
+ public int c1() { return a1() * a2(); }
+ protected abstract int a2();
+ }
+
+ class CallConcrete extends CallAbstract implements CallInterface {
+ private int i;
+
+ CallConcrete(int i) { this.i = i; }
+ public int a1() { return i; }
+ public int a2() { return i + i; }
+ public int i1() { return c1(); }
+ }
+
+ public class Call
+ {
+ public static void main(String[] args) {
+ CallInterface i = new CallConcrete(10);
+ Test.print_int_ln(i.i1());
+ }
+ }
Index: llvm-java/test/Programs/SingleSource/UnitTests/Makefile
diff -u llvm-java/test/Programs/SingleSource/UnitTests/Makefile:1.25 llvm-java/test/Programs/SingleSource/UnitTests/Makefile:1.26
--- llvm-java/test/Programs/SingleSource/UnitTests/Makefile:1.25 Fri Dec 10 13:53:56 2004
+++ llvm-java/test/Programs/SingleSource/UnitTests/Makefile Fri Dec 10 14:09:53 2004
@@ -12,6 +12,7 @@
Arithm \
Array \
BigConstants \
+ Call \
FieldAccess \
FloatCompare \
ForLoop \
More information about the llvm-commits
mailing list