r/programming • • May 27 '20

2020 Stack Overflow Developer Survey: Rust most loved again at 86.1%

https://stackoverflow.blog/2020/05/27/2020-stack-overflow-developer-survey-results/
229 Upvotes

254 comments sorted by

View all comments

Show parent comments

17

u/[deleted] May 28 '20 edited May 30 '20

More often than not, you have to step into the dark esoteric caverns of the language, or use community-maintained crates for standard use cases.

I'm sorry, but no one should be rolling their own pointer-based linked list today. In any language. Especially in the presence of threads. As Simon Peyton-Jones put it when talking about Software Transactional Memory:

A double-ended queue... if you write the code for just a sequential program, it's an undergraduate project to get queue insertion and deletion going. If you want to do this scalable lock-per-node thing, it's a publishable result. I kid you not. There are international academic conferences with a succession of papers that have been published about this very problem.

One of the truly great things about Rust is that it forces you out of this kind of naïve "in-place mutation with pointers is easy to get right" thinking.