[Issue 23491] Nonsensical deprecation message when using delegate

d-bugmail at puremagic.com d-bugmail at puremagic.com
Fri Nov 18 13:38:56 UTC 2022


https://issues.dlang.org/show_bug.cgi?id=23491

RazvanN <razvan.nitu1305 at gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |razvan.nitu1305 at gmail.com

--- Comment #1 from RazvanN <razvan.nitu1305 at gmail.com> ---
I would argue that problem number 2 is not valid. The compiler just looks at
the signature and it sees that unsignedToTempString has a scope return
parameter and assumes that that is the one you are returning so it mentions
that one. It makes more sense to mention the variable that the user can
actually change, rather than the library function parameter which cannot.

However, points 1 and 3 definitely need fixing.

--


More information about the Digitalmars-d-bugs mailing list