On Saturday, 24 June 2017 at 21:11:13 UTC, Igor Shirkalin wrote:
Is it possible without such a constructor?

No. Also, the above works because of the following [1]:

Casting a value v to a struct S, when value is not a struct of the same type, is equivalent to: `S(v)`

[1] https://dlang.org/spec/expression.html#CastExpression

Reply via email to