From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id E49223858286; Wed, 17 Jan 2024 11:19:09 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org E49223858286 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1705490349; bh=kb++u5NNekVGjwZkvoOeZAw+Rg4GuTyWTNulW926RLY=; h=From:To:Subject:Date:In-Reply-To:References:From; b=uZ2+4AI3Is3glTEsiW8yQmquHMRfpGPwmES2xjbxwKz2JCwfYfk8LmCCfur3ePfTe qEH6HwibHNnDc1S9RJ5MlhBFLpswBviVnVENlcQ8iFVe1Xnh4wtK7wzUHVSLTFggMr +ZahgfPAXict5u+ubEoyOHP7TpStTM+mqeMwkpAc= From: "redi at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/104094] Alias template shown in diagnostic with wrong template parameter name Date: Wed, 17 Jan 2024 11:19:08 +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: 12.0 X-Bugzilla-Keywords: diagnostic X-Bugzilla-Severity: normal X-Bugzilla-Who: redi at gcc dot gnu.org X-Bugzilla-Status: NEW X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: cf_reconfirmed_on 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=3D104094 Jonathan Wakely changed: What |Removed |Added ---------------------------------------------------------------------------- Last reconfirmed|2022-01-19 00:00:00 |2024-1-17 --- Comment #2 from Jonathan Wakely --- Another example with recent trunk: In file included from /home/jwakely/src/gcc/gcc/libstdc++-v3/testsuite/std/text_encoding/requirem= ents.cc:20: /home/jwakely/gcc/14/include/c++/14.0.1/ranges: In function 'constexpr _Cont std::ranges::to(_Rg&&, _Args&& ...)': /home/jwakely/gcc/14/include/c++/14.0.1/ranges:9332:21: warning: typedef 'u= sing _RefT =3D std::ranges::range_reference_t<_Pattern>' locally defined but not= used [-Wunused-local-typedefs] 9332 | using _RefT =3D range_reference_t<_Rg>; | ^~~~~ Where does _Pattern come from? There is no _Pattern in that function templa= te. The source line shows it should be range_reference_t<_Rg> instead. _Pattern is used in lazy_split_view, split_view and join_view, none of which are used at all by `ranges::to`. Is there some has collision going on here = when the pretty printer finds names? Does it need an additional disambiguation s= tep if more than one name is found?=