--- a/langtools/test/tools/javac/InterfaceObjectIncompatibility.java Fri Sep 05 16:43:00 2014 -0700
+++ b/langtools/test/tools/javac/InterfaceObjectIncompatibility.java Fri Sep 05 16:51:39 2014 -0700
@@ -1,33 +1,10 @@
/*
- * Copyright (c) 2002, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
* @bug 4479164
* @summary Throws clauses incompatible with Object methods allowed in interfaces
* @author gafter
*
- * @compile/fail InterfaceObjectIncompatibility.java
+ * @compile/fail/ref=InterfaceObjectIncompatibility.out -XDrawDiagnostics InterfaceObjectIncompatibility.java
*/
interface InterfaceObjectIncompatibility {
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/langtools/test/tools/javac/InterfaceObjectIncompatibility.out Fri Sep 05 16:51:39 2014 -0700
@@ -0,0 +1,3 @@
+InterfaceObjectIncompatibility.java:12:12: compiler.err.override.meth.doesnt.throw: (compiler.misc.cant.override: toString(), InterfaceObjectIncompatibility, toString(), java.lang.Object), java.io.IOException
+InterfaceObjectIncompatibility.java:13:9: compiler.err.override.meth.doesnt.throw: (compiler.misc.cant.override: hashCode(), InterfaceObjectIncompatibility, hashCode(), java.lang.Object), java.lang.Exception
+2 errors
--- a/langtools/test/tools/javac/InterfaceObjectInheritance.java Fri Sep 05 16:43:00 2014 -0700
+++ b/langtools/test/tools/javac/InterfaceObjectInheritance.java Fri Sep 05 16:51:39 2014 -0700
@@ -1,33 +1,10 @@
/*
- * Copyright (c) 2002, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
* @bug 4526026
* @summary javac allows access to interface members inherited protected from Object
* @author gafter
*
- * @compile/fail InterfaceObjectInheritance.java
+ * @compile/fail/ref=InterfaceObjectInheritance.out -XDrawDiagnostics InterfaceObjectInheritance.java
*/
interface InterfaceObjectInheritance {
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/langtools/test/tools/javac/InterfaceObjectInheritance.out Fri Sep 05 16:51:39 2014 -0700
@@ -0,0 +1,2 @@
+InterfaceObjectInheritance.java:17:18: compiler.err.cant.resolve.location.args: kindname.method, finalize, , , (compiler.misc.location.1: kindname.variable, i, InterfaceObjectInheritance)
+1 error
--- a/langtools/test/tools/javac/InterfaceOverrideFinal.java Fri Sep 05 16:43:00 2014 -0700
+++ b/langtools/test/tools/javac/InterfaceOverrideFinal.java Fri Sep 05 16:51:39 2014 -0700
@@ -1,31 +1,9 @@
/*
- * Copyright (c) 2002, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
+ * @test /nodynamiccopyright/
+ * @bug 4668238 4721069
+ * @summary compiler must reject interface "overriding" final Object meth.
+ * @compile/fail/ref=InterfaceOverrideFinal.out -XDrawDiagnostics InterfaceOverrideFinal.java
*/
-
-/* @test
- @bug 4668238 4721069
- @summary compiler must reject interface "overriding" final Object meth.
- @compile/fail InterfaceOverrideFinal.java
-*/
public interface InterfaceOverrideFinal {
void notify();
}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/langtools/test/tools/javac/InterfaceOverrideFinal.out Fri Sep 05 16:51:39 2014 -0700
@@ -0,0 +1,2 @@
+InterfaceOverrideFinal.java:8:10: compiler.err.override.meth: (compiler.misc.cant.override: notify(), InterfaceOverrideFinal, notify(), java.lang.Object), final
+1 error
--- a/langtools/test/tools/javac/LabeledDeclaration.java Fri Sep 05 16:43:00 2014 -0700
+++ b/langtools/test/tools/javac/LabeledDeclaration.java Fri Sep 05 16:51:39 2014 -0700
@@ -1,33 +1,10 @@
/*
- * Copyright (c) 1998, 2001, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
* @bug 4039843
* @summary The compiler should not allow labeled declarations.
* @author turnidge
*
- * @compile/fail LabeledDeclaration.java
+ * @compile/fail/ref=LabeledDeclaration.out -XDrawDiagnostics LabeledDeclaration.java
*/
class LabeledDeclaration {
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/langtools/test/tools/javac/LabeledDeclaration.out Fri Sep 05 16:51:39 2014 -0700
@@ -0,0 +1,3 @@
+LabeledDeclaration.java:12:14: compiler.err.dot.class.expected
+LabeledDeclaration.java:12:10: compiler.err.not.stmt
+2 errors
--- a/langtools/test/tools/javac/NestedDuplicateLabels.java Fri Sep 05 16:43:00 2014 -0700
+++ b/langtools/test/tools/javac/NestedDuplicateLabels.java Fri Sep 05 16:51:39 2014 -0700
@@ -1,33 +1,10 @@
/*
- * Copyright (c) 1998, 2001, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
* @bug 1241001
* @summary The compiler failed to detect duplicate, nested labels.
* @author turnidge
*
- * @compile/fail NestedDuplicateLabels.java
+ * @compile/fail/ref=NestedDuplicateLabels.out -XDrawDiagnostics NestedDuplicateLabels.java
*/
class NestedDuplicateLabels {
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/langtools/test/tools/javac/NestedDuplicateLabels.out Fri Sep 05 16:51:39 2014 -0700
@@ -0,0 +1,2 @@
+NestedDuplicateLabels.java:12:14: compiler.err.label.already.in.use: foo
+1 error
--- a/langtools/test/tools/javac/NewGeneric.java Fri Sep 05 16:43:00 2014 -0700
+++ b/langtools/test/tools/javac/NewGeneric.java Fri Sep 05 16:51:39 2014 -0700
@@ -1,33 +1,10 @@
/*
- * Copyright (c) 2004, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
* @bug 4959929
* @summary unclear diagnostic for "new T()"
* @author never
*
- * @compile/fail NewGeneric.java
+ * @compile/fail/ref=NewGeneric.out -XDrawDiagnostics NewGeneric.java
*/
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/langtools/test/tools/javac/NewGeneric.out Fri Sep 05 16:51:39 2014 -0700
@@ -0,0 +1,2 @@
+NewGeneric.java:13:28: compiler.err.type.found.req: (compiler.misc.type.parameter: T), (compiler.misc.type.req.class)
+1 error
--- a/langtools/test/tools/javac/NoClass.java Fri Sep 05 16:43:00 2014 -0700
+++ b/langtools/test/tools/javac/NoClass.java Fri Sep 05 16:51:39 2014 -0700
@@ -1,35 +1,12 @@
/*
- * Copyright (c) 1998, 2001, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
* @bug 4041851
* @summary The gramamr allows java files without class or interface
* declarations; when the compiler encountered this, it failed
* to check the validity of import declarations.
* @author turnidge
*
- * @compile/fail NoClass.java
+ * @compile/fail/ref=NoClass.out -XDrawDiagnostics NoClass.java
*/
import nonexistent.pack.cls;
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/langtools/test/tools/javac/NoClass.out Fri Sep 05 16:51:39 2014 -0700
@@ -0,0 +1,2 @@
+NoClass.java:12:24: compiler.err.doesnt.exist: nonexistent.pack
+1 error
--- a/langtools/test/tools/javac/Object1.java Fri Sep 05 16:43:00 2014 -0700
+++ b/langtools/test/tools/javac/Object1.java Fri Sep 05 16:51:39 2014 -0700
@@ -1,33 +1,10 @@
/*
- * Copyright (c) 2001, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
* @bug 4091755
* @summary java.lang.Object can't be redefined without crashing javac
* @author gafter
*
- * @compile/fail Object1.java
+ * @compile/fail/ref=Object1.out -XDrawDiagnostics Object1.java
*/
package java.lang;
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/langtools/test/tools/javac/Object1.out Fri Sep 05 16:51:39 2014 -0700
@@ -0,0 +1,2 @@
+Object1.java:11:22: compiler.err.cyclic.inheritance: java.lang.Throwable
+1 error
--- a/langtools/test/tools/javac/Object2.java Fri Sep 05 16:43:00 2014 -0700
+++ b/langtools/test/tools/javac/Object2.java Fri Sep 05 16:51:39 2014 -0700
@@ -1,33 +1,10 @@
/*
- * Copyright (c) 2001, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
* @bug 4091755
* @summary java.lang.Object can't be redefined without crashing javac
* @author gafter
*
- * @compile/fail Object2.java
+ * @compile/fail/ref=Object2.out -XDrawDiagnostics Object2.java
*/
package java.lang;
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/langtools/test/tools/javac/Object2.out Fri Sep 05 16:51:39 2014 -0700
@@ -0,0 +1,2 @@
+Object2.java:11:25: compiler.err.cyclic.inheritance: java.lang.Cloneable
+1 error