Hacker News new | ask | show | jobs
by pron 421 days ago
That wouldn't be very meaningful. The semantics of Zig's comptime is more like that of subroutines in a dynamic language - say, JavaScript functions - than that of macros. The point is that it's executed, and yields errors, at a different phase, i.e. compile time.
1 comments

You can do that, I think, with EVAL-WHEN.