This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/47429] -Wfatal-errors hiding line number of offending caller
- From: "manu at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Mon, 24 Jan 2011 13:26:02 +0000
- Subject: [Bug c++/47429] -Wfatal-errors hiding line number of offending caller
- Auto-submitted: auto-generated
- References: <bug-47429-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47429
Manuel LÃpez-IbÃÃez <manu at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Last reconfirmed| |2011.01.24 13:26:01
CC| |manu at gcc dot gnu.org
Ever Confirmed|0 |1
--- Comment #2 from Manuel LÃpez-IbÃÃez <manu at gcc dot gnu.org> 2011-01-24 13:26:01 UTC ---
This is an old bug but I cannot find it in bugzilla.
There are several issues:
* GCC doesn't have the concept of multi-line diagnostic, each line is
independent. That is, we cannot do error("this is one line.\nThis is another").
This is not difficult to implement but it is long and tedious.
* GCC cannot build a single diagnostic that expands several lines from
individual calls. That is, we cannot do
Diagnostic diag;
diag.error("âint Blah::testâ is private");
diag.note("within this context")
diag.report();
This is much harder (and ugly) to solve in C.
I am not sure about the status of Clang/LLVM with respect to this. Last time I
looked their diagnostic machinery was too strongly based on GCC's so they
suffered the same problem, but there have been loads of changes since then, so
perhaps they fixed it already.