this() immutable
Stephan Schiffels
stephan_schiffels at mac.com
Thu Jun 13 06:09:26 PDT 2013
On Thursday, 13 June 2013 at 12:29:57 UTC, Simen Kjaeraas wrote:
> On Thu, 13 Jun 2013 14:17:22 +0200, Stephan Schiffels
> <stephan_schiffels at mac.com> wrote:
>
>> For example, is there a way of instantiating an object
>> normally (i.e. mutable), and then later "freeze" it to
>> immutable via a simple cast or so?
>
> In std.exception there is assumeUnique. It's basically just a
> cast, but
> might be good enough for you.
I see, will look at that. I actually need it immutable since I am
using it across multiple threads.
More information about the Digitalmars-d-learn
mailing list