Re: What am I missing? Pure constructor behaves differently when assigning string member

2014-11-29 Thread anonymous via Digitalmars-d-learn
On Saturday, 29 November 2014 at 09:41:00 UTC, jostly wrote: I can't find a way to use a pure constructor to create both mutable and immutable instances of the same class, when one of the fields I assign is a string. [...] The question is: am I missing something that would make it possible to

Re: What am I missing? Pure constructor behaves differently when assigning string member

2014-11-29 Thread jostly via Digitalmars-d-learn
On Saturday, 29 November 2014 at 09:41:00 UTC, jostly wrote: I can't find a way to use a pure constructor to create both mutable and immutable instances of the same class, when one of the fields I assign is a string. After poking around a bit, I believe it is caused by issue #10012 https://is

What am I missing? Pure constructor behaves differently when assigning string member

2014-11-29 Thread jostly via Digitalmars-d-learn
I can't find a way to use a pure constructor to create both mutable and immutable instances of the same class, when one of the fields I assign is a string. This works fine: class A { int value; this(int value_) pure