digitalmars.D.bugs - [Issue 18633] New: Specify clearly if `typectors ref` is the same
- d-bugmail puremagic.com (25/25) Mar 19 2018 https://issues.dlang.org/show_bug.cgi?id=18633
https://issues.dlang.org/show_bug.cgi?id=18633 Issue ID: 18633 Summary: Specify clearly if `typectors ref` is the same as `typector auto ref ` Product: D Version: D2 Hardware: All OS: All Status: NEW Severity: enhancement Priority: P1 Component: dlang.org Assignee: nobody puremagic.com Reporter: b2.temp gmx.com the compiler accepts `auto ref inout(ElementType!Range) choice(Range, RandomGen = Random)(inout ref Range range, ref RandomGen urng){...}` While a more correct form is `auto ref inout(ElementType!Range) choice(Range, RandomGen = Random)(inout auto ref Range range, ref RandomGen urng){...}` The specs don't say why and when `auto` can be omitted, they could be more accurate. Problem encountered here: https://github.com/dlang/phobos/pull/6302#discussion_r175561789 --
Mar 19 2018