D-Programming-Language/dmd — pull request #1311 by 9rnsr (2012-11-23 07:22:16+00:00)
Title: Implement more property syntax enforcement

Requires: [dmd/pull/1309](https://github.com/D-Programming-Language/dmd/pull/1309) and [dmd/pull/1310](https://github.com/D-Programming-Language/dmd/pull/1310)

The changes:
```d
int func() { return 1; }
void func(int n) { }
@property int prop() { return 2; }
@property void prop(int n) { }
void main() {
// Without -property switch, all lines can compile.
// With -property switch:
func(); // OK -> OK
func(1); // OK -> OK
func; // OK -> OK [*]
func = 1; // OK -> NG
prop(); // OK -> NG
prop; // OK -> OK
prop(1); // OK -> NG
prop = 1; // OK -> OK
}
```

Keep the line at [*] is necessary to allow UFCS chain without redundant parentheses (e.g. `r.map!(a=>a*2).array`).