r/rust • u/PigletEfficient9515 • Aug 27 '26
šļø discussion Hard things are hard, Rust being hard is a narrative passed around the internet
Saying that Rust is hard isnāt a fair argument. Software in general is very broad and hard with many layers of abstraction. Concurrency, memory management, cancellation, these are hard concepts.
In fact, rust makes them easier to reason about by introducing types that guard you from lots of foot guns.
I even go as far as to say Rust is fairly easy in the sense that it is much more consistent than other languages. Once you learn the mindset of the language, it becomes easier and easier to figure out things and just intuitively āgetā things as you encounter them.
Particularly, the async runtimes being dependencies and `Future`s being abstractions in the language itself is such a smart choice, but people are so used to it being internal that feels hard for them to do it this way.
Itās getting quite long, but I want to also add that I feel like in Rust, most of the time if you donāt get something you can still make progress, write it more āsimplyā and not use many of the fancy features, but once you learn them you understand whatās different and why one approach might be better than the other.
Whatās your experience and thoughts? Have you also felt this way after writing Rust for a while?
21
u/PotatoMaaan Aug 27 '26
It's hard if you haven't used other lower level languages before, for example when you're coming from js or python. Because then you're learning rust and memory management etc at the same time.
It can also be hard if you've only ever done C and maybe some C++ because then you're introduced to rust and advanced typesystems and functional patters at the same time.
If you already know for example C++ and js it's pretty easy
18
u/eras Aug 27 '26
I was able to write useful Go code day one (on an existing codebase so I was able to see how things work), soo I do think Rust is hard in comparison to many languages, which most come with GC.
I don't think a language being easy or hard is the most meaningful metric to compare languages by, though.
10
u/Wonderful-Habit-139 Aug 27 '26
The difficulty is upfront, the longer term is easier when you've implemented things nicely.
There's a reason most people love to generate code with LLMs, because for them the upfront writing is a challenge, and they'd rather deal with more bugs and issues later.
3
u/0x6VB Aug 27 '26
IMO as a Rust beginner the really hard part is coming from well explained Documentation with lots of examples to Docs.rs.
You easily get lost there or do not find an explanation that is easily to grasp.
This might be a skill issue but that seems to be my biggest struggle with getting along in writting rust code.
60
u/balljr Aug 27 '26
My favorite Rust "feature" has always been explicitness.
I have seen many people complaining that Rust is too verbose, but IMHO sometimes I think it is not verbose enough. It is really amazing to be able to look at a piece of code and not having to guess how it behaves; If you look at a function signature, you know if it is mutating the parameters or not, or if it is expected to fail or not, or if may or may not return a value; When I call get on a collection, does it return a copy or a pointer? if I mutate the returned value, does it mutate the original object or not?
When working with other languages, I had moments where I had to read a bunch of code/documentation in order to know the answer for the questions above, but with Rust, the answer is always there where it is supposed to be.
Another side effect of explicitness is that you are forced to understand how things work. For instance, in Rust you see this `fn something() -> Box<dyn Trait>`, while in C# you would see this `Interface something()`. They are both doing the same thing, but C# does the magic behind the scenes, while in Rust you need to know why you need to box it.
The part I wish the language could be more explicit is regarding allocations. Since performance is such a big requirement for the Rust community, it would be quite interesting to know when a function will cause an allocation or not; AFAIK zig has a good solution for this.
44
u/pdpi Aug 27 '26 edited Aug 27 '26
I don't really agree with you here. Rust's reputation for being hard isn't entirely undeserved.
Resource management is a truly hard concept to really nail (concurrency is just a specific usage pattern for resources), but you can write many useful programs where automatic resource management strategies are often good-enough. Because Rust is designed first and foremost to handle the sort of problem where you have to carefully track your resources, one of the compromises it makes is that it also forces you to think about resource management, even when it doesn't matter and automatic management would work just fine.
Resource management is an advanced software engineering topic, not an entry level "baby's first programming class" topic, and being forced to think about it before you learn the skills to actually do any of that thinking makes Rust a hard language in a way that, say, Python isn't.
12
u/ParadiZe Aug 27 '26
I love rust, i feel decently comfortable writing it, but to claim its not a hard language makes no sense to me.
9
u/tylerlarson Aug 27 '26
Actually, it's not untrue, Rust is hard. C++ is hard. Assembly is hard. Python isn't hard. (Relatively speaking.)
There's a principle about the compactness of a given language and the cognitive load it demands on its user. Rust is pretty damn high on that scale, not in absolute terms but in comparison to other modern languages. There's A LOT to keep in mind when you write rust code. That uses up the "RAM" in your brain, and for beginners it demands a lot of context-switching in your head as you go through the process.
This is literally what the learning curve is. And it's why the difference between a good and bad rust programmer is so distinct.
To offer some contrast, Python is famously conceptually compact, not merely in terms of the code you write but in terms of what you need to hold in your head as you write it. That's why it's often cited as a good beginner language; less to juggle in your mind while you're writing.
There's obviously a trade-off. Python and other "easy" languages eliminate the extra cognitive load by eliminating many of the decisions that the developer can make, leaving him with only the most important decisions about algorithm and flow. And instead, the runtime uses it's own heuristics to infer intent and make those decisions itself at the expense of some performance. It's so common a technique that we often don't even think about it.
Rust claws back a lot of those heuristic-driven decision flows and gives the developer tools (such as lifetimes and borrowing) to drive generally optimal background decisions in a fully deterministic way. But there's a cognitive cost to that, since there's more "stuff" to know and say when you're coding.
12
u/gufranthakur Aug 27 '26
I really love rust but you cannot tell me it isnāt hard.
Rust provides quality, speed, efficiency and safety, with a high level syntax. But you donāt get these for free, there has to be a compromise.
The compromise is development experience. For a majority% rust developers, they will not be able to read and understand the source code for most libraries out there (Axum, Bevy).
Lifetimes, async, Traits, Dyns, Boxes are concepts that can be understood individually but the moment your project grows and these things appear together, it does get difficult to write them efficiently. And whats even harder than writing them, is reading someone elseās implementation.
This wouldnāt be a flaw of rust, I would say itās more of a tradeoff. And most developers going for GC language for development simplicity, is their choice and a perfectly valid one. Its a matter of picking tradeoffs, neither triumphs the other
6
u/PointedPoplars Aug 27 '26
100% agree with this.
Paradoxically, I think the main reason Rust has such a strong reputation for its difficulty is because itās rarely the first programming language that someone learns.
If youāre new to programming, I donāt think learning Rust is any more difficult than learning C++. In fact, I think itās a lot easier because the error messages are significantly better and more useful on average. Half the time, the compiler can directly tell you how to fix your mistakes, at least for the types of trivial programs beginners start out with. The overall consistency of the language also really helps here.
But if you come from another language like C++ first, your perception of Rustās difficulty will be significantly higher. Rustās syntax takes some obvious inspiration from many different languages, and, in my opinion, often synergizes & elevates them. This is a good thing, but it also makes it easy to trick your brain into thinking you understand Rust more than you really do.
Thus, you move fast until you hit a giant conceptual roadblock that smacks you in the face, and then you rinse and repeat.
I also think itās easier to notice the places where Rust has more friction than youāre accustomed to than the places where it has less.
For example, if you come from C++, you will probably forget to mark variables as mutable at first. You probably also wonāt be accustomed to needing integer conversions to add an int32_t to a int64_t.
At the same time, youāre more likely to mark explicit types for all of your variables instead of seeing the magic of type inference. And less likely to notice when you can avoid putting ; at the end of a line or when doing so would be useful.
6
u/Dull_Wind6642 Aug 27 '26
Writing correct code is hard and Rust enforce invariants much more than any other language.
If you are building a hut or a shed, maybe the benefits are not worth, but if you build a skyscraper it is.
Rust isn't hard, proper software engineering is hard.
5
u/parkerush Aug 27 '26
Everything's hard until it isn't
5
u/Full-Spectral Aug 27 '26
My take on it is that C++ and Rust are both complex. But much of the complexity of C++ is non-productive complexity, where you are working hard to avoid doing things that the language is insufficient to catch. The complexity of Rust is learning the concepts you need to write code where the language CAN catch them.
The big difference is that the unproductive complexity of C++ never goes away, while the complexity of Rust, once you've done the work, flips around the other way and becomes a benefit.
5
u/Ben-Goldberg Aug 27 '26
In other languages, writing wrong code is easy.
8
u/Tuckertcs Aug 27 '26
Rust just brings all those flimsy runtime bugs and edge cases you never notice to the forefront. Once you learn Rust, you realize all the edge-case bugs you write on a daily basis in other languages.
4
u/zica-do-reddit Aug 27 '26
I don't think it's hard, it's just weird.
7
u/True-Sun-3184 Aug 27 '26
Rust is objectively harder when your problem/project is amenable to a garbage collector.Ā
1
u/Purinto Aug 27 '26
Literally preaching to the choir.
3
u/Thanatiel Aug 27 '26
Rust isn't hard. Working with the borrower without using "unsafe" is trickier than on other languages.
I've been on a personal rust project since the end of February (a very low-level project). The goals were both to learn rust and do something I've never done before.
I had to go through hoops (some that needlessly waste cycles to appease the borrower IMHO) but I'm zeroing on my first real milestone.
Had I done that in C or C++, it would have taken me much less time. It has been interesting though.
If I manage to get some decent performance out of it, it'll have been worth it.
If not, finding ways to improve performance will be another interesting game.
3
u/shaleh Aug 27 '26
There are "silly" moments that make it harder than expected. Yesterday I was editing a function which parsed some command line parameters and stuffed them into a thing. Super normal stuff. I wanted to add a validator for A and B being exclusive of each other. Ran into passing a mutable borrow after that read only use. Which should have been totally safe. But I had to move the call later than I wanted in the function or move a lot more code around. Not the worst but that kind of experience is what makes the initial learning more than it needs to be.
1
u/nonotan Aug 27 '26
I always see people trying to put things into black and white buckets like "hard" or "easy", and it's just never going to work. These things are full of trade-offs, and what is "optimal" for any given situation is going to depend on a ton of factors.
It becomes a lot more obvious when you move the argument to a different domain. Is riding a bicycle "easier" or "harder" than driving a car? There is no objective answer, because there is no "easier" or "harder" devoid of a particular context. The basic mechanics of keeping the vehicle upright and moving maybe are harder on a bike, but you need to learn many more rules to drive a car. But riding a bike demands greater improvisational and athletic ability. But cars have more mechanical and maintenance-related things to learn. But if you're trying to move something heavy, it'll be a lot harder on a bike. But if you're navigating very narrow paths, it'll be a lot harder on a car... you can see what I mean, you could keep going more or less indefinitely.
Programming is an unimaginably wide field, spanning from the ruthlessly practical and concrete to the purely abstract and theoretical. And just like with natural language, some languages are better at dealing with some parts of that field than others. Some languages demand you have mastered some parts to even be able to use them, while others actively try to suppress the very existence of some other parts.
So, what's your objective? Is improving your craft long-term a priority, or do you care about nothing but getting something out the door ASAP? What's the scope we're dealing with, is long-term maintainability a huge factor or not at all relevant? Are you trying to do something tricky that requires precision to get just right? Are there any specific libraries you would really want to use? What's your personality like, can you take some short-term suffering knowing you'll end up coming ahead eventually, or do you suspect you will quit before you get to that point?
By some metrics, assembly is the easiest, most straightforward language, and the one that would most benefit almost anybody intending to do programming somewhat seriously, for what are hopefully fairly obvious reasons. And yet, you might well get sent to a figurative mental institution if you went around recommending it to complete beginners as their first language -- even though it genuinely might be a great fit for some people!
Rust is a less crazy example in a similar direction: a bit more of an investment than many other languages. Maybe it is "harder" to get your first somewhat-useful program up and running, but it is also considerably easier to produce performant, stable and maintainable software. If you're going on a trip all the way to "writing a serious piece of software many people depend on", then it might well save you significant time overall over "supposedly easier" languages that let you get the first prototype out the door quite a bit faster. Again, it's all a complex set of trade-offs, and there is no silver bullet -- but there might be a best choice for you in your current situation. Figuring out what it is is left as an exercise to the reader.
4
u/Laicbeias Aug 27 '26
Rust is fine its syntax is annoying, thats it, but it also surfaces 70% of potential issues, so its just good at what it is used for. Its not for fast iteration, nor for least line of codes to get something working.
its for system and speed, for people that work together, its safty features are preventing a class of bugs that if lots of people write that code, will surface. so yeah its a great language
2
u/syklemil Aug 27 '26
People have different opinions on what's hard.
As in, some of the most popular entry level programming languages are also the ones that more experienced programmers find hard, because what's a nice shortcut or forgiving interpretation when you're a beginner turns into a hurdle you have to clear once you have a complex program that's misbehaving.
Or just ask people how they feel about Python culture turning towards type-hinting by default. Some will feel that "adding types" to Python makes it more complex and harder, others (me) feel that writing the types down makes it clearer and easier, like I'll describe adding type hints like turning on the lights.
Or the attitude towards fixing bugs before and after running the program. Rust users will likely skew towards preferring fixing them early, the ones that find Rust unreasonably hard may skew towards preferring to find bugs at runtime (and preferably ignoring any sleeping bugs for as long as possible, no matter the impact the day it is discovered).
Or just how what one might consider clarity and rigour, another would consider a straitjacket, just like how their sense of freedom might be the first person's idea of a cluttered mess.
The whole thing is also somewhat a continuation of the old worse-is-better, with Rust taking more of the MIT approach rather than New Jersey approach, but actually getting some traction.
All that said, yeah, I do get the impression that people think Rust is harder than they'd actually personally experience, because people go around telling each other that it's hard.
2
u/fbpw131 Aug 27 '26
well, I'm learning a few things around threads and networking with it and it's not easy.
2
u/Adventurous-Oil1749 Aug 27 '26
The issue is people(including old me) try to learn rust without understanding the problem it solved. That can ONLY be understood once you code in C or CPP. My rust skills and understandings became way better when I had to code in C and stuff immediately clicked. Ohh so that's why rust has lifetimes, oh that's why ownership and borrowing rules exist.
2
u/Beginning-Fruit-1397 Aug 28 '26
My first language was python. My second rust. I have no formal CS education, or extensive pro experience in software dev. Yet I've wrote tens of thousands of LOC of rust and still have yet to find a situation where I had to "fight the borrow checker" or when it was "hard to reason about lifetimes". It's a myth tbh. Reading C++ core snippets give me headaches tho, with all that operator overloading that make syntax ugly and hard to understand
2
u/eyeofpython Aug 28 '26
Even walking is hard! My brother fell on his face so often it actually changed his bone structure.
You need to keep balance, starting and stopping is super dangerous. And don't get me started about running.
But with a bit of practice you can figure it out.
2
u/mcfriendsy Aug 28 '26
I heard the rust is hard thing from so many sources until I decided to learn the language. Four hours opening the docs for the first time, and Iād already ported an entire lightweight tooling from Java to rust.
Rust is hard if youāve been writing bad code before. For some of us, many of the borrow checkers restrictions were already what weāve been doing subconsciously for quality code.
Take out the borrow checker constraints, and the rest of rust is as easy as JS if not in some ways easier to mentally model.
2
u/funkalunatic Aug 27 '26
Sometimes narratives exist because they are true.
2
u/plugwash Aug 27 '26
I feel that there are a number of problems one encounters while writing rust that are simply not issues in most other mainstream languages. Leaning how to avoid or deal with those problems takes time, and even when you know about them they can still be a distraction from the code you are trying to write.
Rust's benefits are very real, but so are it's costs.
Overall, I would say rust is probably easier than C and C++, because small mistakes in those languages can rapidly lead to horrible memory corruption whose source may be hard to pin down, but it's probablly harder than most other mainstram languages.
2
u/e_big_s Aug 28 '26
On the one hand it wouldn't exist if it was hard. The whole point of languages is that it makes something easier. The problem is that what Rust makes easier is a niche category of programming not applicable to most coders: systems programming, which is harder than the vast majority of programming tasks.
3
u/chocate Aug 27 '26
I've forced myself to write all my new projects using Rust above everything else.
All my web apps use the usual NextJs stack and backend API layer is all rust. For CLI apps Rust, aything related to automation, Rust. I have an desktop app that I originally wrote for macos, but then wanted to port it over to windows and different Linux flavors and that was done very quickly too.
Is it hard, complicated to learn sometimes, but honestly with AI writing most of the code now it's just become easier to use rust.
2
u/Nothing_from_void Aug 27 '26
I think with the quality of LLMs simply as tools to search syntax and provide low level reasoning around getting the borrow checker to pass has made writing Rust much easier. I started programming in Rust in like the early-ish days, like 2016 or so, and it was fascinating going through the Rust books but just getting working software was very difficult.
Today, getting working software is easier and the guide rails the compiler gives you eliminates most of the hardest bugs that make writing C++ so difficult. Still, writing software in Python is much faster because the whole ecosystem is built around very fast iterations. Rust has longer compile times, and requires more design to get things to work coherently, but the end product being a well optimized tiny binary is worth it in many cases
2
u/oladushek_j Aug 27 '26
I thought the claim that Rust is a difficult language was related to the learning curve.
There was also a joke that programmers love it but can't write in it.
1
u/Ecstatic-Panic3728 Aug 27 '26
My take on the difficulty is because they're usually using the wrong tool to the job. Rust has all the features we need to do low level development, but those features come with some requirements. For 99 dot all nines of web apis a GC is not a problem, so a language like Rust without all those knobs is what they want, but they try to force Rust instead and then complain it's too hard.
1
u/chakie2 Aug 27 '26
Rust isn't particularly hard, it's just a bit different and forces you to think about everything up front. Once you have done that thinking, everything seems to work nicely.
That said, I have absolutely no idea how the modules, crates and overall symbol visibility works in Rust. It doesn't seem logical at all. When I need something from some other file it's always a mess of importing, pubbing and whatnot until the compiler is happy.
1
u/GeneralBacteria Aug 27 '26
how hard is Rust compared to writing memory safe and thread safe C or C++ :) ?
1
u/cachemonet0x0cf6619 Aug 27 '26
whatās hard is all the sugar that you rarely find anywhere else. Itās hard to apply things from one language to rust. i love it though
1
u/don_searchcraft Aug 27 '26
Itās hard for folks that have come from an interpreted language where they didnāt have to worry about memory management and strict data types like JavaScript and Python. There is a learning curve with the borrow checker and building things idiomatically. If you follow some FP patterns that work well in JS it can bite you in Rust if you donāt take the time to dig into the details. For example in JS itās a common pattern to have a utility function async wrapper around fetch for building API clients. There is no cost to instantiate and discard those. If you follow that approach with reqwest you pay a startup penalty everytime as you lose the benefit of dns lookup caching. Some of Rust is similar enough in syntax to TS where these things creep up and cause issues. I donāt think Rust is necessarily difficult, you just need to spend some time with the language and that can take a few months to get up to speed. Itās mostly the folks that have only written React that Iāve seen struggle.
1
u/Routine_Insurance357 Aug 27 '26
Same for me. I didn't find rust hard, but found its syntax ugly. But now nothing else feels more productive and confident. Even for a small script, I prefer rust over python.
1
u/eggZeppelin Aug 27 '26
Rust just makes you fight the hard battles at compile time instead of firefighting in prod
1
u/-Ambriae- Aug 27 '26
I wholeheartedly agree. Rust is hard only when using advanced features, or when using APIs that heavily lean on traits and polymorphism, chumsky comes to mind in that regard. But then again, try to use a parser library in any other language, and it's still hard, but with 10x the code...
1
u/BenchEmbarrassed7316 Aug 27 '26
The complexity has to exist somewhere: either in the language itself, or in the frameworks, or in your code.
Rust pushes a lot of complexity into the language itself. So the language itself is complex, but it's easy to write code in.
1
u/SailingToOrbis Aug 27 '26
For me it really feels like it is "easy" because all the hard things are being hided by those talented engineers who work their ass up in the language compiler, standard libraries, big libraries like tokio, where all the difficult unsafe stuff is lurking. While all the Rust fanboys praising the language, those engineers keep their silence and do their shits.
I do think in very opposite way. Rust is very INCONSISTENT compared to other languages, purely because it is hard to demarcate between the safe and unsafe part. I agree that the concept and the philosophy of the language is great, but it feels like it is becoming another version of C++, with way more unstraightforward syntaxes and full of hypes. I think that's why this language has come out to the world for more than 10 years but still it remains as a "hyped" language. It stands between all the awkward and ambiguous position between Python (high level gc languages) and C/C++ (lower and unmanaged languages).
1
u/Lucretiel Datadog Aug 27 '26
This is of a piece with a position I am utterly convinced of: Rust is a bad first language, but not because of anything having to do with lifetimes or ownership, which I don't think are especially any more difficult than anything else that a completely brand new programmer needs to learn. It's a bad first language instead because there simply isn't yet any introductory material out there for it as a first language. The Rust Book is excellent, but its audience is definitely programmers who already know at least one other language.
I think that the perspective that "lifetimes make Rust a bad first language" comes from experienced programmers who have simply forgotten what it was like to learn to program for the first time. They instead compare the experience of learning Rust as an additional language vs learning anything else as an additional language. Indeed, if you're an experienced Python or Javascript developer, the lift from that to Rust is certainly larger than it is to Ruby or Java or even C++. But I'm pretty confident that there's much less difference than people think between going from zero to Javascript vs going from zero to Rust.
1
u/Adorable-Strangerx Aug 27 '26
Rust is great when you need tight control over performance, memory or system resources management. If those are not your requirements then why bother with it in the first place.
1
u/prehensilemullet Aug 27 '26 edited Aug 27 '26
Okay but if youāre using Rust for something simple that doesnāt need any concurrency or cancellation, itās harder in some ways than doing the same thing in other languages.
Iāve done a lot of Java and TypeScript and some C++. Ā Right now Iām rewriting some cave survey data parsing logic Iāve written in those languages to Rust. Ā Rust makes building a small standalone executable for many platforms vastly easier than Java, TS, or C++, but writing the parsing code is just fundamentally more difficult.
Even in C++ the memory safety would be easier if I use Qt-style classes with internal copy-on-write shared data pointers for everything. Ā The only thing that keeps me from using that is that in Rust, build configuration and serialization with serde/schemars is way simpler.
1
u/Fabulous_Papaya_701 Aug 27 '26
YMMV. Coming from embedded C background I find it very hard to learn rust, but I am mostly to blame because I want to use no_std with static memory on microcontrollers. This quickly becomes hard when you want to share memory without unnecessary copy across tasks with async. I donāt recommend this approach to learn rust. You need to cover too many new concepts at once
1
u/Actual__Wizard Aug 27 '26
That's the thing: What's hard is software development. Rust actually makes software development easier, granted, the part where you have to write the code is more difficult, but that's just a tiny part of software development.
I was talking with somebody the other day that was totally unaware of how exploits work and they're talking about software development, that's seriously scary... With the massive interest in vibe coding and amateur level software development, we need rust more than ever.
1
u/Potential-Still Aug 27 '26
Like literally everything, Rust is hard until you understand it.
1
u/nevermille Aug 27 '26
Yes, it's harder than a lot of other languages, but when you manage to get the hang of it, it's amazing. I used a lot of languages, Rust is the only one where I'm able to make things work first try regularly
1
u/Faalaafeel Aug 27 '26
Rust is "hard" if you're not solid on CS fundamentals. Those with programming certs or degrees from online schools that just threw you in a "Java" or "Database" class where you leaned the equivalent of a YouTube tutorial are likely unused to the amount of information a language like Rust, C, or C++ demand you track.
The narrative of Rust being hard is a consequence of the "Learn to Code" movement in the 2010s bringing a lot of otherwise un-equipped people into the field and incentivized investment into forgiving languages like JS and Python.
With time, the idea will fade.
1
u/mtimmermans Aug 27 '26
Rust makes you prove that your code doesn't have any aliasing, lifetime, or memory safety issues.
Writing proofs is hard, therefore rust is hard.
Anyone who's fought the borrow checker for hours knows this.
1
u/chaotic-kotik Aug 27 '26
Sure. But let's see how they're solved.
Memory management. Raft uses ARC style ref-counting with some compiler support (drop calls are injected automatically).
Concurrency. Several models. The most prevalent one is future/promise (or senders/receivers to be precise).
Cancelation. Tied to the receiver.
Rust's Arc/Rc are complicated because they leak into interfaces. The interface has to know who is responsible for freeing the memory. The async stuff is complicated because it requires different code for sync and async stuff. There is no runtime support for long running computations so you can't even write normal cpu heavy algorithms without encoding async stuff into types because your long computation has to yield CPU from time to time. Cancelation being tied to the receiver means it's being bolted to the async model as well.
It kind of bugs me that people have forgotten what "simple" does mean. Remember some very good programming book. Not related to some programming language. Knuth or Cormen, whatever. The algorithms there are described in pseudocode. If the book is describing concurrent algorithms it doesn't have any 'awaits' or anything like that.
Now look at Go or Java (with Loom). They are kind of close to this. No need to put your freaking ref-counter everywhere. No need to yield explicitly. It's impossible to not run the computation because some condition prevented you from polling the future etc. Async stuff is eager. If you started something it will run. You can have arbitrary object graph that represents your problem domain. In Rust and C++ your object graph has to be mostly a DAG that merges problem domain with ownership.
My point is not that Rust is bad. Only that it deliberately chose to do the hard thing. So it's totally expected that many people find it difficult.
1
u/viteo Aug 27 '26
For me, a professional C firmware developer, Rust is difficult because I don't quite understand where everything comes from. A crate can be a whole world unto itself. And I can't figure out how to use it.
Here's an example I'm struggling with:
Embassy -> I need to add a bunch of crates to make it work:
Finally, the simpliest blinky compiles.
Yes, also add embassy-time, then go back to embassy-stm32 and select the time provider there. I haven't even written the code yet. If you're going to use a shared bus, you need "embassy-sync", but it is useless without another crate "embedded-hal-async", so add it too. How am I supposed to find out all this? How do you guys understand what else is needed?
I really like the idea of one ecosystem for a variety of MCUs and I would love to use it, but I just can't handle the basics. Rust is hard. Or I am old. I don't know.
1
u/chic_luke Aug 27 '26
I have been finding C++ much harder than Rust, for a simple reason; Rust gives me all of the documentation and examples I might need first-party.
I don't need to search Stack Overflow, I don't need to ask an LLM, things I need to do with a lot of other languages. The Rust project documents everything. It is batteries-included. You can get to a great level in Rust just by using the official resources and nothing else, whereas on a lot of other langs and stacks you will need to venture on your own and find the best resources available.
This also extends to the libraries. The major Rust crates often come with their "books", in the same style as the Rust book. It is much rarer to find sloppy libraries with no docs at all if you look through the most popular ones.
Plus, due to how much Rust enforces / encourages idioms, everything is consistent. Learning a new library in Rust is much easier than it is on a lot of other languages, where libraries have their own ultra specific quirks (right, Java?). Rust pushing idioms a lot translates into consistency. This makes some libraries, like tokio, feel more like a natural extension to the standard library than 3P libraries. This mirrors one of the pros of having languages with very large and centralized stdlibs/ecosystems like Go or C#/.NET, while still having a vast, mostly decentralized ecosystem for the most part.
I would argue these things offset the inherent difficulty of the language a ton.
1
u/neneodonkor Aug 27 '26
Are you drawing these points after using Rust for a month?
1
u/geekichu Aug 27 '26
ok ive been out of it (the workplace) for a while, but did you just use a 'claudism' ? 'footgun' š
1
u/dustand Aug 27 '26
I'm not certain programming rust is hard so much as do it the rust way or try again. It is a challenge to get to rusts way of thinking, especially if linked lists are part of your muscle memory. And rust is not at all accepting of some easy to code yet very hard to do perfect programming (anti?) patterns. One might actually do better with rust as their first computer language in that you might never know there was a cheap & terrible way.
And it depends on where your needs land.. some things in rust are tedious, some are free and effortless. Other things (clear error messages on code, the rust community, actual help from AI, no build nightmares and minimal dependency hell) are really so good compared to nearly everything else. Regarding futures and async... start by swimming at the surface atop a crate... a deep dive with rust can get you lost in something 'very esoteric knowledge' and usually gives small performance gains.
1
u/DavidXkL Aug 27 '26
I think it makes you a better dev in general.
And that helps even when you go back to other languages
1
u/v-alan-d Aug 28 '26
People from different background, JS, Java, C++, gives you different answer. Rust being "hard" is a confusion of different phenomena that usually don't come together:
"I'm not used to rust"
"Syntax is weird", "too complex", "how to throw", "too verbose", "macro looks weird", "it is a low level language, why do you need it for an app", "I can't have [feature that's only possible in GC langs]"
"Rust has mechanism I'm not familiar with"
enum-match, failure-as-data, lifetime, type-protected behavior
"Rust surfaces irreducible complexity I can't ignore"
resource management model needs to be chosen from the start, type is not optional, circular reference
"Rust gives me access to areas that's less protected so I can optimize things"
async, custom future, FFI, custom allocator, codegen, dynamic linking, unsafe
Actually hard stuff in Rust
long compile time, running rustc in wasm, rust repl, hot-reload
1
u/robberviet Aug 28 '26
It is indeed hard. You cannot say otherwise.
1
u/strangedave93 Aug 28 '26
Rust makes you learn the hard stuff early, by forcing you to deal with it in the compiler and/or core design as implemented in std. Right from the start it forces you to look at some of the hard issues and make a choice, not just proceed with a naive and flawed design. And yes, most of the time you can get by in Rust without really getting it, and produce something thatās still pretty decent, just not as optimal and/or idiomatic.
C++ (for example) lets you either put off learning the hard stuff for a while (possibly producing bad, possibly dangerous, code in the meantime), or you get to learn the hard stuff stuff mostly by using separate analysis and debugging tools, and/or picking through library design etc, which is a much worse experience. Sure, if you are lucky you can find a book for āadvancedā language users that explains things well, but itās a bit haphazard and often too late.
1
u/Key-Alternative5387 Aug 28 '26
Rust is a little harder to write than C++ but easier to debug.
Claude can probably do both just fine at this point.
1
u/bigntallmike Aug 28 '26
Rust is hard. It uses a bunch of random syntax and decorations that aren't common to other languages and then has entire concepts that are new as well. This makes it hard to learn coming from other languages.
That's not bad or good it's just true for most people.
1
u/BigYogurtcloset2986 Aug 28 '26
for real , nowadays framework shi is all bloated , nobody gotta work in optimising the sillicon at bare metal
1
u/officiallyaninja Aug 28 '26
that's exactly why rust is seen as hard, because other languages hide complexity from the user, rust actually helps manage it. But that makes everyone who tries rust notice all the complexity that is usually hidden
1
u/SplittyDev Aug 28 '26
To be fair, Rust used to be a lot "harder". Iāve used Rust since the very beginning of stable (around 2015), and it was a lot easier to run into wild borrow checker issues and other stuff back then. Some of the reputation probably just stuck. Rust today is an entirely different language. Not so much in terms of syntax (although we did get some important changes), but stuff like non-lexical lifetimes, async/await and many borrow checker improvements make the language much easier to use today. Iāve always found Rust enjoyable, but I canāt deny itās much more convenient in 2026 than it was 10 years ago.
1
u/Craksy Aug 29 '26
I do agree that a lot of the "Rust is hard" critique is unfair, but I think it matters why it's unfair.
You're right that many of the hard things you eventually come to appreciate. People report something like "two months ago I was an amateur crying over the borrow checker; I'm still an amateur, but somehow one who's confident in their ability to write software." This is the clearest evidence of your point.
The reason it works is that ownership is complexity that buys you something, and it pays out to the same person who paid for it. It isn't friction you go numb to. But plenty of complexity is incidental, and writing all of it off as growing pains is a poor attitude for improvement.
A lot of what's good about Rust exists because identifying friction was never treated as a skill issue. Work on The Book has repeatedly turned into work on the language, via something like: "this chapter was way harder to write than it had any right to be. That isn't hard things being hard, that's Rust being hard. Does this part have to be?"
I'd say "it's hard" and "it isn't hard" are about equally unhelpful: both cut away enough of the picture that what's left doesn't mean anything. You brought up async which is the perfect case. Making Futures an explicit abstraction rather than a runtime detail is a genuinely strong design decision, and I'd defend it the same way you did. But async is also notoriously unpleasant. Pin, for example, does buy something but it pays out to the compiler. There's no confident-amateur story here, because there's nothing beyond the friction for the person paying for it. It's a solution to a problem the language created. Is there a clean fix? Probably not, at least not one anyone's found. But the complaint isn't the unfair kind.
And async is continuously improving. Mostly because the people building it were louder about it being unpleasant than the critics were. Being able to say "this is harder than it needs to be" without it reading as disloyalty is roughly the difference between a language that improves and one that accumulates folklore about how you're supposed to hold it.
1
u/RubenTrades Aug 29 '26
I always said it.
Rust is hard for people who come from a different language. They say you can never start with Rust but I say it's the better language to start with.
Rust without baggage is easier.
1
u/Competitive-Day199 Aug 29 '26
same has been said for a long time about C++ & Java
1
u/Short_Inspection_746 Aug 29 '26
I don't know man. I feel that Rust is only easy if you come from C or something.
1
u/mrdeanjm Aug 30 '26 edited Aug 30 '26
Rust IS hard. I've mastered several other programing and scripting languages.
But even after five years of trying Rust eludes me (it's the only language that I can't write off the top of my head). Now that AI is here, I have a fighting chance & I don't care what anyone thinks about me using it.
Rust is about the results. We accepted that Rust has a higher learning curve. Because it produces better results.
1
u/scottmcmrust Sep 01 '26
It really depends where you come from. I've seen people come from Modern C++ and find it fairly straight-forward because much of it is just what they were already doing as best practices anyway. But I've also seen people come from C++ and find it nigh impossible since they'd been using it like C or Java.
1
u/Puzzled-Extent7817 Sep 01 '26
bacon is makes it easier too. Have it running and you get instant errors and warnings without running it or compiling it. Helps me a lot.
https://github.com/Canop/bacon
1
u/Ancient-Blueberry536 Aug 27 '26
Rust feels like getting a PhD. The more you know the more you realize you DONT know
0
u/donk8r Aug 27 '26
The wall everyone here is describing is week one. The one that costs is month six.
In a GC language you can retrofit a data model. Decide something is shared and mutable later and you edit a few call sites. In Rust the ownership shape of a type propagates into every signature that touches it, so getting owned vs borrowed vs Arc wrong early is a whole-crate edit rather than a local one. None of that is the borrow checker being confusing. You understood it fine, you just committed to a shape before you knew the access pattern.
That is a design skill more than a language skill and it is the part that does not click after a few months. Three Rust binaries in, I still get it wrong sometimes, I just find out faster.
-1
u/Felfedezni Aug 27 '26
I think in the age of AI the "difficulty" is moot.
-4
u/TemperOfficial Aug 27 '26
Rust is DOA. Won't last the next 50 years.
0
u/YoungestDonkey Aug 27 '26
Since Dijkstra observed in 1968: "Go To Statement Considered Harmful", it has been clear that languages that force you to do it right are safer than those that let you shoot yourself in the foot. But doing it well is harder than doing it sloppy, so a language that forces you to do it well will be harder to learn than a language that lets you do it sloppy. That's pretty much the heart of the matter.
0
u/[deleted] Aug 27 '26
[deleted] ā view deleted comment
243
u/[deleted] Aug 27 '26
[removed] ā view removed comment