HN user

Joshringuk

4 karma
Posts0
Comments7
View on HN
No posts found.

I would agree for the most part but I found C3 to be a significant simplification over Zig. I struggled very hard with Zig but found C3 to be much more straightforward.

Syntax wise it's different but philosophically it is quite similar to Go's strive for simplicity, but less extreme, much lower level and more C like syntax.

Yes the temp allocator will remove things at the end of it's scope. It makes it very clear when memory will be affected and gives predictable code execution.

There are other contexts for managing mutex locks so they auto close and you could dream up one for database connections and transactions too.

The nice things about a context is you can always see it's there, destructors by design are a bit hidden which can make code harder to reason about.