I ported my Deque from a class to a struct. http://dpaste.1azy.net/cc983a8d
It uses a ref counted payload which holds a pointer to a chunk of memory.
A helper function called createDeque was created to get around the struct ctor stuff.

While implementing I ran in some problems. Like:
http://d.puremagic.com/issues/show_bug.cgi?id=9401 This goes for all attributes as Maxin Fomin correctly says. http://d.puremagic.com/issues/show_bug.cgi?id=4338 This is sort of annoying but I got past it by doing some bad casts. A @trusted { at the beginning of the file is not horored by the compiler created methods.

Somehow "new" now creates segfaults (run the code and see the Appender die). I have no idea what I do wrong. When main is left another segfault occurs while joining running threads (I did not create any Threads explicitly).

It would be nice if somebody could take a look and give me some pointers.

Best Regards
Robert

Reply via email to