From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by sourceware.org (Postfix) with ESMTPS id AED813858D28 for ; Sat, 16 Sep 2023 20:46:53 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org AED813858D28 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=redhat.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1694897213; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=09w6NcwMRPUaRbPydN2pwQVegY5mt4AQ41IElwDgmmU=; b=OGWiHiRMXXH0hutn4Y6iyFQ/xqQGyBxxZH/GWgkprdJq0AvJmxWF210Tqk7KEGqEfRayOI WDDbyNRE9o75JXZ2Qyfh+IZ+nHJWpV22jrkd8l4cLikvXaWUQit1Eo5g/lx/XHOjL65jOr oyRUr3XNKPqeCAzo2KbAOv6HvH/GaxM= Received: from mail-qv1-f71.google.com (mail-qv1-f71.google.com [209.85.219.71]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-228-fI02cChvO3SrMZFat7YbFw-1; Sat, 16 Sep 2023 16:46:49 -0400 X-MC-Unique: fI02cChvO3SrMZFat7YbFw-1 Received: by mail-qv1-f71.google.com with SMTP id 6a1803df08f44-6564515ecd9so9872116d6.0 for ; Sat, 16 Sep 2023 13:46:49 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1694897209; x=1695502009; h=content-transfer-encoding:in-reply-to:from:references:to :content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=09w6NcwMRPUaRbPydN2pwQVegY5mt4AQ41IElwDgmmU=; b=uIPdQ59C50P2gsGfteeWfVWKaFi08I1d034XeD2JXL0vh/UrF1SQ2FOioRdxJbhSyn 7/bPPEOfhI7EakdXh937rm3yAMohWOkgBimuRTDOxgx4APGbt4Hc82/sxBHVuN9hiJKG 266HQ5eMMfaIZ6sek9H4VsoUbb/au0vAFZ5khk8bMAoZKY4R016Kuv4mFgvtmAIDpRX4 E0M8aaKyq2vBlx07JIXFt+6iLpXMhk7WlhrE9oCwNiqHEBoOcNhjGVlDJlN7zyAYFIeF 98TJmhgFIFqsj121ucSsuHw83UZA4zs0vLcKGqW0yjLDspQcy3HwbofyrsCr1+kR8Fsz fTqA== X-Gm-Message-State: AOJu0YwK8ZJ5YlAPccQ/LHqUFulOErfM0dYGJl8fVZ6ITgcFGGprTS34 ACeP7jy5J699JO90VfZic6c3UmYGZ9u5KGsrIatcvI1QLrvNnJd1MbZc/sPhDaL48VxWKiahH/z qTEAHihUOqujYrOx9yQFJm1Hutw== X-Received: by 2002:ad4:5ce2:0:b0:647:30f9:4b79 with SMTP id iv2-20020ad45ce2000000b0064730f94b79mr13603922qvb.7.1694897209206; Sat, 16 Sep 2023 13:46:49 -0700 (PDT) X-Google-Smtp-Source: AGHT+IGOjteL6eO8iTEe4+Om3eTaOBRh3LABEdIrTE+x160dnLg6KtoVgWK0BDMm3xSomvXoZRIbRg== X-Received: by 2002:ad4:5ce2:0:b0:647:30f9:4b79 with SMTP id iv2-20020ad45ce2000000b0064730f94b79mr13603913qvb.7.1694897208977; Sat, 16 Sep 2023 13:46:48 -0700 (PDT) Received: from [192.168.1.108] (130-44-146-16.s12558.c3-0.arl-cbr1.sbo-arl.ma.cable.rcncustomer.com. [130.44.146.16]) by smtp.gmail.com with ESMTPSA id l2-20020a0cac02000000b00655e428604esm2232494qvb.137.2023.09.16.13.46.47 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sat, 16 Sep 2023 13:46:48 -0700 (PDT) Message-ID: Date: Sat, 16 Sep 2023 16:46:46 -0400 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.15.1 Subject: Re: [PATCH] c++: unifying identical tmpls from current inst [PR108347] To: Patrick Palka , gcc-patches@gcc.gnu.org References: <20230913175316.4083902-1-ppalka@redhat.com> From: Jason Merrill In-Reply-To: <20230913175316.4083902-1-ppalka@redhat.com> X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Language: en-US Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-7.2 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE,SPF_NONE,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: On 9/13/23 13:53, Patrick Palka wrote: > Bootstrapped and regtested on x86_64-pc-linux-gnu, does this look > OK for trunk? > > -- >8 -- > > Here more_specialized_partial_spec considers the two partial > specializations to be unordered ultimately because unify for identical > parm=arg=A::C returns failure due to C being dependent. > > This patch fixes this by relaxing unify's early-exit identity test to > also accept dependent decls; we can't deduce anything further from them > anyway. OK. > In passing this patch removes the CONST_DECL case of unify: > we should never see the CONST_DECL version of a template parameter here, > and for other CONST_DECLs (such as enumerators) it seems we can rely on > them already having been folded to their DECL_INITIAL. Hmm, I think I'd prefer to add a gcc_unreachable in case we decide to defer that folding at some point. Jason