This is the mail archive of the
java-patches@gcc.gnu.org
mailing list for the Java project.
[PATCH] New test case.
- To: java-patches at gcc dot gnu dot org
- Subject: [PATCH] New test case.
- From: Alexandre Petit-Bianco <apbianco at cygnus dot com>
- Date: Thu, 12 Jul 2001 14:34:10 -0700
- Reply-to: apbianco at cygnus dot com
I'm checking in this new test case, brought to you by java/3285.
./A
2001-07-12 Alexandre Petit-Bianco <apbianco@redhat.com>
* libjava.compile/anon_ctor_itf_arg.java: New file.
* libjava.compile/anon_ctor_itf_arg.out: New file.
Index: libjava.compile/anon_ctor_itf_arg.java
===================================================================
RCS file: anon_ctor_itf_arg.java
diff -N anon_ctor_itf_arg.java
--- /dev/null Tue May 5 13:32:27 1998
+++ anon_ctor_itf_arg.java Thu Jul 12 00:50:07 2001
@@ -0,0 +1,38 @@
+/* From java/3285, By p.thio@valescom.com */
+
+interface I
+{
+ void print ();
+};
+
+class C1
+implements I
+{
+ public void print () { System.out.println ("C1: Message"); }
+}
+
+abstract
+class C2
+{
+ C2(I i)
+ {
+ i.print ();
+ }
+ abstract void h();
+}
+
+public
+class anon_ctor_itf_arg
+{
+ public static
+ void main(String argv[])
+ {
+ C1 c1 = new C1();
+ new C2(c1)
+ {
+ void h()
+ {
+ }
+ };
+ }
+}
Index: libjava.compile/anon_ctor_itf_arg.out
===================================================================
RCS file: anon_ctor_itf_arg.out
diff -N anon_ctor_itf_arg.out
--- /dev/null Tue May 5 13:32:27 1998
+++ anon_ctor_itf_arg.out Thu Jul 12 00:50:07 2001
@@ -0,0 +1 @@
+C1: Message