Hey guys, what does this error mean:
.local/usr/dmd-2.111.0/linux/bin64/../../src/phobos/std/internal/memory.d(39,33): Error: fakePureCalloc cannot be interpreted at compile time, because it has no available source code
I have a class:
import std.container.array : Array;
class Sieve(K, V)
{
alias kvtuple = Tuple!(K, V);
struct cdata
{
kvtuple data;
cdata* prev;
cdata* next;
bool visited;
}
cdata* head, tail, hand;
Array!(cdata) arr;
int count, len;
this(int l = 1021)
{
len = l;
arr.length(len);
}
... do more things
}
works when I do:
Sieve!(string, int) sieve = new Sieve!(string, int); sieve.arr.length(1021);
and remove the constructor.
Permalink
Reply