Apparently the road to hell is paved with vague slogans...
C is actually a fantastically complicated language, both syntactically and at the semantic and abstract machine level.
i am not sure i understand, are you saying that c and rust have the same semantics ?
Treating C like a “high level assembler” needs a rule like the cryptographic doom principle: it will inevitably lead you astray, and “astray” for C generally means memory unsafety.
you are right. however, i think c does a better job at being a model of an abstract machine than rust. if we restrict semantics to that, and the developer accepts that they need more knowledge than just c, i think the semantics are simpler than rust's. in the same way, dont you think that rust can create a false sense of security to those not completely understanding what protections it provides? if we see programming languages as a hci problem, then i think c by default offers more freedom, and consequently more unsafety. amyway i dont want to come off as hating rust, i think it is a good language, but more importantly its community seems fantastic and i wish it success
No: the entire point of Rust's design is that you don't need to know the abstract machine semantics to write Rust safely. The compiler enforces the semantics for you, rather than pushing them onto you.
If we are being honest with ourselves the truth is that even a language as nightmarishly complex as C++ is preferable to C. And whether or not you agree with that the fact is that the world marches on regardless.
Am I dreaming?
The ability to write your own compiler for a language... that's related to the above?
except... Forth or Pascal, perhaps?
If they were, things wouldn't be the way they are today. Perhaps you're saying that they are, but can only express that position in the form of subtle exploits (which seem to be decreasing over time)? No, I think the majority of engineers are overwhelmingly complacent and obedient, and won't oppose.
As for why Rust, that's because the amount of prosletysing of that language seems to be far more than all the others.
Rustacean Abraham Lincoln might quibble on what freedom means in this context: https://news.ycombinator.com/item?id=34620164
To put it in other words, I want my tools to do whatever I want them to do and not the other way around.
Rust just says "This is an engineering project, not a philosophy paper, or science lab. It is not the time or place for experimentation, new ideas, and individual discretion, or for trusting each other or ourselves, we want reliability at all costs".
Which is exactly the attitude I want to see, when failure means I lose important notes, money, or get lost because GPS crashed, or my battery runs down because everyone was too afraid to optimize their brittle bug heaps, or a self driving car murders me, or we return to 1970s level tech due to nobody trusting software.
I'm rather fascinated that you put this in these terms, because I've seen the exact opposite (specifically the philosophy paper). The few times I've seen rust tried out, it seemed to turn into a competition between devs about how clever they could be with category theory. Then an abstraction stack grows until logic errors creep in because nobody understands what the thing is actually doing anymore.
I don't want to blame rust specifically for this, because the same thing happened with scala. Not sure what it is, possibly just a lack of dev discipline. I can't help but view this category of languages (rust, scala, haskell, etc) as competitive philosophy because I have to spend several hours sitting around pondering the nature of things before I can make minor changes from my jira ticket.
End result ends up being that someone usually re-writes an "interim" solution in java/go/etc, over a couple of sprints and then nobody ever gets back to the long term solution written in the elegant language because they don't have time to understand it.
They're all plenty skilled, but I'll give you the pragmatism one. A certain style of dev seems to have a compulsion to violate Kernighan's Law.
Eventually that abstraction hierarchy collapses on itself. I don't want to pin this purely on rust either, since I've seen it in plenty of languages (including java), but I see it happen often enough that I'm reluctant to trust my co-workers with rust at this point.
Or maybe they all can and I'll retreat into my little abstraction-minimal kingdom where the code's not very elegant, but I can figure it out, and I can onboard people in less than a month.
>> "Freedom is not worth having if it does not include the freedom to make mistakes."
>> "The road to hell is paved with good intentions."
Having a smarter compiler that prevents errors does not reduce individual thought or hinder creativity.
It incorporates best practices and discipline that should be followed anyway into the creative process to prevent errors at the source.
"Freedom isn't free."
"The price of freedom is eternal vigilance."
If we gradually destroy all semblance of individual thought and discretion and replace that with something that essentially approaches rule-by-machine, what remains is not far from an authoritarian dystopia in societal terms. Even more so when you realise the direction Big Tech is taking. Jailbreaking and rooting are an escape hatch that they're certainly trying to close with all the "memory safety" stuff.
I'm not saying I can write 100% correct code, although I certainly try (and IMHO it's not too difficult to get close.)
"Freedom is not worth having if it does not include the freedom to make mistakes."
"The road to hell is paved with good intentions."