4 ms·
>(Zig is eating Rusts lunch in that department) I mean, has it? I find the way it works in Zig rather clunky, and unless I'm missing something (and I know comp
by mardifoufs 2y ago
>(Zig is eating Rusts lunch in that department)
I mean, has it? I find the way it works in Zig rather clunky, and unless I'm missing something (and I know comptime reflection isn't the same), I just usually end up needing or wanting something closer to c++ templates or even consteval/constexpr. Again, I'm pretty sure this is a total skill issue and just a lack of imagination from my side, but I don't see what I could do with zig that I can't with c++ (I'm specifically referring to comptime here). I know the difference in theory, as c++ doesn't have actual reflection, but I wonder what's the practical difference in use cases.
(In fact I used to think that not having a separate metaprogramming language was awesome, as I really disliked the language inside a language that are c++ templates but I'm not sure I agree anymore. Especially with additions like constexpr/eval)