3 ms·
> If a language needs an article like this, absolutely begging people to bite the bullet to learn it, maybe that's a language design smell. The problem with ar
by bsder 1y ago
> If a language needs an article like this, absolutely begging people to bite the bullet to learn it, maybe that's a language design smell.
The problem with articles like this is that they don't really get to the heart of the problem:
There are programs that Rust will simply not let you write.
Rust has good reasons for this. However, this is fundamentally different from practically every programming language that people have likely used before where you can write the most egregious glop and get it to compile and sometimes even kinda-sorta run. You, as a programmer, have to make peace with not being able to write certain types of programs, or Rust is not your huckleberry.
- swiftcoder 1y ago> There are programs that Rust will simply not let you write. Can you specify a few of these programs? I can see where Rust might not allow you to write something the way you want to, but I fail to see how a program would not be expressible in rust...
- steveklabnik 1y agoThey mean in Safe Rust. Unsafe is included in Rust for this reason.
- swiftcoder 1y agoIs safe rust not Turing complete? I can see the argument that a purist "safe rust only" program might be slow, but it still will be expressible
- steveklabnik 1y agoTurning completeness doesn’t take efficiency into account, nor the reality of things like “call into the operating system so that you can display output” that are necessary when building real systems.
- swiftcoder 1y agoWith respect, I think that's moving the goalposts. If we have defined out of existence all forms of I/O, then what are we actually discussing?
- steveklabnik 1y agoWe haven't, that's why Turing completeness is not relevant for the question at hand. I can implement the non-IO parts of Brainfuck with safe Rust, so it is Turing Complete. That doesn't change the fact that there are useful programs not expressible in it.
- empath75 1y ago> There are programs that Rust will simply not let you write. If you're writing purely safe code, I will say this is true in a practical sense, but you can almost always use unsafe to write whatever you think rust won't let you do.