public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug libstdc++/56267] New: [4.7/4.8 Regression] unordered containers require Assignable hash function
@ 2013-02-09 18:50 redi at gcc dot gnu.org
  2013-02-10 12:20 ` [Bug libstdc++/56267] " rguenth at gcc dot gnu.org
                   ` (9 more replies)
  0 siblings, 10 replies; 11+ messages in thread
From: redi at gcc dot gnu.org @ 2013-02-09 18:50 UTC (permalink / raw)
  To: gcc-bugs


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

             Bug #: 56267
           Summary: [4.7/4.8 Regression] unordered containers require
                    Assignable hash function
    Classification: Unclassified
           Product: gcc
           Version: 4.7.3
            Status: UNCONFIRMED
          Keywords: rejects-valid
          Severity: normal
          Priority: P3
         Component: libstdc++
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: redi@gcc.gnu.org


\x01\x01#include <unordered_set>

struct hash : std::hash<int>
{
  hash& operator=(const hash&) = delete;
};

int main()
{
  std::unordered_set<int, hash> s{ 0, 1, 2 };
  auto i = s.begin(0);
  i = i;
}


The standard does not require hash functions to be assignable.

We must cache the hash code unless is_copy_assignable<H> is true, I'm testing
the fix.


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

end of thread, other threads:[~2014-01-21 19:39 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-02-09 18:50 [Bug libstdc++/56267] New: [4.7/4.8 Regression] unordered containers require Assignable hash function redi at gcc dot gnu.org
2013-02-10 12:20 ` [Bug libstdc++/56267] " rguenth at gcc dot gnu.org
2013-02-10 21:57 ` redi at gcc dot gnu.org
2013-02-10 23:00 ` paolo.carlini at oracle dot com
2013-02-11  0:20 ` redi at gcc dot gnu.org
2013-02-11  0:25 ` redi at gcc dot gnu.org
2013-02-14 22:04 ` jsm28 at gcc dot gnu.org
2013-04-11  8:00 ` [Bug libstdc++/56267] [4.7/4.8/4.9 " rguenth at gcc dot gnu.org
2014-01-20 15:50 ` redi at gcc dot gnu.org
2014-01-20 18:50 ` redi at gcc dot gnu.org
2014-01-21 19:39 ` redi 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).