[Issue 20075] New: allow cast(ref T)lvalue for casting lvalues
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Tue Jul 23 05:58:23 UTC 2019
https://issues.dlang.org/show_bug.cgi?id=20075
Issue ID: 20075
Summary: allow cast(ref T)lvalue for casting lvalues
Product: D
Version: D2
Hardware: All
OS: All
Status: NEW
Severity: enhancement
Priority: P1
Component: dmd
Assignee: nobody at puremagic.com
Reporter: turkeyman at gmail.com
This is a really tired pattern:
*cast(T*)&lvalue
We should allow:
cast(ref T)lvalue
This is just so much clearer.
--
More information about the Digitalmars-d-bugs
mailing list