From patchwork Thu Apr 25 09:44:13 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Paolo Carlini X-Patchwork-Id: 239443 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "localhost", Issuer "www.qmailtoaster.com" (not verified)) by ozlabs.org (Postfix) with ESMTPS id 5D9272C00FB for ; Thu, 25 Apr 2013 19:44:27 +1000 (EST) DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender :message-id:date:from:mime-version:to:cc:subject:content-type; q=dns; s=default; b=PtlkcEXzai7XrjRClk8JArJ30Bi6vVvhGiZ5FdvljkD TlGlm5+efOOgWL3ys/ts7x/zZn5rWwIZlYrvnmFGZfYssNJwCpTjSB/sn3vWOfyC 8nq57gG4RT/ENFL1IE8e3mMe4rd0ZLNGbenBWkdhSTqub1HQjMiRWwUc1pcfVO0s = DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender :message-id:date:from:mime-version:to:cc:subject:content-type; s=default; bh=dPcykRD66NSqXvF8DlBeCh6VVF4=; b=VjNKDClUcxWdR2WXr Xvv1bUt0esu0LrNd7F1kVgK1EOyYydA4ce/0hCFmgqIMnki19ixt7bioToS+AxDa VqPHu+PnMHofzDx2nyRV83FEe5wRWtGuRtjyfM7KJkZUxodytixxhn76Tte3qQT6 Cjx8UCm4d5RNc4Br5MOY24kXgk= Received: (qmail 13193 invoked by alias); 25 Apr 2013 09:44:21 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org Received: (qmail 13176 invoked by uid 89); 25 Apr 2013 09:44:20 -0000 X-Spam-SWARE-Status: No, score=-5.4 required=5.0 tests=AWL, BAYES_00, RCVD_IN_DNSWL_MED, RCVD_IN_HOSTKARMA_NO, RCVD_IN_HOSTKARMA_YE, RP_MATCHES_RCVD, SPF_PASS, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-User: qpsmtpd, 2 recipients Received: from aserp1040.oracle.com (HELO aserp1040.oracle.com) (141.146.126.69) by sourceware.org (qpsmtpd/0.84/v0.84-167-ge50287c) with ESMTP; Thu, 25 Apr 2013 09:44:20 +0000 Received: from ucsinet22.oracle.com (ucsinet22.oracle.com [156.151.31.94]) by aserp1040.oracle.com (Sentrion-MTA-4.3.1/Sentrion-MTA-4.3.1) with ESMTP id r3P9iHnr023021 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Thu, 25 Apr 2013 09:44:18 GMT Received: from userz7021.oracle.com (userz7021.oracle.com [156.151.31.85]) by ucsinet22.oracle.com (8.14.4+Sun/8.14.4) with ESMTP id r3P9iGWa018173 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=FAIL); Thu, 25 Apr 2013 09:44:16 GMT Received: from abhmt109.oracle.com (abhmt109.oracle.com [141.146.116.61]) by userz7021.oracle.com (8.14.4+Sun/8.14.4) with ESMTP id r3P9iFWJ014668; Thu, 25 Apr 2013 09:44:15 GMT Received: from poldo4.casa (/79.52.195.70) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Thu, 25 Apr 2013 02:44:15 -0700 Message-ID: <5178FAED.5030409@oracle.com> Date: Thu, 25 Apr 2013 11:44:13 +0200 From: Paolo Carlini User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130329 Thunderbird/17.0.5 MIME-Version: 1.0 To: "gcc-patches@gcc.gnu.org" CC: libstdc++ Subject: [v3] libstdc++/57065 X-Virus-Found: No Hi, tested make check/check-debug on x86_64-linux, committed to mainline. Thanks, Paolo. ///////////////////// 2013-04-25 Paolo Carlini PR libstdc++/57065 * include/debug/unordered_map (unordered_map, unordered_multimap): Fix default allocator type. * include/profile/unordered_map (unordered_map, unordered_multimap): Likewise. * include/bits/unordered_map.h: Fix comments. Index: include/bits/unordered_map.h =================================================================== --- include/bits/unordered_map.h (revision 198275) +++ include/bits/unordered_map.h (working copy) @@ -75,12 +75,13 @@ * * @ingroup unordered_associative_containers * - * @tparam _Key Type of key objects. - * @tparam _Tp Type of mapped objects. - * @tparam _Hash Hashing function object type, defaults to hash<_Value>. - * @tparam _Pred Predicate function object type, defaults - * to equal_to<_Value>. - * @tparam _Alloc Allocator type, defaults to allocator<_Key>. + * @tparam _Key Type of key objects. + * @tparam _Tp Type of mapped objects. + * @tparam _Hash Hashing function object type, defaults to hash<_Value>. + * @tparam _Pred Predicate function object type, defaults + * to equal_to<_Value>. + * @tparam _Alloc Allocator type, defaults to + * std::allocator>. * * Meets the requirements of a container, and * unordered associative container @@ -786,12 +787,13 @@ * * @ingroup unordered_associative_containers * - * @tparam _Key Type of key objects. - * @tparam _Tp Type of mapped objects. - * @tparam _Hash Hashing function object type, defaults to hash<_Value>. - * @tparam _Pred Predicate function object type, defaults - * to equal_to<_Value>. - * @tparam _Alloc Allocator type, defaults to allocator<_Key>. + * @tparam _Key Type of key objects. + * @tparam _Tp Type of mapped objects. + * @tparam _Hash Hashing function object type, defaults to hash<_Value>. + * @tparam _Pred Predicate function object type, defaults + * to equal_to<_Value>. + * @tparam _Alloc Allocator type, defaults to + * std::allocator>. * * Meets the requirements of a container, and * unordered associative container Index: include/debug/unordered_map =================================================================== --- include/debug/unordered_map (revision 198275) +++ include/debug/unordered_map (working copy) @@ -46,7 +46,7 @@ template, typename _Pred = std::equal_to<_Key>, - typename _Alloc = std::allocator<_Key> > + typename _Alloc = std::allocator > > class unordered_map : public _GLIBCXX_STD_C::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>, public __gnu_debug::_Safe_unordered_container, typename _Pred = std::equal_to<_Key>, - typename _Alloc = std::allocator<_Key> > + typename _Alloc = std::allocator > > class unordered_multimap : public _GLIBCXX_STD_C::unordered_multimap<_Key, _Tp, _Hash, _Pred, _Alloc>, Index: include/profile/unordered_map =================================================================== --- include/profile/unordered_map (revision 198275) +++ include/profile/unordered_map (working copy) @@ -44,9 +44,9 @@ { /// Class std::unordered_map wrapper with performance instrumentation. template, + typename _Hash = std::hash<_Key>, typename _Pred = std::equal_to<_Key>, - typename _Alloc = std::allocator<_Key> > + typename _Alloc = std::allocator > > class unordered_map : public _GLIBCXX_STD_BASE { @@ -346,9 +346,9 @@ /// Class std::unordered_multimap wrapper with performance instrumentation. template, + typename _Hash = std::hash<_Key>, typename _Pred = std::equal_to<_Key>, - typename _Alloc = std::allocator<_Key> > + typename _Alloc = std::allocator > > class unordered_multimap : public _GLIBCXX_STD_BASE {