[llvm-dev] [RFC] Preferred error/note style across non-clang tools, e.g. tablegen

Chris Lattner via llvm-dev llvm-dev at lists.llvm.org
Fri Jul 24 13:03:37 PDT 2020



> On Jul 24, 2020, at 11:23 AM, Evandro Menezes <evandro.menezes at sifive.com> wrote:
> 
>>> 
>>> I do not personally like the error and note, since in the patch above, the note is always fatal, whereas I'd rather see what other errors there are before it aborts.
>> 
>> There is plenty of prior-art even just in CodeGenSchedule for error-and-non-fatal-notes (see collectRetireControlUnits, collectLoadStoreQueueInfo). These new ones merely maintain existing behavior of exiting after the diagnostic. Seems this objection is an objection to how it already behaves, and not to the changes I’m proposing.
> 
> I may be missing something, but we'll discuss the patch in its review.  However, unless an error results in a barrage of errors because something crucial was broken, I'd rather see all error messages.  Sometimes, building is tedious (e.g., batch system), so I'd rather be aware of all issues and fix them before trying another build.

Maybe I missed something here: I thought the proposal was to add additional notes to existing error messages, with the goal of clarifying the output and improving the user experience.

I didn’t think the intention was to turn error messages into notes.  Did I get that wrong?

Notes serve completely different role than errors: notes are an “add on” to a warning or error, they should never be a primary diagnostic.

-Chris
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20200724/0e120c5a/attachment.html>


More information about the llvm-dev mailing list