News for hackers. Stuff that matters.
Re:Android's new Bluetooth stack rewrite (Gabeldorsh) is wri... by zozbot234 on Wednesday March 31, 2021 @12:17PM (#26649149)
Meta-programming needs in Rust are addressed by macros. There's not really anything missing there compared to what C++ does via templates.
Re:Android's new Bluetooth stack rewrite (Gabeldorsh) is wri... by steveklabnik on Wednesday March 31, 2021 @12:34PM (#26649373)
IMHO, you're a bit too far in the other direction; there are areas where we've been working on actively improving, and there are still some things that C++ folks really miss in Rust. Doesn't mean we'll add all of them, of course, but there is desire for more, for good reasons.
Re:Android's new Bluetooth stack rewrite (Gabeldorsh) is wri... by kevincox on Wednesday March 31, 2021 @12:51PM (#26649643)
There are generics and dependent types. But these are still gaining features and not nearly as powerful as templates and SFINAE. (but way easier to understand)

Macros are an option but don't have access to the same type information so often they solve different problems.