JavaCompiler.getStandardFileManager(...,Locale,...) always uses default locale and ignores the one that user specifies.
<JavacTool.java>
.
.
.
public JavacFileManager getStandardFileManager(
DiagnosticListener<? super JavaFileObject> diagnosticListener,
Locale locale,
Charset charset) {
Context context = new Context();
if (diagnosticListener != null)
context.put(DiagnosticListener.class, diagnosticListener);
context.put(Log.outKey, new PrintWriter(System.err, true)); // FIXME
return new JavacFileManager(context, true, charset);
}
...
.
</JavacTool.java>
In the above Standard implementaion, locale is ignored.