From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 6E26E385B524; Tue, 12 Sep 2023 17:05:47 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 6E26E385B524 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1694538347; bh=/u10y+xgjx+EwC99460CAAaz7Ivfsx5f5+RomCnhsjQ=; h=From:To:Subject:Date:In-Reply-To:References:From; b=s2JUp1QA5txEUALcX8fSCwgbh0OzKhAv6IyG/JLOMdhaDRHhwe2w3aKs0GiP0plO5 rHpwXhEj85+ooPMoZGTwOTu0bb9rmkMcr1qVXU7SIosfSLufFzVqZIgLwsKSqNtBVZ DDcveBxEDFc9QaoSpaS2Zh4O079cf1uyJ6Z/yWUo= From: "redi at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/59256] qualified name in friend function declaration doesn't match previous declaration in inline namespace Date: Tue, 12 Sep 2023 17:05:46 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: c++ X-Bugzilla-Version: 4.9.0 X-Bugzilla-Keywords: accepts-invalid, rejects-valid X-Bugzilla-Severity: normal X-Bugzilla-Who: redi at gcc dot gnu.org X-Bugzilla-Status: NEW X-Bugzilla-Resolution: X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 List-Id: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D59256 --- Comment #16 from Jonathan Wakely --- The std::format case looks like this: namespace x { inline namespace v { namespace detail { template struct bar; } template auto make(Arg); template class detail::bar { bar() { } template friend auto x::make(Arg); }; template auto make(Arg) { detail::bar b; return 1; } } } int main() { return x::make(1); }=