• 4 Posts
  • 295 Comments
Joined 1 year ago
cake
Cake day: June 26th, 2023

help-circle







  • Here’s some of my personal complaints. I don’t in general know how to fix them.

    1. proc_macros need their own crate

    2. generics cause problems. Many useful macros can’t handle them. Try using a generic that’s a complex async function, then pass a closure to it.

    3. There’s this kind of weird mismatch where sometimes you want an enum wrapping various types, and in others generics. I find my data flows switching back and forth.

    4. async in rust is actually really good, but go does it better. I don’t think rust could match go without becoming a different language.

    5. Traits are just a big mess. Trait implementations with generics have to be mutually exclusive, but there aren’t any good tools to make them so. The orphaned trait rule is necessary to keep the language sane but is incredibly restricting. Just today I find certain a attribute macros for impls that doesn’t work on trait impls. I guess I have to write wrappers for every trait method.

    6. The “new type” pattern. Ugh. Just make something like a type alias that creates a distinct type. This one’s probably easy to fix.

    7. Cargo is truly great, but it’s a mystery to me right now how I’m going to get it to work with certain packaging systems.

    To me, Rust is a bunch of great pieces that don’t fit together well.




  • There are also video games in libraries, and there are books in libraries with components that are unusable these days. Nobody is required by law to support these components in perpetuity. Nor is any publishing company required by law to maintain support for a book in perpetuity in any way.

    Nor is anybody required by law to help you fix your classic car. People with classic cars spend tons of money to find spare parts or even get them manufactured. This is despite the fact that cars are much more of a necessity than video games.

    Likewise, if you paid a video game to keep their servers open, or paid them for their source code, they’d give it to you. If you paid a smart person to reverse engineer the network protocol and write an equivalent server, you’d have your part.