Error instantiating std.container.Array
Tobias Pankrath via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Mon Mar 2 07:55:06 PST 2015
On Monday, 2 March 2015 at 15:14:49 UTC, Francesco Cattoglio
wrote:
> On Monday, 2 March 2015 at 15:01:55 UTC, Tobias Pankrath wrote:
>>> I'm really clueless... :P
>>
>> Something is wrong with your Material class, but you'll need
>> to show us a reduced example.
>
> After a really long time I finally found what was wrong.
>
> http://dpaste.dzfl.pl/16d202b7124d
>
> Wow, I honestly could have NEVER foreseen this.
> This is all it takes for a class being unusable in a
> std.container.Array
> class MyClass
> {
> void init();
> }
.init is a special property of every type:
http://dlang.org/property.html#init
More information about the Digitalmars-d-learn
mailing list