Sorry about not writing much these days. Hoping to blog again...
Earlier, I blogged about javac's hidden option "-printflat". I modified javac source to "open up" the hidden "-printflat" flag. Well, it turns out that you don't need to do that!! As per javac source docs, there are 4 kinds of options:
RecognizedOptions class in com.sun.tools.javac.main package. It appears that not much check is done by -XD handling code. With -XDxyz, the code puts "xyz", "xyz" as key-value pairs in compiler's options table. And with "-XDxyz=abc" the -XD handling code puts "xyz", "abc" as key-value pairs in options table. So, we can use
javac -XD-printflat Main.java
to achieve what was done my previous blog entry.
-XD-printflat would put "-printflat" in compiler's internal options table. No need to modify javac sources at all!