| 1 |
/* |
| 2 |
TEST_OUTPUT: |
| 3 |
---- |
| 4 |
fail_compilation/issue15103.d(22): Error: found `(` when expecting `;` or `=`, did you mean `Foo foo = 42`? |
| 5 |
fail_compilation/issue15103.d(23): Error: found `(` when expecting `;` or `=`, did you mean `Boo boo = 43`? |
| 6 |
fail_compilation/issue15103.d(24): Error: found `(` when expecting `;` or `=`, did you mean `string y = "a string"`? |
| 7 |
--- |
| 8 |
*/ |
| 9 |
|
| 10 |
struct Foo |
| 11 |
{ |
| 12 |
this(int x) {} |
| 13 |
} |
| 14 |
|
| 15 |
class Boo |
| 16 |
{ |
| 17 |
this(int x) {} |
| 18 |
} |
| 19 |
|
| 20 |
void main () |
| 21 |
{ |
| 22 |
Foo foo(42); |
| 23 |
Boo boo(43); |
| 24 |
string y("a string"); |
| 25 |
} |