9 ms·
Rust really does seem to be taking off in the realm of native languages. Personally I would've preferred something simpler, such as nim or Kotlin Native. Howev
by prideout 7y ago
Rust really does seem to be taking off in the realm of native languages. Personally I would've preferred something simpler, such as nim or Kotlin Native.
However I'm excited for the future of system-level programming: we were stuck with C/C++ for a long, long time and maybe that's finally changing thanks to Rust!
- eej2ya1K 7y agoIt's taking off, sure, but every single piece of Rust software I've tried has been, uh, I'll be nice and say not to my taste. Almost like the safety guarantees Rust provides means that developers stop caring about portability, UNIX conventions or just... general... comfiness.
- smhenderson 7y agoDo you have some examples of what you've experienced that you didn't like? I keep reading about people replacing tools written in C with Rust versions but I haven't really pursued it further and seen them in action.
- eej2ya1K 7y agoThe last one I tried was ripgrep, and something about the default behavior just drove me insane... I'll freely admit that it's all about aesthetics and there's no right answer, but that doesn't mean my preferences go away ;)
- ik7tb 7y agoIt's not meant to work exactly like `grep`, if that's what you're on about. If anything, I'd say reimplementing working tools in another language is pointless. It's like when bands cover songs. Who cares if another band plays the song if they don't put their own spin on it? So it's more that you don't care for the tool than the language in this case. Although, I invite you to try ripgrep again and/or lay out some of your gripes with it. I find it a very good replacement for grep.
- burntsushi 7y agoalias rg="rg -uuu" That will disable all smart filtering and make it behave more like `grep -r`. Defaults matter and a lot of folks appreciate them, including plenty of old Unix greybeards that I've talked to about it. (I used plain grep myself for well over ten years before writing ripgrep.) But the defaults don't need to pin you down. They can be disabled very easily. :)
- feanaro 7y agoDid you not also mention problems with portability and UNIX conventions?
- eej2ya1K 7y agoYes, and sorry, that's not specifically related to ripgrep. About a year ago I tried to compile a few rust tools and a bunch of them just straight up didn't work at all because they made assumptions that are only valid for debian/ubuntu based distros. I'm glad people are enjoying rust, and sure, memory safety is nice. Fun and comfort are even better, though, so I'll stick to C, Lua and Go for my personal projects.
- feanaro 7y agoYeah, I was just surprised since I specifically found Rust tools to generally both fun and comfortable due to having (what I consider) excellent UX.
- feanaro 7y agoHere is for instance a Rust tool that I just stumbled upon that seems to have an exemplary UX and adherence to Unix principles while packing a lot of features which I would personally call "fun". https://github.com/sharkdp/pastel https://github.com/sharkdp/pastel
- Corrado 7y agoWow, that's a tool that I didn't know I needed until now. Being a back-end engineer I don't often deal with color information, but every once in a while I have to build a web page or tweak some CSS and it always a pain for me to remember color hex values. This tool should make this much easier. As a bonus, it gives you similar colors and can generate random or distinct color pallets.
- steveklabnik 7y agoAs a Windows user, the Rust ecosystem feels far more portable than any other ecosystem I've used; I run into issues extremely rarely, even though most people are on Mac OS or Linux. (Our last survey did show ~30% of people using Windows, though.)
- burntsushi 7y agoYeah this is a big benefit that is undersold. If I were in the C or C++ ecosystem, I probably wouldn't be able to support Windows as well as I do. It would be too much work. The foundations on which Rust's standard library are built means I can regularly go through entire release cycles without opening my Windows laptop to test anything. Which saves a lot of context switching overhead for me personally.
- jedisct1 7y agoWhen it comes to portability, Go is really awesome.
- Diggsey 7y agoBoth Nim and Kotlin Native have a runtime in the form of a GC/automatic memory management, so you'd still need another language "beneath" them to get the job done. In the system programming world, "simple" means having the program do what you tell it and no more, so that there are no surprises when you come to run it. Rust has a very complicated compiler, and a moderately complicated syntax, but the semantics of the language are amongst the simplest out there - far simpler than C (purely because of the UB), Nim or Kotlin Native IMO, and that really helps when writing low-level code, or even just when contributing to an unfamiliar code-base.
- eej2ya1K 7y agoThe semantics of Rust aren't simple at all. I've used a huge number of languages, both professionally and for personal projects, and Rust is the first one I'm too stupid to understand. ("Modern" JavaScript comes close, but that's not because of semantics, it's more because everything is incredibly overengineered...
- dunefox 7y ago> Rust is the first one I'm too stupid to understand. More complicated than Haskell, etc.?
- eej2ya1K 7y agoI'm probably too stupid for Haskell, too, but in my experience the Haskell community actually acknowledges that the language is hard! The patronizing attitude of rust defenders here on HN, on the other hand, man... it just pushes me further away.
- _bxg1 7y agoIt's not that hard, it just brings very unfamiliar ideas to the table. If you've used a bunch of different languages, most other languages can be picked up pretty quickly by combining different aspects you're familiar with from the ones you know. That's not the case for Rust. It takes a few solid weeks of feeling stupid until you really start to grasp borrowing, and that experience may feel offensive to people who are used to knowing what they're doing, but a few weeks really isn't that much time in the grand scheme of things.
- degraafc 7y agoI'm hoping for Zig [1] to reach maturity and offer that kind of simplicity, because I just can't get a handle on Rust (not that I've spent a massive amount of time trying). [1]: https://ziglang.org https://ziglang.org
- dgellow 7y agoBoth V (https://vlang.io/ https://vlang.io/) and Zig seem really interesting, I also hope they will reach maturity
- networkimprov 7y ago+1 for Zig, tho it has a long way to go. I've seen ppl say that something seems amiss with the V project.
- Verdex 7y agoThere is also: https://github.com/odin-lang/Odin https://github.com/odin-lang/Odin and https://www.kitlang.org/ https://www.kitlang.org/ That are trying to get into the C replacement business.
- jedisct1 7y agoI'm hoping for it to get more exposure. The fact that Mozilla was behind Rust played a lot in Rust becoming popular. But a lot of nice languages have stayed under the radar, and have been eventually abandoned. To succeed, Zig needs maturity, but also marketing. And that is hard without some big name advocating it.
- guggle 7y agoAh ! Nim... as a Pythonista, I'm loving its aesthetics. However in the end it's all about community support, available libs, tooling...