April 19 [Issue 24513] New: `pure` can be used as `auto` | ||||
---|---|---|---|---|
| ||||
https://issues.dlang.org/show_bug.cgi?id=24513 Issue ID: 24513 Summary: `pure` can be used as `auto` Product: D Version: D2 Hardware: x86_64 OS: Linux Status: NEW Keywords: accepts-invalid, diagnostic Severity: enhancement Priority: P1 Component: dmd Assignee: nobody@puremagic.com Reporter: b2.temp@gmx.com ## summary `pure` can be used as `auto`, meaning that maybe it carries the same semantics ? ## test case ```d module runnable; pure p(string[] args) { pure a = args.length; return a - a; } int main(string[] args) { return cast(typeof(return)) p(args); } ``` ## notes wtf -- |
Copyright © 1999-2021 by the D Language Foundation