[Issue 19097] Extend Return Scope Semantics

d-bugmail at puremagic.com d-bugmail at puremagic.com
Tue Aug 21 20:20:21 UTC 2018


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

Steven Schveighoffer <schveiguy at yahoo.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |schveiguy at yahoo.com

--- Comment #8 from Steven Schveighoffer <schveiguy at yahoo.com> ---
Just throwing this out there, why do we need it to be the first parameter? Why
not ALL ref parameters?

It makes sense for a constructor, for which there is an obvious return
expectation of the `this` parameter, but anyone can devise some calling scheme
by which any arguments are transferred to any other ref arguments.

Just because Phobos follows the convention of putting the "return" parameter as
the first parameter, does that mean the language should require it?

--


More information about the Digitalmars-d-bugs mailing list