aboutsummaryrefslogtreecommitdiff
path: root/libjava/testsuite/libjava.lang
diff options
context:
space:
mode:
Diffstat (limited to 'libjava/testsuite/libjava.lang')
-rw-r--r--libjava/testsuite/libjava.lang/Final.java20
-rw-r--r--libjava/testsuite/libjava.lang/Final.out1
2 files changed, 21 insertions, 0 deletions
diff --git a/libjava/testsuite/libjava.lang/Final.java b/libjava/testsuite/libjava.lang/Final.java
new file mode 100644
index 0000000..1b22096
--- /dev/null
+++ b/libjava/testsuite/libjava.lang/Final.java
@@ -0,0 +1,20 @@
+public final class Final
+{
+ public static void main(String args[])
+ {
+ Final f = null;
+ try
+ {
+ f.doSomething();
+ }
+ catch (NullPointerException x)
+ {
+ System.out.println("NullPointerException - ok");
+ }
+ }
+
+ void doSomething()
+ {
+ System.out.println("This should not happen");
+ }
+}
diff --git a/libjava/testsuite/libjava.lang/Final.out b/libjava/testsuite/libjava.lang/Final.out
new file mode 100644
index 0000000..2e51312
--- /dev/null
+++ b/libjava/testsuite/libjava.lang/Final.out
@@ -0,0 +1 @@
+NullPointerException - ok