Bug 8056 – Properties should behave like variables, e.g. compound assignments
Status
RESOLVED
Resolution
DUPLICATE
Severity
enhancement
Priority
P2
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2012-05-06T20:19:00Z
Last change time
2012-05-07T04:06:20Z
Assigned to
nobody
Creator
wfunction
Comments
Comment #0 by wfunction — 2012-05-06T20:19:48Z
This should compile if properties are to be used as variables:
@property int foo() { return 1; }
@property void foo(int v) { }
void main()
{
foo |= 2;
}
Comment #1 by issues.dlang — 2012-05-06T20:32:51Z
A related issue would be incrementing and decrementing properties. e.g.
++foo;
Comment #2 by smjg — 2012-05-07T04:06:20Z
*** This issue has been marked as a duplicate of issue 8006 ***