Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[generator] Avoid 'error (…):' construct in diagnostic messages (#851)
Context: #850 When a parsing issue is hit when importing Javadoc info, an "error" is printed out like this: Error (31:41): Syntax error, expected: #PCDATA, <tt>, <TT>, <i>, <I>, {@code, {@docroot}, {@inheritdoc}, {@link, {@linkplain, {@literal, {@value}, {@value, UnknownHtmlElementStart, </tt>, </TT>, </i>, </I>, </p>, </P>, <p>, <P>, <pre>, <PRE>, @author, @apiSince, @deprecated, @deprecatedSince, @exception, @param, @return, @see, @Serialdata, @serialField, @SInCE, @throws, @[unknown], @Version {@link #getCurrentTrackSelections()}}.</li> This is intended to be informational, but this output format triggers the MSBuild error parsing regex, and is interpreted as an actual error, causing the build to fail. Avoid the error by prepending `JavadocImport-` to the `LogMessage.Level` enum value, so that MSBuild doesn't interpret the string as an error and the build can successfully complete: JavadocImport-Error (31:41): Syntax error, expected: #PCDATA, <tt>, <TT>, <i>, <I>, {@code, {@docroot}, {@inheritdoc}, {@link, {@linkplain, {@literal, {@value}, {@value, UnknownHtmlElementStart, </tt>, </TT>, </i>, </I>, </p>, </P>, <p>, <P>, <pre>, <PRE>, @author, @apiSince, @deprecated, @deprecatedSince, @exception, @param, @return, @see, @Serialdata, @serialField, @SInCE, @throws, @[unknown], @Version {@link #getCurrentTrackSelections()}}.</li>
- Loading branch information