Challenge: write a reference counted slice that works as much as possible like a built-in slice

deadalnix deadalnix at gmail.com
Wed Nov 10 17:27:24 UTC 2021


On Wednesday, 10 November 2021 at 14:47:34 UTC, Paul Backus wrote:
> Destroying .init works fine here. `free(null)` is guaranteed by 
> the C standard to be a no-op.
>

Decrementing the reference count is going to segfault if the 
pointer to the owner is null.



More information about the Digitalmars-d mailing list