public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
* [Bug libstdc++/57065] New: incorrect default allocator template for debug and profile unordered_map @ 2013-04-25 5:29 theonetruekenny at yahoo dot com 2013-04-25 9:12 ` [Bug libstdc++/57065] " paolo.carlini at oracle dot com ` (2 more replies) 0 siblings, 3 replies; 4+ messages in thread From: theonetruekenny at yahoo dot com @ 2013-04-25 5:29 UTC (permalink / raw) To: gcc-bugs http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57065 Bug #: 57065 Summary: incorrect default allocator template for debug and profile unordered_map Classification: Unclassified Product: gcc Version: 4.9.0 Status: UNCONFIRMED Severity: minor Priority: P3 Component: libstdc++ AssignedTo: unassigned@gcc.gnu.org ReportedBy: theonetruekenny@yahoo.com In libstdc++-v3/include/debug/unordered_map and libstdc++-v3/include/profile/unorderd_map, the unordered_map template is defined as: template<typename _Key, typename _Tp, typename _Hash = std::hash<_Key>, typename _Pred = std::equal_to<_Key>, typename _Alloc = std::allocator<_Key> > class unordered_map however, the correct definition (as reflected in bits/unordered_map.h) is: * @param Pred Predicate function object type, defaults to equal_to<Value>. * @param Alloc Allocator type, defaults to allocator<Key>. * * The resulting value type of the container is std::pair<const Key, Tp>. */ template<class _Key, class _Tp, class _Hash = hash<_Key>, class _Pred = std::equal_to<_Key>, class _Alloc = std::allocator<std::pair<const _Key, _Tp> > > class unordered_map note that the comment is wrong, but the code is correct. See also: http://www.cplusplus.com/reference/unordered_map/unordered_map/ which matches the definition in bits/unordered_map.h As far as I can tell, this error has existed since gcc 4.3. ^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug libstdc++/57065] incorrect default allocator template for debug and profile unordered_map 2013-04-25 5:29 [Bug libstdc++/57065] New: incorrect default allocator template for debug and profile unordered_map theonetruekenny at yahoo dot com @ 2013-04-25 9:12 ` paolo.carlini at oracle dot com 2013-04-25 9:44 ` paolo.carlini at oracle dot com 2013-04-25 10:06 ` paolo.carlini at oracle dot com 2 siblings, 0 replies; 4+ messages in thread From: paolo.carlini at oracle dot com @ 2013-04-25 9:12 UTC (permalink / raw) To: gcc-bugs http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57065 Paolo Carlini <paolo.carlini at oracle dot com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |NEW Last reconfirmed| |2013-04-25 AssignedTo|unassigned at gcc dot |paolo.carlini at oracle dot |gnu.org |com Target Milestone|--- |4.9.0 Ever Confirmed|0 |1 --- Comment #1 from Paolo Carlini <paolo.carlini at oracle dot com> 2013-04-25 09:12:47 UTC --- Mine. ^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug libstdc++/57065] incorrect default allocator template for debug and profile unordered_map 2013-04-25 5:29 [Bug libstdc++/57065] New: incorrect default allocator template for debug and profile unordered_map theonetruekenny at yahoo dot com 2013-04-25 9:12 ` [Bug libstdc++/57065] " paolo.carlini at oracle dot com @ 2013-04-25 9:44 ` paolo.carlini at oracle dot com 2013-04-25 10:06 ` paolo.carlini at oracle dot com 2 siblings, 0 replies; 4+ messages in thread From: paolo.carlini at oracle dot com @ 2013-04-25 9:44 UTC (permalink / raw) To: gcc-bugs http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57065 Paolo Carlini <paolo.carlini at oracle dot com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Resolution| |FIXED --- Comment #2 from Paolo Carlini <paolo.carlini at oracle dot com> 2013-04-25 09:44:37 UTC --- Fixed. ^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug libstdc++/57065] incorrect default allocator template for debug and profile unordered_map 2013-04-25 5:29 [Bug libstdc++/57065] New: incorrect default allocator template for debug and profile unordered_map theonetruekenny at yahoo dot com 2013-04-25 9:12 ` [Bug libstdc++/57065] " paolo.carlini at oracle dot com 2013-04-25 9:44 ` paolo.carlini at oracle dot com @ 2013-04-25 10:06 ` paolo.carlini at oracle dot com 2 siblings, 0 replies; 4+ messages in thread From: paolo.carlini at oracle dot com @ 2013-04-25 10:06 UTC (permalink / raw) To: gcc-bugs http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57065 --- Comment #4 from Paolo Carlini <paolo.carlini at oracle dot com> 2013-04-25 10:06:24 UTC --- Note that the www.cplusplus.com documentation has unordered_multiset wrong ;) ^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2013-04-25 10:06 UTC | newest] Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2013-04-25 5:29 [Bug libstdc++/57065] New: incorrect default allocator template for debug and profile unordered_map theonetruekenny at yahoo dot com 2013-04-25 9:12 ` [Bug libstdc++/57065] " paolo.carlini at oracle dot com 2013-04-25 9:44 ` paolo.carlini at oracle dot com 2013-04-25 10:06 ` 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).