Hello,

I'm searching for a software design pattern to deal idiomatically and 
efficiently with memory ownership when wrapping C types.

When wrapped C code returns type, it might require or not to be freed manually 
according to C documentation. How to express a Nim type that can be 
idiomatically tagged as owned or not owned and let =destroy hook run only for 
the owned kind?

Would you suggest an existing Nim codebase that solves this problem 
idiomatically using ARC?

Thanks

Reply via email to