* [Bug c++/17964] [4.0/4.1 Regression] cpp error messages contain wrong line in C++
[not found] <bug-17964-1447@http.gcc.gnu.org/bugzilla/>
@ 2005-10-13 20:57 ` pinskia at gcc dot gnu dot org
2005-10-27 20:34 ` pinskia at gcc dot gnu dot org
` (9 subsequent siblings)
10 siblings, 0 replies; 15+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-10-13 20:57 UTC (permalink / raw)
To: gcc-bugs
------- Comment #5 from pinskia at gcc dot gnu dot org 2005-10-13 20:57 -------
It gets worse if the unknown escape is at the beginning of the file and then
you have about 100 more lines.
--
pinskia at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Last reconfirmed|2005-09-10 02:28:42 |2005-10-13 20:57:39
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17964
^ permalink raw reply [flat|nested] 15+ messages in thread
* [Bug c++/17964] [4.0/4.1 Regression] cpp error messages contain wrong line in C++
[not found] <bug-17964-1447@http.gcc.gnu.org/bugzilla/>
2005-10-13 20:57 ` [Bug c++/17964] [4.0/4.1 Regression] cpp error messages contain wrong line in C++ pinskia at gcc dot gnu dot org
@ 2005-10-27 20:34 ` pinskia at gcc dot gnu dot org
2005-10-31 0:40 ` mmitchel at gcc dot gnu dot org
` (8 subsequent siblings)
10 siblings, 0 replies; 15+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-10-27 20:34 UTC (permalink / raw)
To: gcc-bugs
------- Comment #6 from pinskia at gcc dot gnu dot org 2005-10-27 20:34 -------
(In reply to comment #5)
> It gets worse if the unknown escape is at the beginning of the file and then
> you have about 100 more lines.
Or even in a different file.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17964
^ permalink raw reply [flat|nested] 15+ messages in thread
* [Bug c++/17964] [4.0/4.1 Regression] cpp error messages contain wrong line in C++
[not found] <bug-17964-1447@http.gcc.gnu.org/bugzilla/>
2005-10-13 20:57 ` [Bug c++/17964] [4.0/4.1 Regression] cpp error messages contain wrong line in C++ pinskia at gcc dot gnu dot org
2005-10-27 20:34 ` pinskia at gcc dot gnu dot org
@ 2005-10-31 0:40 ` mmitchel at gcc dot gnu dot org
2005-10-31 1:16 ` joseph at codesourcery dot com
` (7 subsequent siblings)
10 siblings, 0 replies; 15+ messages in thread
From: mmitchel at gcc dot gnu dot org @ 2005-10-31 0:40 UTC (permalink / raw)
To: gcc-bugs
------- Comment #7 from mmitchel at gcc dot gnu dot org 2005-10-31 00:40 -------
Leaving as P2; indeed, this is something we should fix.
Overall, the Weinberg/Austern patch to improve compilation speed by reading in
all the tokens upfront has indeed caused several diagnostic issues, all
relating to the fact that we rely on cpplib to tell us about our current
location, and that's no longer possible. We need to explore whether there's a
good way to recover that information, having pre-scanned the file.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17964
^ permalink raw reply [flat|nested] 15+ messages in thread
* [Bug c++/17964] [4.0/4.1 Regression] cpp error messages contain wrong line in C++
[not found] <bug-17964-1447@http.gcc.gnu.org/bugzilla/>
` (2 preceding siblings ...)
2005-10-31 0:40 ` mmitchel at gcc dot gnu dot org
@ 2005-10-31 1:16 ` joseph at codesourcery dot com
2005-11-01 20:03 ` jsm28 at gcc dot gnu dot org
` (6 subsequent siblings)
10 siblings, 0 replies; 15+ messages in thread
From: joseph at codesourcery dot com @ 2005-10-31 1:16 UTC (permalink / raw)
To: gcc-bugs
------- Comment #8 from joseph at codesourcery dot com 2005-10-31 01:16 -------
Subject: Re: [4.0/4.1 Regression] cpp error messages contain
wrong line in C++
On Mon, 31 Oct 2005, mmitchel at gcc dot gnu dot org wrote:
> Overall, the Weinberg/Austern patch to improve compilation speed by reading in
> all the tokens upfront has indeed caused several diagnostic issues, all
> relating to the fact that we rely on cpplib to tell us about our current
> location, and that's no longer possible. We need to explore whether there's a
> good way to recover that information, having pre-scanned the file.
... and without causing other problems with diagnostic location such as
diagnostics appearing where NULL is defined instead of where it is used.
Zack's patch which ran into that issue (mentioned in comment#3) is
<http://gcc.gnu.org/ml/gcc-patches/2005-02/msg00394.html>.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17964
^ permalink raw reply [flat|nested] 15+ messages in thread
* [Bug c++/17964] [4.0/4.1 Regression] cpp error messages contain wrong line in C++
[not found] <bug-17964-1447@http.gcc.gnu.org/bugzilla/>
` (3 preceding siblings ...)
2005-10-31 1:16 ` joseph at codesourcery dot com
@ 2005-11-01 20:03 ` jsm28 at gcc dot gnu dot org
2005-11-02 21:04 ` mrs at apple dot com
` (5 subsequent siblings)
10 siblings, 0 replies; 15+ messages in thread
From: jsm28 at gcc dot gnu dot org @ 2005-11-01 20:03 UTC (permalink / raw)
To: gcc-bugs
------- Comment #9 from jsm28 at gcc dot gnu dot org 2005-11-01 20:03 -------
Working on a fix.
--
jsm28 at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
AssignedTo|unassigned at gcc dot gnu |jsm28 at gcc dot gnu dot org
|dot org |
Status|NEW |ASSIGNED
Last reconfirmed|2005-10-13 20:57:39 |2005-11-01 20:03:12
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17964
^ permalink raw reply [flat|nested] 15+ messages in thread
* [Bug c++/17964] [4.0/4.1 Regression] cpp error messages contain wrong line in C++
[not found] <bug-17964-1447@http.gcc.gnu.org/bugzilla/>
` (4 preceding siblings ...)
2005-11-01 20:03 ` jsm28 at gcc dot gnu dot org
@ 2005-11-02 21:04 ` mrs at apple dot com
2005-11-03 0:31 ` pinskia at gcc dot gnu dot org
` (4 subsequent siblings)
10 siblings, 0 replies; 15+ messages in thread
From: mrs at apple dot com @ 2005-11-02 21:04 UTC (permalink / raw)
To: gcc-bugs
------- Comment #10 from mrs at apple dot com 2005-11-02 21:04 -------
Radar 3843157
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17964
^ permalink raw reply [flat|nested] 15+ messages in thread
* [Bug c++/17964] [4.0/4.1 Regression] cpp error messages contain wrong line in C++
[not found] <bug-17964-1447@http.gcc.gnu.org/bugzilla/>
` (5 preceding siblings ...)
2005-11-02 21:04 ` mrs at apple dot com
@ 2005-11-03 0:31 ` pinskia at gcc dot gnu dot org
2005-11-03 7:01 ` mmitchel at gcc dot gnu dot org
` (3 subsequent siblings)
10 siblings, 0 replies; 15+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-11-03 0:31 UTC (permalink / raw)
To: gcc-bugs
------- Comment #11 from pinskia at gcc dot gnu dot org 2005-11-03 00:30 -------
Patch posted:
http://gcc.gnu.org/ml/gcc-patches/2005-11/msg00092.html
--
pinskia at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
URL| |http://gcc.gnu.org/ml/gcc-
| |patches/2005-
| |11/msg00092.html
Keywords| |patch
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17964
^ permalink raw reply [flat|nested] 15+ messages in thread
* [Bug c++/17964] [4.0/4.1 Regression] cpp error messages contain wrong line in C++
[not found] <bug-17964-1447@http.gcc.gnu.org/bugzilla/>
` (6 preceding siblings ...)
2005-11-03 0:31 ` pinskia at gcc dot gnu dot org
@ 2005-11-03 7:01 ` mmitchel at gcc dot gnu dot org
2005-11-03 23:08 ` jsm28 at gcc dot gnu dot org
` (2 subsequent siblings)
10 siblings, 0 replies; 15+ messages in thread
From: mmitchel at gcc dot gnu dot org @ 2005-11-03 7:01 UTC (permalink / raw)
To: gcc-bugs
------- Comment #12 from mmitchel at gcc dot gnu dot org 2005-11-03 07:01 -------
I approved the patch, subject to there being no objections from the cpplib or
diagnostic maintainers.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17964
^ permalink raw reply [flat|nested] 15+ messages in thread
* [Bug c++/17964] [4.0/4.1 Regression] cpp error messages contain wrong line in C++
[not found] <bug-17964-1447@http.gcc.gnu.org/bugzilla/>
` (7 preceding siblings ...)
2005-11-03 7:01 ` mmitchel at gcc dot gnu dot org
@ 2005-11-03 23:08 ` jsm28 at gcc dot gnu dot org
2005-11-04 1:24 ` jsm28 at gcc dot gnu dot org
2005-11-04 4:50 ` pinskia at gcc dot gnu dot org
10 siblings, 0 replies; 15+ messages in thread
From: jsm28 at gcc dot gnu dot org @ 2005-11-03 23:08 UTC (permalink / raw)
To: gcc-bugs
------- Comment #13 from jsm28 at gcc dot gnu dot org 2005-11-03 23:08 -------
Subject: Bug 17964
Author: jsm28
Date: Thu Nov 3 23:08:18 2005
New Revision: 106454
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=106454
Log:
gcc:
PR c++/17964
* diagnostic.c (diagnostic_set_info_translated): New function.
(diagnostic_set_info): Use it. Add comment.
* diagnostic.h (diagnostic_set_info_translated): Declare.
gcc/cp:
* error.c (cp_cpp_error): New function.
* cp-tree.h (cp_cpp_error): Declare.
* parser.c (cp_lexer_new_main): Set CPP option client_diagnostic
and error callback after lexing.
gcc/testsuite:
* g++.dg/cpp/string-1.C: New test.
libcpp:
* include/cpplib.h (struct cpp_options): Add client_diagnostic.
(struct cpp_callbacks): Add error.
* errors.c (cpp_error): If client_diagnostic, use error callback.
* charset.c (convert_escape): Don't use %03o in diagnostic.
Added:
trunk/gcc/testsuite/g++.dg/cpp/string-1.C
Modified:
trunk/gcc/ChangeLog
trunk/gcc/cp/ChangeLog
trunk/gcc/cp/cp-tree.h
trunk/gcc/cp/error.c
trunk/gcc/cp/parser.c
trunk/gcc/diagnostic.c
trunk/gcc/diagnostic.h
trunk/gcc/testsuite/ChangeLog
trunk/libcpp/ChangeLog
trunk/libcpp/charset.c
trunk/libcpp/errors.c
trunk/libcpp/include/cpplib.h
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17964
^ permalink raw reply [flat|nested] 15+ messages in thread
* [Bug c++/17964] [4.0/4.1 Regression] cpp error messages contain wrong line in C++
[not found] <bug-17964-1447@http.gcc.gnu.org/bugzilla/>
` (8 preceding siblings ...)
2005-11-03 23:08 ` jsm28 at gcc dot gnu dot org
@ 2005-11-04 1:24 ` jsm28 at gcc dot gnu dot org
2005-11-04 4:50 ` pinskia at gcc dot gnu dot org
10 siblings, 0 replies; 15+ messages in thread
From: jsm28 at gcc dot gnu dot org @ 2005-11-04 1:24 UTC (permalink / raw)
To: gcc-bugs
------- Comment #14 from jsm28 at gcc dot gnu dot org 2005-11-04 01:23 -------
Subject: Bug 17964
Author: jsm28
Date: Fri Nov 4 01:23:54 2005
New Revision: 106469
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=106469
Log:
gcc:
PR c++/17964
* diagnostic.c (diagnostic_set_info_translated): New function.
(diagnostic_set_info): Use it. Add comment.
* diagnostic.h (diagnostic_set_info_translated): Declare.
gcc/cp:
* error.c (cp_cpp_error): New function.
* cp-tree.h (cp_cpp_error): Declare.
* parser.c (cp_lexer_new_main): Set CPP option client_diagnostic
and error callback after lexing.
gcc/testsuite:
* g++.dg/cpp/string-1.C: New test.
libcpp:
* include/cpplib.h (struct cpp_options): Add client_diagnostic.
(struct cpp_callbacks): Add error.
* errors.c (cpp_error): If client_diagnostic, use error callback.
* charset.c (convert_escape): Don't use %03o in diagnostic.
Added:
branches/gcc-4_0-branch/gcc/testsuite/g++.dg/cpp/string-1.C
- copied unchanged from r106454,
trunk/gcc/testsuite/g++.dg/cpp/string-1.C
Modified:
branches/gcc-4_0-branch/gcc/ChangeLog
branches/gcc-4_0-branch/gcc/cp/ChangeLog
branches/gcc-4_0-branch/gcc/cp/cp-tree.h
branches/gcc-4_0-branch/gcc/cp/error.c
branches/gcc-4_0-branch/gcc/cp/parser.c
branches/gcc-4_0-branch/gcc/diagnostic.c
branches/gcc-4_0-branch/gcc/diagnostic.h
branches/gcc-4_0-branch/gcc/testsuite/ChangeLog
branches/gcc-4_0-branch/libcpp/ChangeLog
branches/gcc-4_0-branch/libcpp/charset.c
branches/gcc-4_0-branch/libcpp/errors.c
branches/gcc-4_0-branch/libcpp/include/cpplib.h
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17964
^ permalink raw reply [flat|nested] 15+ messages in thread
* [Bug c++/17964] [4.0/4.1 Regression] cpp error messages contain wrong line in C++
[not found] <bug-17964-1447@http.gcc.gnu.org/bugzilla/>
` (9 preceding siblings ...)
2005-11-04 1:24 ` jsm28 at gcc dot gnu dot org
@ 2005-11-04 4:50 ` pinskia at gcc dot gnu dot org
10 siblings, 0 replies; 15+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-11-04 4:50 UTC (permalink / raw)
To: gcc-bugs
------- Comment #15 from pinskia at gcc dot gnu dot org 2005-11-04 04:50 -------
Fixed.
--
pinskia at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
Resolution| |FIXED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17964
^ permalink raw reply [flat|nested] 15+ messages in thread