From patchwork Wed Nov 18 14:31:28 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Sandiford X-Patchwork-Id: 546032 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.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3EB861402D4 for ; Thu, 19 Nov 2015 01:31:47 +1100 (AEDT) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b=VGhefSjN; dkim-atps=neutral DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:from :to:subject:date:message-id:mime-version:content-type :content-transfer-encoding; q=dns; s=default; b=DczbBbJm7+03TUgY kk9jjmq+s0ftzeYaAxT/Jw6xIYo+e+MmTyRthl7E2eCYmoiWPifvRS5M9Ah8oCZB cNduC4caKGNhsPnjmTepglD/q/XPs9N2u+Ols3YcJxyA2/QiUTxo0OxOydL9xHk7 RnLpzmiKy/jdJWh3jMMHJ3IFng0= 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:from :to:subject:date:message-id:mime-version:content-type :content-transfer-encoding; s=default; bh=uTBw6vn9y9iF7s2x4Lm0qR lF0Ow=; b=VGhefSjN95mbTVI+D0xncgFX3IuVJm+zuGqSCaupTLlc1i3LYKhGr9 N1oqILprpjErXa+vEW/HG7qITWqyYWpYJLPNx47ZWogk40ulRkWT8WjoDl7AFzzM wZZRYXDCkvOCestCd+JByL1+3JOolhCFQW7zSpRqdQ6tCG7LpkKSk= Received: (qmail 16881 invoked by alias); 18 Nov 2015 14:31:40 -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 16870 invoked by uid 89); 18 Nov 2015 14:31:40 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.5 required=5.0 tests=AWL, BAYES_00, SPF_PASS autolearn=ham version=3.3.2 X-HELO: eu-smtp-delivery-143.mimecast.com Received: from eu-smtp-delivery-143.mimecast.com (HELO eu-smtp-delivery-143.mimecast.com) (146.101.78.143) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Wed, 18 Nov 2015 14:31:33 +0000 Received: from cam-owa1.Emea.Arm.com (fw-tnat.cambridge.arm.com [217.140.96.140]) by eu-smtp-1.mimecast.com with ESMTP id uk-mta-33-HWYlTLvHQVOb0onegrm_5Q-1; Wed, 18 Nov 2015 14:31:28 +0000 Received: from localhost ([10.1.2.79]) by cam-owa1.Emea.Arm.com with Microsoft SMTPSVC(6.0.3790.3959); Wed, 18 Nov 2015 14:31:27 +0000 From: Richard Sandiford To: gcc-patches@gcc.gnu.org Mail-Followup-To: gcc-patches@gcc.gnu.org, richard.sandiford@arm.com Subject: [committed] PR 68406: Avoid problem with older host compilers Date: Wed, 18 Nov 2015 14:31:28 +0000 Message-ID: <87d1v7js5b.fsf@e105548-lin.cambridge.arm.com> User-Agent: Gnus/5.130012 (Ma Gnus v0.12) Emacs/24.3 (gnu/linux) MIME-Version: 1.0 X-MC-Unique: HWYlTLvHQVOb0onegrm_5Q-1 Older compilers require the Key typedef to be expanded for the traversal function templates. This patch uses the same approach as we did for hash_map. Tested on x86_64-linux-gnu and applied as obvious (given the previous hash_map patch). Sorry for the breakage. Richard gcc/ PR bootstrap/68406 * hash-set.h (hash_set::traverse): Expand Key typedef. diff --git a/gcc/hash-set.h b/gcc/hash-set.h index 679d2b6..8a7c9a0 100644 --- a/gcc/hash-set.h +++ b/gcc/hash-set.h @@ -68,7 +68,7 @@ public: /* Call the call back on each pair of key and value with the passed in arg. */ - template + template void traverse (Arg a) const { for (typename hash_table::iterator iter = m_table.begin ();