2 ms·
Seems like you could still have macros, they would just evaluate before type checking. Rust works this way
by brundolf 5y ago
Seems like you could still have macros, they would just evaluate before type checking. Rust works this way
- valenterry 5y agoTo my knowledge, Rust's macros are not generally safe/sound by definition. And that can be a big problem down the line. Compare it to Scala. When they developed Scala 3, they changed macros and dropped a lot of their powers to make the safe/sound by definition and compatible with the typesystem. But they are now severely restricted when compared to Lisp macros. EDIT: here's an example of a discussion about that in Rust: https://github.com/rust-lang/unsafe-code-guidelines/issues/278 https://github.com/rust-lang/unsafe-code-guidelines/issues/2...