lexer.setFilename(aContents.getFilename());
lexer.setCommentListener(aContents);
lexer.setTreatAssertAsKeyword(aTreatAssertAsKeyword);
lexer.setTreatEnumAsKeyword(aTreatEnumAsKeyword);
final GeneratedJavaRecognizer parser =
aSilentlyConsumeErrors
? new SilentJavaRecognizer(lexer)
: new GeneratedJavaRecognizer(lexer);
parser.setFilename(aContents.getFilename());
parser.setASTNodeClass(DetailAST.class.getName());
parser.compilationUnit();
return (DetailAST) parser.getAST();
}