public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/96045] New: Wrong line and column diagnostic message in a class template instantiation
@ 2020-07-03 11:05 haoxintu at gmail dot com
  2020-07-08 21:54 ` [Bug c++/96045] [11 Regression] " mpolacek at gcc dot gnu.org
                   ` (7 more replies)
  0 siblings, 8 replies; 9+ messages in thread
From: haoxintu at gmail dot com @ 2020-07-03 11:05 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96045

            Bug ID: 96045
           Summary: Wrong line and column diagnostic message in a class
                    template instantiation
           Product: gcc
           Version: 11.0
            Status: UNCONFIRMED
          Keywords: diagnostic
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: haoxintu at gmail dot com
  Target Milestone: ---

This simple code, bug.cc, GCC-trunk can not emit the right diagnostic
information.

$cat bug.cc
template <class> class A {};
struct A <int> 

$g++ -c bug.cc
bug.cc:3: error: expected unqualified-id at end of input

Noted that the number 3 is not a line number nor a column number.

While in Clang
$clang++ -c bug.cc
bug.cc:2:16: error: expected unqualified-id
struct A <int> 
               ^
1 error generated.

$g++ --version
g++ (GCC) 11.0.0 20200630 (experimental)
Copyright (C) 2020 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2021-01-28 16:07 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-07-03 11:05 [Bug c++/96045] New: Wrong line and column diagnostic message in a class template instantiation haoxintu at gmail dot com
2020-07-08 21:54 ` [Bug c++/96045] [11 Regression] " mpolacek at gcc dot gnu.org
2020-07-08 21:57 ` mpolacek at gcc dot gnu.org
2020-10-16 11:54 ` rguenth at gcc dot gnu.org
2020-12-22 20:49 ` jason at gcc dot gnu.org
2020-12-22 21:00 ` nathan at gcc dot gnu.org
2020-12-23 22:26 ` cvs-commit at gcc dot gnu.org
2020-12-26 19:51 ` cvs-commit at gcc dot gnu.org
2021-01-28 16:07 ` jakub at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).