santosh said:
Richard Heathfield wrote:
>santosh said:
>>We are given the definition of a "diagnostic message" in 3.10 of the
Standard. To quote:
3.10
1 diagnostic message
message belonging to an implementation-defined subset of the
implementation's message output
Unless I'm mistaken, (which I probably am), the definition clearly
implies that each conforming implementation must clearly distinguish
diagnostic messages from their total set of messages, and moreover
document this.
Do existing major implementations actually do this?
Yes.
>>I don't think they
follow the letter of the Standard in this regard.
Borland does. Microsoft does.
But do they also document the subset of their messages that are
diagnostic messages and the means to identify them from "ordinary"
messages?
Borland certainly does. I can't lay my hands on my MS documentation right
now (I haven't even /seen/ it in some years, even though it comes in about
917 volumes), so I was speaking from memory there.
Or do they take the easy way out and define the entire set of messages
as diagnostic messages?
MS might take that easy way out, but I doubt it. (No doubt someone with a
tidier study than mine will be able to clarify.)
>
>And how about gcc? Well, kind of:
"Diagnostics consist of all the output sent to stderr by GCC." :-)
Then presumably there is no obvious way to distinguish between
diagnostic and other messages if stderr and stdout of gcc happen to
write to the same device or file. :-)
On a typical gcc-friendly system (e.g. Linux) it's easy enough to separate
them.
--
Richard Heathfield <http://www.cpax.org.uk>
Email: -http://www. +rjh@
Google users: <http://www.cpax.org.uk/prg/writings/googly.php>
"Usenet is a strange place" - dmr 29 July 1999