[Bug c++/115987] False "possibly dangling reference" false positive when having an extra template parameter

durosu at yahoo dot com gcc-bugzilla@gcc.gnu.org
Thu Jul 18 17:36:21 GMT 2024


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115987

Dan Urosu <durosu at yahoo dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
         Resolution|---                         |FIXED

--- Comment #14 from Dan Urosu <durosu at yahoo dot com> ---
Thanks for clarifying (1)
I think I can work-around with the pragma. Will try something shortly in the
real code.


Can you please elaborate on this "Right, that's how it works."
(just curious, because we do have the FUNC temporary)

 "T& unwrap_2(Wrapper<T>& r, FUNC&&) ", you don't get the warning.

->>>> Right, that's how it works.


More information about the Gcc-bugs mailing list