Program crash: GC destroys an object unexpectedly

user1234 user1234 at 12.de
Mon Sep 13 17:56:34 UTC 2021


On Monday, 13 September 2021 at 17:54:43 UTC, eugene wrote:
> On Monday, 13 September 2021 at 17:40:41 UTC, user1234 wrote:
>> The problems seems to lies in `newSignal()` which "would" not 
>> allocate using the GC.
>
>     final Signal newSignal(int signum) {
>         Signal sg = new Signal(signum);
>         sg.owner = this;
>         sg.number = sg_number++;
>         sg.register();
>         return sg;
>     }
>
> full src is here
> http://zed.karelia.ru/0/e/edsm-in-d-2021-09-10.tar.gz

thx, so the problem is not what I suspected to be (mixed 
gc-managed and manually managed memory). sorrry...


More information about the Digitalmars-d-learn mailing list