this post was submitted on 30 Sep 2023
61 points (85.1% liked)

Programming

17497 readers
35 users here now

Welcome to the main community in programming.dev! Feel free to post anything relating to programming here!

Cross posting is strongly encouraged in the instance. If you feel your post or another person's post makes sense in another community cross post into it.

Hope you enjoy the instance!

Rules

Rules

  • Follow the programming.dev instance rules
  • Keep content related to programming in some way
  • If you're posting long videos try to add in some form of tldr for those who don't want to watch videos

Wormhole

Follow the wormhole through a path of communities [email protected]



founded 1 year ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
[–] [email protected] 3 points 1 year ago

Oh, well, I hope, it was clear that the third and fourth code sample aren't actually valid Rust, but yeah, I did write them to look like typical Rust production code.

And yeah, that article is great. I feel the same way, the semantics are just different. And whether you like those semantics, depends on what you're doing.

If you're just writing a quick script where you don't really need error handling and you probably won't have more than a few files etc., then Rust's semantics can be painful.
But if you're writing a larger application, then Rust's strictness and explicitness often just portrays the reality you have to deal with anyways. And it makes you deal with it right away, which can be frustrating at times, but overall feels like it boosts my productivity.