public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug libstdc++/57730] New: class/struct mismatch for std::hash
@ 2013-06-26 16:12 d.frey at gmx dot de
  2013-06-26 16:18 ` [Bug libstdc++/57730] " pinskia at gcc dot gnu.org
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: d.frey at gmx dot de @ 2013-06-26 16:12 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57730

            Bug ID: 57730
           Summary: class/struct mismatch for std::hash
           Product: gcc
           Version: unknown
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: libstdc++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: d.frey at gmx dot de

When compiling with Clang and -Wall -Wextra -Werror, I get an error on a
mismatched declaration/definition for std::hash wrt the use of "class" vs.
"struct". The problem seems to be an inconsistent friend declaration in

  /usr/include/c++/4.8/bits/stl_bvector.h

in line 523 (at least on my system, Ubuntu 12.04, GCC 4.8.1) where it reads

  friend class hash;

and where it *should* read

  friend struct hash;

which (for me) solves the problem.

There might be other places, I did a quick grep on "class hash" and found 4
occurrences in libstdc++, but I'm not sure how to find all cases or even how to
check for this.


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

* [Bug libstdc++/57730] class/struct mismatch for std::hash
  2013-06-26 16:12 [Bug libstdc++/57730] New: class/struct mismatch for std::hash d.frey at gmx dot de
@ 2013-06-26 16:18 ` pinskia at gcc dot gnu.org
  2013-06-26 21:05 ` paolo.carlini at oracle dot com
  2013-06-26 21:05 ` paolo.carlini at oracle dot com
  2 siblings, 0 replies; 4+ messages in thread
From: pinskia at gcc dot gnu.org @ 2013-06-26 16:18 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57730

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|---                         |WONTFIX

--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Bug in clang to warn about this because they is perfectly valid standard C++
code.


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

* [Bug libstdc++/57730] class/struct mismatch for std::hash
  2013-06-26 16:12 [Bug libstdc++/57730] New: class/struct mismatch for std::hash d.frey at gmx dot de
  2013-06-26 16:18 ` [Bug libstdc++/57730] " pinskia at gcc dot gnu.org
@ 2013-06-26 21:05 ` paolo.carlini at oracle dot com
  2013-06-26 21:05 ` paolo.carlini at oracle dot com
  2 siblings, 0 replies; 4+ messages in thread
From: paolo.carlini at oracle dot com @ 2013-06-26 21:05 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57730

Paolo Carlini <paolo.carlini at oracle dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |REOPENED
   Last reconfirmed|                            |2013-06-26
         Resolution|WONTFIX                     |---
     Ever confirmed|0                           |1

--- Comment #2 from Paolo Carlini <paolo.carlini at oracle dot com> ---
Reopened...


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

* [Bug libstdc++/57730] class/struct mismatch for std::hash
  2013-06-26 16:12 [Bug libstdc++/57730] New: class/struct mismatch for std::hash d.frey at gmx dot de
  2013-06-26 16:18 ` [Bug libstdc++/57730] " pinskia at gcc dot gnu.org
  2013-06-26 21:05 ` paolo.carlini at oracle dot com
@ 2013-06-26 21:05 ` paolo.carlini at oracle dot com
  2 siblings, 0 replies; 4+ messages in thread
From: paolo.carlini at oracle dot com @ 2013-06-26 21:05 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57730

Paolo Carlini <paolo.carlini at oracle dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|REOPENED                    |RESOLVED
         Resolution|---                         |DUPLICATE

--- Comment #3 from Paolo Carlini <paolo.carlini at oracle dot com> ---
... to close as Dup.

*** This bug has been marked as a duplicate of bug 56627 ***


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

end of thread, other threads:[~2013-06-26 21:05 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-06-26 16:12 [Bug libstdc++/57730] New: class/struct mismatch for std::hash d.frey at gmx dot de
2013-06-26 16:18 ` [Bug libstdc++/57730] " pinskia at gcc dot gnu.org
2013-06-26 21:05 ` paolo.carlini at oracle dot com
2013-06-26 21:05 ` paolo.carlini at oracle dot com

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).