Ranter
Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Comments
-
Curious to know why since I like a lot of Rust design. Don't like the overly political environment it has though.
-
Some things are really weird tbh or hard to grasp (like that enums are more what unions are in most modern languages).
But aside from that, I regard it as a unicorn language with a ridicules learning but a similar ridicules reward for surviving it.
As far as I understand it, the language took some good things from ancient languages (fortran, haskell, ...) as well as some "university languages". That combined with the borrow checker makes the language pretty hard and unfamiliar initially.
Btw, someone made a talk, where he took bad parts from many languages and made up a new worse one. Funnily enough he didn't take anything from rust and even praised it: https://youtube.com/watch/...
Edit: Little tip. Use rust-analyzer over the offical rust extension (which usually is outdated rls). For example in vscode. Not sure if intellij uses the r-a by default. -
@t3b4n it can, I can do what I want in php without overly confusing compiler bitching syntax because guess what? php is for web development...... your question makes no sense
-
The answer to a better c++ is not Rust, it is honestly learning proper c++. Rust has no space in: game development (C++ is still king here) low level development (C reigns here), application development(go, java, c#, c++ and many other live here) etc
I don't get the appeal of rust, by the time I am done learning how to program in Rust I can just get good with the proper new standards of c++.
As a web developer, Go makes way the fuck more sense, garbage collected I know. But I don't get the examples that I see "say you forget to free memory when you use malloc" then....just don't fucking forget?
"Say you forget to do x when you are working with multiple threads" ok, then just don't fucking forget?
like I don't get it, Rust seems to appeal to people in high level enterprise development scenarios, for which getting a job is hard, if you forget the cases in which Rust protects you then you are a noob, so, don't apply for those jobs? -
Rust does many things right.
Borrow checking isn't just about memory safety. One of rusts approaches is in general concurrency and preventing data races (not race conditions).
Grumpy me doesn't like _everything_ Rust has - but one must admit that attacking the 3 hardest things in programming (owner / lifetime handling, concurrency and memory safety) in a language is no small feat.
Yes, understanding the borrow checker is hard - but the same is true for understanding and preventing any of the 3 problems it solves.
I still dislike the (necessary) of unsafe + but it seems to have gotten better the last years.
Plus rust does has a nice evolving model and a root foundation of splitting things logically up:
- core
- alloc
- std
Many cargo packages adapted to only rely on the rust core/alloc part - no_std .
It's one of the things that makes rust very viable for writing firmware / kernel / bootloader code.
An interesting nitbit - cause firmware / kernel / bootloader's are another security nightmare.
So saying that the language was intentionally designed to be bad - nope.
It's hard and I don't like the syntax - but Rusts base principle and foundation is very solid and tried from the beginning to not only incorporate other languages features / styles, but also maintain a strict course of being as universal usable as possible.
Last but not least - Rust links statically, which is possible with Go, too.
Meaning that you can easily distribute a single binary without any form of dependencies.
Static linking has it's downsides, yes.
But if you look at e.g. prometheus exporters and other critical stuff, it has the very highly favored upside that distribution becomes far more easy.
Which is for security and critical things like monitoring really important.
Replacing a single binary is a lot easier than having to update a whole system and playing whack a mole with dependencies and possible runtime errors ;) -
Everybody hates Rust when first learning it, been there too. People hate what they don't understand. But you get over it. You got this!
-
@12bitfloat not everybody, but I guess it’s easy to get frustrated when learning Rust. I like to apply this thinking to all learning that it can be applied to: first understand, only then learn. Learning something hard gets much less frustrating when you get the whys behind it all.
-
Actually, if you really want a prime example of a bad language on purpose, try MUMPS.
Related Rants
I started learning Rust and now I know the answer to the question "What would a programming language look like if the engineers were tasked with designing a bad programming language on purpose"
random
rust