Mercurial > hg > openjdk > jdk9 > langtools
changeset 3172:75ea796e3c93
8067379: Investigate and replace .class files in langtools/test with equivalent .jasm files
Reviewed-by: jjg, ksrini, anazarov
Contributed-by: mallikarjuna.avaluri@oracle.com
author | jjg |
---|---|
date | Tue, 15 Dec 2015 18:54:53 -0800 |
parents | bbac0642e72d |
children | 25ad096cd625 |
files | test/tools/javac/6547131/T.java test/tools/javac/6547131/p/Outer$I.class test/tools/javac/6547131/p/Outer.class test/tools/javac/InnerClassesAttribute/Outside$1$Inside.class test/tools/javac/InnerClassesAttribute/Outside$1$Inside.jasm test/tools/javac/InnerClassesAttribute/Outside.class test/tools/javac/InnerClassesAttribute/Outside.jasm test/tools/javac/InnerClassesAttribute/Test.java test/tools/javac/T6435291/T.class test/tools/javac/T6435291/T6435291.java test/tools/javac/missingSuperRecovery/MissingSuperRecovery.java test/tools/javac/missingSuperRecovery/impl.class test/tools/javac/missingSuperRecovery/impl.jasm |
diffstat | 13 files changed, 130 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/test/tools/javac/6547131/T.java Tue Dec 15 15:30:35 2015 -0800 +++ b/test/tools/javac/6547131/T.java Tue Dec 15 18:54:53 2015 -0800 @@ -2,7 +2,7 @@ * @test * @bug 6547131 * @summary java.lang.ClassFormatError when using old collection API - * @compile T.java + * @compile p/Outer.jasm p/Outer$I.jasm T.java * @run main T */
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/test/tools/javac/InnerClassesAttribute/Outside$1$Inside.jasm Tue Dec 15 18:54:53 2015 -0800 @@ -0,0 +1,38 @@ +/* + * Copyright (c) 2015, 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. + */ + +super class Outside$1$Inside + version 45:3 +{ + +Method "<init>":"()V" + stack 1 locals 1 +{ + aload_0; + invokespecial Method java/lang/Object."<init>":"()V"; + return; +} + +private InnerClass Inside=class Outside$1$Inside; + +} \ No newline at end of file
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/test/tools/javac/InnerClassesAttribute/Outside.jasm Tue Dec 15 18:54:53 2015 -0800 @@ -0,0 +1,44 @@ +/* + * Copyright (c) 2015, 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. + */ + +super public class Outside + version 45:3 +{ + +public Method "<init>":"()V" + stack 1 locals 1 +{ + aload_0; + invokespecial Method java/lang/Object."<init>":"()V"; + return; +} + +Method method:"()V" + stack 0 locals 1 +{ + return; +} + +private InnerClass Inside=class Outside$1$Inside; + +} \ No newline at end of file
--- a/test/tools/javac/InnerClassesAttribute/Test.java Tue Dec 15 15:30:35 2015 -0800 +++ b/test/tools/javac/InnerClassesAttribute/Test.java Tue Dec 15 18:54:53 2015 -0800 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2015 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 @@ -27,7 +27,7 @@ * @summary The compiler used to crash when it saw a correctly-formed * InnerClasses attribute in a .class file. * @author turnidge - * + * @build Outside Outside$1$Inside * @compile Test.java */ public
--- a/test/tools/javac/T6435291/T6435291.java Tue Dec 15 15:30:35 2015 -0800 +++ b/test/tools/javac/T6435291/T6435291.java Tue Dec 15 18:54:53 2015 -0800 @@ -30,6 +30,7 @@ * jdk.compiler/com.sun.tools.javac.code * jdk.compiler/com.sun.tools.javac.main * jdk.compiler/com.sun.tools.javac.util + * @build T * @run main/othervm T6435291 */
--- a/test/tools/javac/missingSuperRecovery/MissingSuperRecovery.java Tue Dec 15 15:30:35 2015 -0800 +++ b/test/tools/javac/missingSuperRecovery/MissingSuperRecovery.java Tue Dec 15 18:54:53 2015 -0800 @@ -4,7 +4,7 @@ * @summary Check for proper error recovery when superclass of extended * class is no longer available during a subsequent compilation. * @author maddox - * + * @build impl * @compile/fail/ref=MissingSuperRecovery.out -XDdiags=%b:%l:%_%m MissingSuperRecovery.java */
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/test/tools/javac/missingSuperRecovery/impl.jasm Tue Dec 15 18:54:53 2015 -0800 @@ -0,0 +1,43 @@ +/* + * Copyright (c) 2015, 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. + */ + +super public class impl + implements base + version 45:3 +{ + +public Method "<init>":"()V" + stack 1 locals 1 +{ + aload_0; + invokespecial Method java/lang/Object."<init>":"()V"; + return; +} + +public Method run:"()V" + stack 0 locals 1 +{ + return; +} + +} \ No newline at end of file