1 /***************************************************/
2 // with disable this() struct
14 fail_compilation/fail9665b.d(32): Error: one path skips field `x2`
15 fail_compilation/fail9665b.d(33): Error: one path skips field `x3`
16 fail_compilation/fail9665b.d(35): Error: one path skips field `x5`
17 fail_compilation/fail9665b.d(36): Error: one path skips field `x6`
18 fail_compilation/fail9665b.d(30): Error: field `x1` must be initialized in constructor
19 fail_compilation/fail9665b.d(30): Error: field `x4` must be initialized in constructor
33 auto n
= true ?
(x3
= X(1)) : X
.init
;
36 auto m
= true ?
(x6
= X(1)) : typeof(x6
).init
;
40 /***************************************************/
46 fail_compilation/fail9665b.d(65): Error: one path skips field `x2`
47 fail_compilation/fail9665b.d(66): Error: one path skips field `x3`
48 fail_compilation/fail9665b.d(68): Error: one path skips field `x5`
49 fail_compilation/fail9665b.d(69): Error: one path skips field `x6`
50 fail_compilation/fail9665b.d(63): Error: field `x1` must be initialized in constructor, because it is nested struct
51 fail_compilation/fail9665b.d(63): Error: field `x4` must be initialized in constructor, because it is nested struct
52 fail_compilation/fail9665b.d(76): Error: template instance `fail9665b.S2!(X)` error instantiating
66 auto a
= true ?
(x3
= x
) : X
.init
;
69 auto b
= true ?
(x6
= x
) : typeof(x6
).init
;
74 struct X
{ this(int) {} }
75 static assert(X
.tupleof
.length
== 1);