9 ms·
John Carmack: writing Rust code feels wholesome
- topspin 8y agoI've been playing with Tokio and Actix for a few days. That's the same feeling I get.
- rienbdj 8y agoC++ continues to lose mind-share. When will the community acknowledge that their tooling is lacking?
- geezerjay 8y agoA tool is a tool. It's immaterial if a particular tool like C++ and its ecosystem is no longer the best available tool for some applications. Workmen pick the tool that best suits their tasks, and if a better tool appears it makes no sense to assume that the old tool requires more attention.
- adgasf 8y agoC++ has many users that love the language but are in denial that other languages have advanced beyond it (not in all areas, of course, but enough areas that matter).
- ahartmetz 8y agoDo you use C++? I do, and I don't love the language. What I like about C++ is that it's a high level low level language. Anything that isn't is not a competitor in C++'s core application areas. D and OCaml come kinda close but they have (in practice) mandatory garbage collection. The only real alternatives are Ada (which somehow never achieved much mindshare) and Rust.
- pjmlp 8y agoI do, as native companion to Java and .NET, and I still kind of like it. However for my own use cases, my actual alternative is the newly founded love for low level programming support by Java and .NET designers. Mandatory GC is nice to have around, while only specific hotspots require a more machine friendly coding.
- cuddlecake 8y ago> Workmen pick the tool that best suits their tasks Workmen also carry the burden of maintaining old (legacy) products. No one would say no to a shiny new feature that makes tedious stuff easier.
- loup-vaillant 8y ago> A tool is a tool. Oh yes it is. Which means, a tool is an extension of oneself. We tend to identify ourselves with our tools, especially if they required extensive learning. The simplest tools (hammer) are easily replaced, but the more complex ones (my cello) are highly personal, and seldom swapped. Programming languages fall on the complex end of the spectrum. They require learning, and to some extent, what you learn is what you are. Throwing away a programming language (and its ecosystem) is throwing away a good chunk of the knowledge you acquired there —a part of yourself. A new language needs to have one hell of an advantage to get significant adoption under those conditions. And I didn't even talk about network effects…
- jeffdavis 8y agoTools are generally independent. Using a particular screwdriver doesn't change the effectiveness of your hammer. Changing between programming languages is a bit more complicated than exchanging tools in a belt.
- x100y 8y agoWhere? On HN and Reddit? I see new code bases in C++ springing up like mushrooms. I'd prefer Haskell/ML, but I can't deny reality.
- pimeys 8y agoIt seems the market for people who can convert systems from other languages to Rust is starting to appear. At least in the last couple of months there has been quite a few offers in Berlin for people who can write and teach Rust.
- baybal2 8y agoIf it does, than not to Rust. Comparing tooling support for c++ and rust... In that comparison c++ completely overwhelms rust
- IshKebab 8y agoI like C++ but I think he meant in terms of how sane and usable the tools are, in which case Rust easily wins. Compare Cargo to CMake for example. Sure it might not have as many IDEs, static analysers, debuggers and so on, but I'd easily take Rust's build system over C++'s tool ecosystem.
- pjmlp 8y agoWhen we compare eco-systems, we need to consider everything. For cargo to win over cmake, it needs to finally support binary libraries. For Rust to matter to .NET devs, it needs to support COM/UWP and mixed mode debugging on IDEs. On Android, mixed mode debugging and just fitting in with the NDK/AS would also be quite productive.
- IshKebab 8y agoC++ is actually doing very well, and the community is very well aware that C++ tooling sucks. It's just not an easy problem to solve because it has such a huge amount of existing code and projects.
- adgasf 8y agoAbsolutely! I think the important question is, what will happen first: (a) C++ gets better tooling around build systems and package management; or (b) Rust libraries are written for all of the things that we care about? Certainly in the HN bubble it feels like (b).
- est31 8y agoIt's not just package management. C++ is hugely overcomplicated with features. Understanding C++ is a life project. And the language is unsafe-by-default so you will spend time tracking down segfaults or other UB stuff. Rust allows me to focus on the problem domain, less on the language.
- bsaul 8y agoMany comments in twitter mentions rust still not being ready for server code ( which i start to feel strange since concurrency is the only major issue on the server side, and supposed to be rust strength). Anyone can confirm ?
- d33 8y agoPerhaps they meant webapps: http://www.arewewebyet.org/ http://www.arewewebyet.org/
- markdog12 8y agoLatest news: 11 Aug 2017
- steveklabnik 8y agoWargroove, a recent game by Chucklefish, has its matchmaking server in Rust. Many people are waiting for async/await before saying “please come try this”, as it makes the enterprise far easier. We’re quite close!
- n_t 8y agoI have used rust but I think it has another year before it really shines. 2020 is the year of Rust - async/await, tool ecosystem, various crate stability, etc is happening fast.
- pornel 8y agoWhile you'll hear Rust community often say "just wait until this new hotness", I'd like to clarify it's not like a perpetual "it will be the year of Linux Desktop". Rust has already shipped everything it needed to be production ready. We're just always excited for the next big thing. Two years ago it was incremental compilation, last year it was a new borrow checker, this year it's async/await, etc.
- steveklabnik 8y agoThis is also true. It really is about what you’re doing. Async/await in particular enables you to write idiomatic code, right now you have to twist it a bit and can’t do certain things. Other features? I agree with you.
- Waterluvian 8y agoWhen I explored rust I found the exact same feeling too, but couldn't find that word. My only issue is how surprisingly weak Rust support is in my favourite editor. Rust seems to feel more popular than it is. Or maybe more people write Rust in a "no frills notepad" kind of way.
- x15 8y agovscode has pretty good support for rust. If you need something more advanced, you can try clion from jetbrains with the intellij-rust plug-in.
- Waterluvian 8y agoVscode is what I tried. It was critically flawed where the autocomplete would crash or be missing half the options you'd expect. I will need to try again. It's been six months.
- sondr3 8y agoI can vouch for CLion with intellij-rust, it is by far the best Rust editor/IDE available at the moment. RLS still suffers from slow/no auto completion and crashes too much for my liking. The pace and features that are coming out of the team working on intellij-rust is amazing: https://intellij-rust.github.io/thisweek/ https://intellij-rust.github.io/thisweek/.
- Waterluvian 8y agoRust is so exciting to me that I'll probably do this. But I absolutely HATE having to maintain multiple editors. It's like playing two pianos where the keys are all in different places. I will spend hours trying to make one like the other but it'll just never quite be right so my coding rhythm. will be discordant and janky. I wish there was a trivial way to say to intellij, "steal all my config from vscode"
- 0xcoffee 8y agoSame experience here. Was learning rust with vscode, and it would only show half of the compiler error output (e.g. the part that recommends how to fix the error wasn't shown). In the latest vscode release they now support multiline error messages so maybe the situation will improve.
- brutus1213 8y agoI looked seriously at rust about 2 years ago. I seem to have tried the language at the wrong time .. they were transitioning between versions and this made learning it hard. I grew up with C so am very comfy with pointers. Even reference counting feels natural to me. That said, the borrowing/ownership semantics of rust (at the time I looked at it) felt needlessly over complicated. Has this got better? Is there a K&R equivalent that an experienced programmer can get pick up to get productive with the language soon?
- ainar-g 8y ago>That said, the borrowing/ownership semantics of rust (at the time I looked at it) felt needlessly over complicated. Isn't it just “one mutator at a time”? >Is there a K&R equivalent that an experienced programmer can get pick up to get productive with the language soon? (Opinion incoming.) The Rust Book[1] is great iff you are a complete beginner. If you are an experienced programmer, who knows his way around concepts like resource management and ownership, it's kind of a drag. Rust by Example[2] is much better. The Nomicon[3] is interesting, but it's mostly about unsafe. [1] https://doc.rust-lang.org/book/ https://doc.rust-lang.org/book/ [2] https://doc.rust-lang.org/stable/rust-by-example/ https://doc.rust-lang.org/stable/rust-by-example/ [3] https://doc.rust-lang.org/nomicon/index.html https://doc.rust-lang.org/nomicon/index.html
- manaskarekar 8y ago>the borrowing/ownership semantics of rust (at the time I looked at it) felt needlessly over complicated. Taking a wild guess here, but it sounds like you maybe referring to issues addressed by Non-Lexical Lifetimes (NLL)? Reference: https://github.com/rust-lang/rfcs/blob/master/text/2094-nll.md https://github.com/rust-lang/rfcs/blob/master/text/2094-nll.... NLL are a part of Rust 2018 Edition. Three complementary books are the best resources: - The Official book: https://doc.rust-lang.org/book/ https://doc.rust-lang.org/book/ - The Rust By Example book : https://doc.rust-lang.org/rust-by-example/ https://doc.rust-lang.org/rust-by-example/ - Programming Rust (O'Reilly) : https://www.amazon.com/Programming-Rust-Fast-Systems-Development/dp/1491927283 https://www.amazon.com/Programming-Rust-Fast-Systems-Develop...
- 8y ago
- azhenley 8y agoI decided to learn Go instead of Rust over the last 6 months (very limited time so couldn’t learn both well). Rust has gotten so much on HN lately that I think it may be time for me to make the switch.
- Kenji 8y agoGo is okay too. It's not as hyped as Rust but it has a lot going for it. So don't regret your choice.
- forinti 8y agoI started with Go and am now learning Rust. I liked Go, but it felt incomplete (currently there's a discussion on generics) and I'm tired of Java never settling down and now trying to be cool. Also, method declarations are weird (method over variable or pointer). Rust seems complete. The ownership paradigm is a bit difficult at first, but the compiler is good at pointing out exactly what the issue is.
- pjmlp 8y agoInteresting remark of Java not settling down with Rust being complete, while some Rust libraries depend on nightly and async/await is still not fully baked. Languages are products, either they change with times or they die.
- mbroncano 8y agoAlso posted in the twitter thread, a game dev wish-list for Rust https://users.rust-lang.org/t/my-gamedever-wishlist-for-rust/2859 https://users.rust-lang.org/t/my-gamedever-wishlist-for-rust...
- klyrs 8y agoJC: hey this language is nice Twitter: yes but have you tried my favorite language?!
- johnisgood 8y agoDoes anyone know, is https://github.com/rust-lang/rfcs/blob/master/text/0066-better-temporary-lifetimes.md https://github.com/rust-lang/rfcs/blob/master/text/0066-bett... ever going to be resolved? I really do not like the idea of having to create a new variable for something so simple as this.
- TheCoelacanth 8y agoSeems to be unanimously agreed to be a good idea, but is a bit tricky to actually implement[1]. Hopefully some day. [1] https://github.com/rust-lang/rust/issues/15023 https://github.com/rust-lang/rust/issues/15023
- purplezooey 8y agoMan reading Twitter is so awful. It feels like sitting in one of those 2 hour meetings where everyone is allowed to give their 30 seconds and all that's left is your throbbing headache.