gcc/testsuite/gdc.test/compilable/test18737.d
raw| 1 | /* REQUIRED_ARGS: |
| 2 | * PERMUTE_ARGS: |
| 3 | */ |
| 4 | |
| 5 | // https://issues.dlang.org/show_bug.cgi?id=18737 |
| 6 | |
| 7 | struct S |
| 8 | { |
| 9 | this(char); |
| 10 | |
| 11 | this(int j) |
| 12 | { |
| 13 | this('a'); |
| 14 | assert(0); |
| 15 | this('b'); |
| 16 | } |
| 17 | |
| 18 | this(long j) |
| 19 | { |
| 20 | if (j) |
| 21 | { |
| 22 | this('c'); |
| 23 | assert(0); |
| 24 | } |
| 25 | else if (j + 1) |
| 26 | { |
| 27 | this('d'); |
| 28 | return; |
| 29 | } |
| 30 | this('e'); |
| 31 | } |
| 32 | } |