8046770: .out files for assert, boxing, and overload tests in tools/javac dir
authorsogoel
Wed, 02 Jul 2014 14:27:10 -0700
changeset 25310 a2e7f254f886
parent 25309 dcd9a7e19669
child 25311 cf09dddb6caf
child 25433 b935bc56f1e4
8046770: .out files for assert, boxing, and overload tests in tools/javac dir Reviewed-by: jjg
langtools/test/tools/javac/assert/DU1.java
langtools/test/tools/javac/assert/DU1.out
langtools/test/tools/javac/assert/DU2.java
langtools/test/tools/javac/assert/DU2.out
langtools/test/tools/javac/boxing/Boxing2.java
langtools/test/tools/javac/boxing/Boxing2.out
langtools/test/tools/javac/boxing/T5082929.java
langtools/test/tools/javac/boxing/T5082929.out
langtools/test/tools/javac/completion/C.java
langtools/test/tools/javac/completion/C.out
langtools/test/tools/javac/completion/example/B.class
langtools/test/tools/javac/expression/NullAppend.java
langtools/test/tools/javac/expression/NullAppend.out
langtools/test/tools/javac/expression/NullAppend2.java
langtools/test/tools/javac/expression/NullAppend2.out
langtools/test/tools/javac/nested/5009484/X.java
langtools/test/tools/javac/nested/5009484/X.out
langtools/test/tools/javac/nested/5009484/Y.java
langtools/test/tools/javac/nested/5009484/Y.out
langtools/test/tools/javac/overload/T4743490.java
langtools/test/tools/javac/overload/T4743490.out
langtools/test/tools/javac/overload/T5090220.java
langtools/test/tools/javac/overload/T5090220.out
--- a/langtools/test/tools/javac/assert/DU1.java	Wed Jul 02 13:29:58 2014 -0700
+++ b/langtools/test/tools/javac/assert/DU1.java	Wed Jul 02 14:27:10 2014 -0700
@@ -1,33 +1,9 @@
 /*
- * 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 4468510
  * @summary Check correct DU computation for assertions.
  * @author gafter
- *
- * @compile/fail DU1.java
+ * @compile/fail/ref=DU1.out -XDrawDiagnostics  DU1.java
  */
 
 class DU1 {
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/langtools/test/tools/javac/assert/DU1.out	Wed Jul 02 14:27:10 2014 -0700
@@ -0,0 +1,2 @@
+DU1.java:16:9: compiler.err.var.might.already.be.assigned: i
+1 error
--- a/langtools/test/tools/javac/assert/DU2.java	Wed Jul 02 13:29:58 2014 -0700
+++ b/langtools/test/tools/javac/assert/DU2.java	Wed Jul 02 14:27:10 2014 -0700
@@ -1,33 +1,9 @@
 /*
- * 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 4468510
  * @summary Check correct DU computation for assertions.
  * @author gafter
- *
- * @compile/fail DU2.java
+ * @compile/fail/ref=DU2.out -XDrawDiagnostics  DU2.java
  */
 
 class DU2 {
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/langtools/test/tools/javac/assert/DU2.out	Wed Jul 02 14:27:10 2014 -0700
@@ -0,0 +1,2 @@
+DU2.java:14:9: compiler.err.var.might.already.be.assigned: i
+1 error
--- a/langtools/test/tools/javac/boxing/Boxing2.java	Wed Jul 02 13:29:58 2014 -0700
+++ b/langtools/test/tools/javac/boxing/Boxing2.java	Wed Jul 02 14:27:10 2014 -0700
@@ -1,33 +1,9 @@
 /*
- * 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 4974939
  * @summary Boxing/unboxing negative unit and regression tests
  * @author gafter
- *
- * @compile/fail Boxing2.java
+ * @compile/fail/ref=Boxing2.out -XDrawDiagnostics  Boxing2.java
  */
 
 public class Boxing2 {
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/langtools/test/tools/javac/boxing/Boxing2.out	Wed Jul 02 14:27:10 2014 -0700
@@ -0,0 +1,2 @@
+Boxing2.java:12:18: compiler.err.prob.found.req: (compiler.misc.inconvertible.types: int, java.lang.Long)
+1 error
--- a/langtools/test/tools/javac/boxing/T5082929.java	Wed Jul 02 13:29:58 2014 -0700
+++ b/langtools/test/tools/javac/boxing/T5082929.java	Wed Jul 02 14:27:10 2014 -0700
@@ -1,32 +1,9 @@
 /*
- * Copyright (c) 2006, 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     5082929
  * @summary Comparing Float and Integer
  * @author  Peter von der Ah\u00e9
- * @compile/fail T5082929.java
+ * @compile/fail/ref=T5082929.out -XDrawDiagnostics  T5082929.java
  */
 
 public class T5082929 {
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/langtools/test/tools/javac/boxing/T5082929.out	Wed Jul 02 14:27:10 2014 -0700
@@ -0,0 +1,2 @@
+T5082929.java:11:23: compiler.err.incomparable.types: java.lang.Float, java.lang.Integer
+1 error
--- a/langtools/test/tools/javac/completion/C.java	Wed Jul 02 13:29:58 2014 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,41 +0,0 @@
-/*
- * Copyright (c) 2001, 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
- * @bug 4433676
- * @summary javac dies with NullPointerException in com.sun.tools.javac.v8.comp.Resolve.find
- * @author gafter
- *
- * @compile/fail C.java
- */
-public class C {
-
-    class CInner extends example.B {
-
-        public CInner(Object o) {
-        }
-
-    }
-
-}
--- a/langtools/test/tools/javac/completion/C.out	Wed Jul 02 13:29:58 2014 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,5 +0,0 @@
-C.java:11: cannot access example.a.A
-file example/a/A.class not found
-    class CInner extends example.B {
-    ^
-1 error
Binary file langtools/test/tools/javac/completion/example/B.class has changed
--- a/langtools/test/tools/javac/expression/NullAppend.java	Wed Jul 02 13:29:58 2014 -0700
+++ b/langtools/test/tools/javac/expression/NullAppend.java	Wed Jul 02 14:27:10 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 4620794
  * @summary compiler allows null + null
  * @author gafter
  *
- * @compile/fail NullAppend.java
+ * @compile/fail/ref=NullAppend.out -XDrawDiagnostics  NullAppend.java
  */
 
 class NullAppend {{
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/langtools/test/tools/javac/expression/NullAppend.out	Wed Jul 02 14:27:10 2014 -0700
@@ -0,0 +1,2 @@
+NullAppend.java:11:16: compiler.err.operator.cant.be.applied.1: +, compiler.misc.type.null, compiler.misc.type.null
+1 error
--- a/langtools/test/tools/javac/expression/NullAppend2.java	Wed Jul 02 13:29:58 2014 -0700
+++ b/langtools/test/tools/javac/expression/NullAppend2.java	Wed Jul 02 14:27:10 2014 -0700
@@ -1,33 +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
+ * @test /nodynamiccopyright/
  * @bug 4717193
  * @summary javac improperly allows null + 1
  * @author gafter
- *
- * @compile/fail NullAppend2.java
+ * @compile/fail/ref=NullAppend2.out -XDrawDiagnostics  NullAppend2.java
  */
 
 class NullAppend2 {{
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/langtools/test/tools/javac/expression/NullAppend2.out	Wed Jul 02 14:27:10 2014 -0700
@@ -0,0 +1,2 @@
+NullAppend2.java:10:16: compiler.err.operator.cant.be.applied.1: +, compiler.misc.type.null, int
+1 error
--- a/langtools/test/tools/javac/nested/5009484/X.java	Wed Jul 02 13:29:58 2014 -0700
+++ b/langtools/test/tools/javac/nested/5009484/X.java	Wed Jul 02 14:27:10 2014 -0700
@@ -1,32 +1,9 @@
 /*
- * Copyright (c) 2005, 2006, 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     5009484
  * @summary Compiler fails to resolve appropriate type for outer member
  * @author  Philippe P Mulet
- * @compile/fail X.java
+ * @compile/fail/ref=X.out -XDrawDiagnostics  X.java
  */
 
 public class X<T> {
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/langtools/test/tools/javac/nested/5009484/X.out	Wed Jul 02 14:27:10 2014 -0700
@@ -0,0 +1,2 @@
+X.java:22:30: compiler.err.prob.found.req: (compiler.misc.inconvertible.types: T, X)
+1 error
--- a/langtools/test/tools/javac/nested/5009484/Y.java	Wed Jul 02 13:29:58 2014 -0700
+++ b/langtools/test/tools/javac/nested/5009484/Y.java	Wed Jul 02 14:27:10 2014 -0700
@@ -1,32 +1,9 @@
 /*
- * Copyright (c) 2006, 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     5009484
  * @summary Compiler fails to resolve appropriate type for outer member
  * @author  Peter von der Ah\u00e9
- * @compile/fail Y.java
+ * @compile/fail/ref=Y.out -XDrawDiagnostics  Y.java
  */
 
 public class Y<T> {
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/langtools/test/tools/javac/nested/5009484/Y.out	Wed Jul 02 14:27:10 2014 -0700
@@ -0,0 +1,2 @@
+Y.java:12:18: compiler.err.prob.found.req: (compiler.misc.inconvertible.types: T, Y<T>)
+1 error
--- a/langtools/test/tools/javac/overload/T4743490.java	Wed Jul 02 13:29:58 2014 -0700
+++ b/langtools/test/tools/javac/overload/T4743490.java	Wed Jul 02 14:27:10 2014 -0700
@@ -1,33 +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
+ * @test /nodynamiccopyright/
  * @bug 4743490
  * @summary overloading versus super.f(args) versus interfaces
  * @author gafter
- *
- * @compile/fail T4743490.java
+ * @compile/fail/ref=T4743490.out -XDrawDiagnostics  T4743490.java
  */
 
 class T4743490 {
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/langtools/test/tools/javac/overload/T4743490.out	Wed Jul 02 14:27:10 2014 -0700
@@ -0,0 +1,2 @@
+T4743490.java:21:18: compiler.err.ref.ambiguous: m, kindname.method, m(java.lang.String,java.lang.Object), T4743490.B, kindname.method, m(java.lang.Object,java.lang.String), T4743490.A
+1 error
--- a/langtools/test/tools/javac/overload/T5090220.java	Wed Jul 02 13:29:58 2014 -0700
+++ b/langtools/test/tools/javac/overload/T5090220.java	Wed Jul 02 14:27:10 2014 -0700
@@ -1,31 +1,8 @@
 /*
- * Copyright (c) 2004, 2007, 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 5090220
  * @summary Autoboxing applied when calculating most-specific method
- * @compile/fail T5090220.java
+ * @compile/fail/ref=T5090220.out -XDrawDiagnostics  T5090220.java
  */
 
 class T5090220 {
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/langtools/test/tools/javac/overload/T5090220.out	Wed Jul 02 14:27:10 2014 -0700
@@ -0,0 +1,2 @@
+T5090220.java:16:9: compiler.err.ref.ambiguous: foo, kindname.method, foo(int,java.lang.Integer), T5090220, kindname.method, foo(java.lang.Integer,double), T5090220
+1 error