6 ms·
And way, way better compiler errors thanks to a sane generics system
by blakehawkins 4y ago
And way, way better compiler errors thanks to a sane generics system
- bbojan 4y agoI think you meant thanks to a sane(r) macro system? Both Rust and C++ use monomorphisation for generics, I believe shitty compiler errors are due to C++'s templating.
- throwaway17_17 4y agoI’m what way can you have ‘generics’ in C++ that are not based on templating? I am almost certain that any implementation of anything ‘generic’ templates are inherently involved. Maybe I’m wrong about what you mean by generics though.
- estebank 4y agoThere are concepts now which are close enough to Rust's traits.
- benreesman 4y agoAnd much better compiler errors. `rustc` about leads the pack on error messages of all the languages I use regularly.