Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Is this different from NSAutoreleasePool, which has been around for over 30 years?


NSAutoreleasePool keeps a list of autoreleased objects, that are given a "release" message when the pool goes out of scope.

`@pool` flushes the temp allocator and all allocations made by the temp allocator are freed when the pool goes out of scope.

There are similarities, but NSAutoreleasePool is for refcounting and an object released by the autoreleasepool might have other objects retaining it, so it's not necessarily freed.


Implementation-wise yes, very different, idea-wise not really. The author of C3 is a fan of Objective-C.




Consider applying for YC's Fall 2026 batch! Applications are open till July 27.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: