langtools/test/tools/javac/6520152/T6520152.java
author trims
Fri, 02 Jul 2010 01:37:36 -0700
changeset 5910 ca3d85421cbb
parent 10 06bc494ca11e
child 37633 d16d6d59446d
permissions -rw-r--r--
6966252: Bump the HS19 build number to 04 Summary: Update the HS19 build number to 04 Reviewed-by: jcoomes

/**
 * @test
 * @bug     6520152
 * @summary ACC_FINAL flag for anonymous classes shouldn't be set
 * @compile T.java
 * @run main/othervm T6520152
 */

import java.lang.reflect.Method;
import static java.lang.reflect.Modifier.*;

public class T6520152 {
    public static void main(String [] args) throws Exception {
        Class clazz = Class.forName("T$1");
        if ((clazz.getModifiers() & FINAL) != 0) {
            throw new RuntimeException("Failed: " + clazz.getName() + " shouldn't be marked final.");
        }
    }
}