[Issue 18604] in parameter storage class should be deprecated

d-bugmail at puremagic.com d-bugmail at puremagic.com
Tue Mar 20 19:30:01 UTC 2018


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

Jonathan M Davis <issues.dlang at jmdavisProg.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |issues.dlang at jmdavisProg.co
                   |                            |m

--- Comment #6 from Jonathan M Davis <issues.dlang at jmdavisProg.com> ---
Personally, I don't think that the in keyword on parameters should ever have
existed. Having a keyword essentially be an alias for another keyword just
creates confusion, and having it be an alias for _two_ keywords is even worse.
If someone means const, they should say const. If they mean const scope, they
should say const scope. Given the questions asked and discussions had over the
years, I think that it's fairly clear that there are plenty of folks who have
never understood what the deal with in is and how it relates to const. The fact
that it meant two keywords in principle and one in practice just made it worse.

That being said, so many folks liked the idea of in (I think mainly because
they conceptually like the idea of it being the counterpoint to out) that a
_lot_ of code uses in, and as such, if it were deprecated, a _lot_ of code
would have to be changed. So while ideally, I would love to see in deprecated,
in practice, I think that it would just break too much code to make sense, as
much as that sucks.

--


More information about the Digitalmars-d-bugs mailing list