Daily bump.
[official-gcc.git] / gcc / testsuite / gdc.test / fail_compilation / diag10415.d
blob74444327ecbcc19672be2f521639c6abb9906b7b
1 /*
2 TEST_OUTPUT:
3 ---
4 fail_compilation/diag10415.d(36): Error: none of the overloads of `x` are callable using argument types `(int) const`
5 fail_compilation/diag10415.d(13): Candidates are: `diag10415.C.x() const`
6 fail_compilation/diag10415.d(18): `diag10415.C.x(int __param_0)`
7 fail_compilation/diag10415.d(39): Error: d.x is not an lvalue
8 ---
9 */
11 class C
13 @property int x() const
15 return 0;
18 @property void x(int)
23 template AddProp() { @property int x() { return 1; } }
24 template AddFunc() { void x(int, int) {} }
26 class D
28 // overloadset
29 mixin AddProp;
30 mixin AddFunc;
33 void main()
35 const c = new C();
36 c.x = 1;
38 auto d = new D();
39 d.x = 1;