[Issue 22541] DIP1000: Resolve ambiguity of ref-return-scope parameters
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Wed Nov 24 23:04:48 UTC 2021
https://issues.dlang.org/show_bug.cgi?id=22541
Dennis <dkorpel at live.nl> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |dkorpel at live.nl
--- Comment #2 from Dennis <dkorpel at live.nl> ---
I do like the idea of looking for adjacent `return scope`.
I don't like the complexity behind rules a..e, I'd rather simplify it than add
on top of that, so how about an alternative proposal:
When adjacent keywords `return scope` are present, the result is `ref
returnScope`. Everything else results in `returnRef scope`.
You can make returnRef member functions with `scope return`, no new grammar
needed. It also covers issue 20881.
--
More information about the Digitalmars-d-bugs
mailing list