source: branches/libc-0.6/src/gcc/libjava/testsuite/libjava.lang/stub.java@ 2442

Last change on this file since 2442 was 2, checked in by bird, 23 years ago

Initial revision

  • Property cvs2svn:cvs-rev set to 1.1
  • Property svn:eol-style set to native
  • Property svn:executable set to *
File size: 3.7 KB
Line 
1// Class stub
2// Generated on Fri Feb 4 20:23:47 PST 2000
3// A somewhat thorough test of function invocator generated stubs.
4
5class stub {
6
7 String ok;
8
9 void OK () {System.out.println (ok);}
10 void OK (int i) {System.out.println (ok+" "+i);}
11 static void testOK () {System.out.println ("OK");}
12 static void testOK (int i) {System.out.println ("OK "+i); }
13
14 // STATIC PRIVATE R_VALUE ARGS
15 // No No No No
16 void t1 () {OK();}
17 // Yes No No No
18 static void t2 () {testOK();}
19 // No Yes No No
20 private void t3 () {OK();}
21 // Yes Yes No No
22 static private void t4 () {testOK();}
23 // No No Yes No
24 int t5 () {return 5;}
25 // Yes No Yes No
26 static int t6 () {return 6;}
27 // No Yes Yes No
28 private int t7 () {return 7;}
29 // Yes Yes Yes No
30 static private int t8 () {return 8;}
31
32 // No No No Yes
33 void t9 (int i) {OK(i);}
34 // Yes No No Yes
35 static void t10 (int i) {testOK(i);}
36 // No Yes No Yes
37 private void t11 (int i) {OK(i);}
38 // Yes Yes No Yes
39 static private void t12 (int i) {testOK(i);}
40 // No No Yes Yes
41 int t13 (int i) {return i*2;}
42 // Yes No Yes Yes
43 static int t14 (int i) {return i*3;}
44 // No Yes Yes Yes
45 private int t15 (int i) {return i*4;}
46 // Yes Yes Yes Yes
47 static private int t16 (int i) {return i*5;}
48
49 void foo ()
50 {
51 this.new bar ().test ();
52 }
53 class bar {
54 void test () {
55 ok = "OK";
56 t1 ();
57 t2 ();
58 t3 ();
59 t4 ();
60 System.out.println (t5());
61 System.out.println (t6());
62 System.out.println (t7());
63 System.out.println (t8());