

The term “meta-programming” had me lost since I’m only familiar with that in reference to C++ templates (and Rust’s generics are more like templates).
Yes, like C++ template and macros. The kind of code that generates new code before being run.
So to answer your question as to why there are macros, it’s because you need to generate code based on the input. A function call can’t do that.
You can design a language where you don’t need to generate code to accomplish this. My question isn’t why this is necessary in Rust. My question is why Rust was designed such that this was necessary.
Someone mentioned elsewhere that this allows for compile-time type safety. I’m still trying to wrap my head around how that works.





For the problem of linking back to your instance, I wonder if it would make sense to define a new URI scheme for fediverse links. Websites and apps can handle it directly when a user is logged in, or let an external app handle it otherwise.