[cfe-dev] cfe-dev Digest, Vol 39, Issue 100
Matthieu Monrocq
matthieu.monrocq at gmail.com
Mon Sep 27 11:41:47 PDT 2010
>
> Sorry I used the term "note" as that's the text GCC prepends, I wasn't
> aware of internal Clang construct by that name.
> Regardless of the machinery used, MSVC (and GCC to a lesser degree),
> attempt to implement these messages as unconfrontational notices, they
> don't generate alarm bells or macro pasting tracebacks.
>
> On Tue, Sep 28, 2010 at 2:11 AM, Chris Lattner <clattner at apple.com> wrote:
> >
> > On Sep 27, 2010, at 5:58 AM, John McCall wrote:
> >
> >>
> >> On Sep 27, 2010, at 7:33 AM, Michael Spencer wrote:
> >>
> >>> On Mon, Sep 27, 2010 at 2:24 AM, Matt Joiner <anacrolix at gmail.com>
> wrote:
> >>>> Perhaps, but #pragma message is hijacking the warning machinery,
> >>>> rather than generating a "note" as in GCC and MSVC. For code with many
> >>>> such messages, this would be irritating. If "message" isn't
> >>>> standardized however, I can understand your lack of interest in it.
> >>>
> >>> I originally tried to emit a note, but I couldn't get clang to print
> >>> it. Implementing this was actually my first patch to clang, so I never
> >>> tried to figure out exactly how to get that working.
> >>
> >> A note wouldn't be appropriate; ?notes are always subordinate to other
> diagnostics.
> >
> > Right, GCC doesn't have a lot of structure or regularity to its
> diagnostics. ?In clang, a "note" is always part of the diagnostic before it.
> ?This is why trying to emit a note as the first diagnostic doesn't work. ?If
> a note comes out after a warning that is disabled, the note is disabled as
> well.
> >
> > -Chris
>
>
What worries me with this new pragma message is that compiling with
"-Werror" is no longer an option as long as there is one header with a
message, am I right ?
Matthieu.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20100927/2b8ff54b/attachment.html>
More information about the cfe-dev
mailing list