1.1 --- a/src/share/classes/com/sun/tools/javac/jvm/ClassWriter.java Wed Sep 29 23:27:57 2010 -0700 1.2 +++ b/src/share/classes/com/sun/tools/javac/jvm/ClassWriter.java Thu Sep 30 10:47:12 2010 -0700 1.3 @@ -45,8 +45,10 @@ 1.4 import static com.sun.tools.javac.code.Kinds.*; 1.5 import static com.sun.tools.javac.code.TypeTags.*; 1.6 import static com.sun.tools.javac.jvm.UninitializedType.*; 1.7 +import static com.sun.tools.javac.main.OptionName.*; 1.8 import static javax.tools.StandardLocation.CLASS_OUTPUT; 1.9 1.10 + 1.11 /** This class provides operations to map an internal symbol table graph 1.12 * rooted in a ClassSymbol into a classfile. 1.13 * 1.14 @@ -178,15 +180,16 @@ 1.15 types = Types.instance(context); 1.16 fileManager = context.get(JavaFileManager.class); 1.17 1.18 - debugJSR308 = options.get("TA:writer") != null; 1.19 - verbose = options.get("-verbose") != null; 1.20 - scramble = options.get("-scramble") != null; 1.21 - scrambleAll = options.get("-scrambleAll") != null; 1.22 - retrofit = options.get("-retrofit") != null; 1.23 - genCrt = options.get("-Xjcov") != null; 1.24 - debugstackmap = options.get("debugstackmap") != null; 1.25 + debugJSR308 = options.isSet("TA:writer"); 1.26 + verbose = options.isSet(VERBOSE); 1.27 + scramble = options.isSet("-scramble"); 1.28 + scrambleAll = options.isSet("-scrambleAll"); 1.29 + retrofit = options.isSet("-retrofit"); 1.30 + genCrt = options.isSet(XJCOV); 1.31 + debugstackmap = options.isSet("debugstackmap"); 1.32 1.33 - emitSourceFile = options.get("-g:")==null || options.get("-g:source")!=null; 1.34 + emitSourceFile = options.isUnset(G_CUSTOM) || 1.35 + options.isSet(G_CUSTOM, "source"); 1.36 1.37 String dumpModFlags = options.get("dumpmodifiers"); 1.38 dumpClassModifiers =