8172287: improve intellij logging to cover javac internal errors
authormcimadamore
Thu, 05 Jan 2017 19:10:24 +0000
changeset 43032 8a98364c8c69
parent 43031 2d0b2f38225a
child 43033 c37b643739a7
8172287: improve intellij logging to cover javac internal errors Summary: add new message kind to custom intellij ant logger Reviewed-by: jjg
langtools/make/intellij/src/idea/LangtoolsIdeaAntLogger.java
--- a/langtools/make/intellij/src/idea/LangtoolsIdeaAntLogger.java	Thu Jan 05 11:02:35 2017 -0800
+++ b/langtools/make/intellij/src/idea/LangtoolsIdeaAntLogger.java	Thu Jan 05 19:10:24 2017 +0000
@@ -84,6 +84,8 @@
         JAVAC_WARNING(StringBinaryPredicate.CONTAINS, MSG_WARN, "warning:", "compiler.warn"),
         /** a javac note */
         JAVAC_NOTE(StringBinaryPredicate.CONTAINS, MSG_INFO, "note:", "compiler.note"),
+        /** a javac raw error (these typically come from a build misconfiguration - such as a bad javac flag) */
+        JAVAC_RAW_ERROR(StringBinaryPredicate.STARTS_WITH, MSG_INFO, "javac: "),
         /** continuation of some javac error message */
         JAVAC_NESTED_DIAG(StringBinaryPredicate.STARTS_WITH, MSG_INFO, "  "),
         /** a javac crash */
@@ -126,7 +128,7 @@
     enum Task {
         /** exec task - invoked during compilation */
         JAVAC("exec", MessageKind.JAVAC_ERROR, MessageKind.JAVAC_WARNING, MessageKind.JAVAC_NOTE,
-                       MessageKind.JAVAC_NESTED_DIAG, MessageKind.JAVAC_CRASH),
+                       MessageKind.JAVAC_RAW_ERROR, MessageKind.JAVAC_NESTED_DIAG, MessageKind.JAVAC_CRASH),
         /** jtreg task - invoked during test execution */
         JTREG("jtreg", MessageKind.JTREG_TEST_PASSED, MessageKind.JTREG_TEST_FAILED, MessageKind.JTREG_TEST_ERROR, MessageKind.JTREG_TEST_REPORT),
         /** initial synthetic task when the logger is created */