← Back to context

Comment by givemeethekeys

3 days ago

This looks like Zig. What problems does this solve that Zig doesn't? Potato - potaato?

C3 is more comparable to Odin or the Better C mode in D in that it tries to be a pragmatic evolution not revolution of C.

Here is a comparison to Zig in terms of features: https://c3-lang.org/faq/compare-languages/#zig

And yes, they are all system programming languages with a similar level of abstraction that are suited for similar problem. It is good to have choice. It is like asking what do you need Ruby for when you have Python.

Looks can be deceiving.

C3 provides a module system for cleaner code organization across files, unlike Zig where files act as modules with nesting limitations.

C3 offers first class lambdas and dynamic interfaces for flexible runtime polymorphism without Zigs struct based workarounds.

C3s operator overloading enables intuitive math types like vectors, which Zig avoids to prevent hidden control flow.