Live data from Hacker News

What is Rust and why is it so popular?

stackoverflow.blog

81–90 of 284 posts

Re: What is Rust and why is it so popular?

#81

Earlier quoted context omitted.

OK, I will bite. If I had to come up with a case where Python is better than Rust, I would say with rapid prototyping and scientific computing. If you just want to try a few things out, python has faster development cycle and if you want to do some super clever math python has better library support. With a bit more mind stretching, I can make a case for Go with a bit more mind stretching. If you want to write a mass…

Ecosystem.. I don't know about node. But there's whole lot of java code and libraries out there. Otherwise why would people build other languages for the JVM? Ease of writing; Most of code is okay having a GC. But time to produce working code (not necessarily 100% correct code) is important. Rust is created for low level stuff. It is wrong to expect web backend programmers to deal with ownership, stack-vs-heap and al…

> It is wrong to expect web backend programmers to deal with ownership, stack-vs-heap and all.

I am a web backend programmer. I respectfully disagree. I would much rather deal with ownerhip and related issues than deal with dynamic typing fallout. Unfortunately, I am stuck in Python land for some foreseeable future.

> But there's whole lot of java code and libraries out there.

That is true about every other popular language. Rust might not have the ecosystem, being a lot younger, but why would anyone pick Java out of all the other options?

As far as I can tell, the only two reasons people continue coding in Java are "We have an existing Java ecosystem, it is easier to continue doing what we have been doing than to switch" and "Java is what we know best and it is easier to use Java than to learn new technology stack".

Re: What is Rust and why is it so popular?

#83
post #82

I like everything I see and read about rust but I'm unsure where I'd fit it into my work. Does rust have a future in areas like backend web development or mobile?

My employer, Cloudflare, uses Rust as part of our mobile app for 1.1.1.1. It’s still rough around the edges, you basically integrate Rust like you would a C dependency, but it’s been working great.

There are some backend web development deployments at other companies, but the ecosystem has been changing a lot over the last year. It’s starting to settle down though. Expect more “Flask” and less “Rails.”

Re: What is Rust and why is it so popular?

#84
post #38
post #34

Over the last couple of months I've been slowly, but steadily playing with Rust. I work on embedded systems and while it's gaining traction only slowly, it feels to me reasonably likely that we'll be seeing non-trivial applications in the next 8-10 years. I doubt that we'll see it used for low-power/resource-constrained firmware, but lots and lots of embedded systems are now bulky Linux boxes with years of uptime, an…

I think that Rust's approach to safety -- soundly eliminate UB in safe code -- comes at the high cost of complexity. This affects how easy it is to write custom compilers (very important in the embedded space), but it is also not necessarily the best way to reduce bugs. For some, this cost is acceptable, and I'm sure some people may even welcome the high-level-looking code [1] that Rust and C++ support, but I think t…

> This affects how easy it is to write custom compilers (very important in the embedded space)

Is there a reason you’d write your own Rust compiler frontend, rather than just letting rustc generate LLVM IR as it does, and then writing your own LLVM arch target? None of the Rust complexity leaks over into the LLVM IR it generates; it looks just like the LLVM IR that e.g. clang generates.

Re: What is Rust and why is it so popular?

#85
post #12

The more pressing question: What is Rust and why is it so popular on HN?

I did an internet search for Rust jobs and it was near-zero. Would be nice but reality calls.

You don't look for Rust jobs. You rewrite your current job in Rust. :D

Re: What is Rust and why is it so popular?

#86

Earlier quoted context omitted.

> I doubt that we'll see it used for low-power/resource-constrained firmware I'm curious what your reasoning is for saying this?

Are you going to use Rust on a PIC12 with 32 bytes of data memory and max 256 code instructions? Of course not. Assembly is still king in this low-powered embedded class and will stay as such for the foreseeable future.

In that specific case, I’d probably still not use ASM directly, but rather probably a Lisp DSL for machine-code generation (and a Lisp emulator for the ISA it generates), so that I could in turn write some genetic algorithm or somesuch to explore the space of such ASTs (and thereby the space of max-256-byte machine-code programs) to find the optimal way to pack instructions to solve my problem (where “solve my problem” is specified in terms of what the emulator’s registers and memory should look like on a given cycle.)

ASM is for the use-case where you're optimizing code in terms of using specific instructions or intrinsics; but it's not really for the case where you're concerned with specific opcode encodings (as ASM abstracts that away, grouping multiple different opcode encodings—some short, some very long—behind a single friendly instruction name.) In that case, you have to work with the machine-code directly—or, at least, through data structures that contain machine-code at the base level, and so can tell you exactly what machine-code they contain.

Re: What is Rust and why is it so popular?

#87
post #12

Earlier quoted context omitted.

I did an internet search for Rust jobs and it was near-zero. Would be nice but reality calls.

I just saw my first local, non-blockchain Rust opportunity, but sadly had to pass on it due to other obligations. Everyone I know writing Rust these days is introducing it to their orgs - not waiting for an open position.

That's how I got Koltin going at my job before it was official with Google.

Re: What is Rust and why is it so popular?

#88
post #30

Earlier quoted context omitted.

Some well-liked SF mod got randomly booted due to a CoC powerplay, and then everything exploded. Rules weren't followed correctly, mods getting kicked out or quiting in revolt, all sorts of corporate powerplays and misplays Basically the whole stack overflow administration is fucked, but also no one really cares because that administration is mostly invisible to the majority of SF users (developers coming from Google…

I’m on the fence to whether to care about any of this. On one hand I’ve no time for nonsense anymore. On the other hand, it sounds like it means SO will degrade (even more) because of it.

I don't think it matters at all unless you're an SF admin.. you and I are going to do fuckall to impact the situation anyways. I personally only care insofar as the situation is interesting. This is my onlooking entertainment.

In terms of degradation, I suppose it depends on which side you're on. The admins imo are the ones pushing the rule-heavy and quick-to-close question methodology that stack overflow gets a lot of grief for -- the company seems to be trying to move to the more free-form moderation found on forums, where mods are gods (until ejected by the Supreme Leader aka CEO). Where it really makes sense to blame one mod vs another.

IMO stack overflow benefits mainly from it's strict enforcement, and it's preference on serving answerers rather than questioners (the burden is on asking good questions, less on writing good answers.. rather, it's more assumed good answers will be written for good questions, whereas other systems like quora emphasize the opposite). So the loss of the mod community will cripple stack overflow in the long term, imo.

Re: What is Rust and why is it so popular?

#89
post #38
post #34

Over the last couple of months I've been slowly, but steadily playing with Rust. I work on embedded systems and while it's gaining traction only slowly, it feels to me reasonably likely that we'll be seeing non-trivial applications in the next 8-10 years. I doubt that we'll see it used for low-power/resource-constrained firmware, but lots and lots of embedded systems are now bulky Linux boxes with years of uptime, an…

I think that Rust's approach to safety -- soundly eliminate UB in safe code -- comes at the high cost of complexity. This affects how easy it is to write custom compilers (very important in the embedded space), but it is also not necessarily the best way to reduce bugs. For some, this cost is acceptable, and I'm sure some people may even welcome the high-level-looking code [1] that Rust and C++ support, but I think t…

> Rust is without a doubt a (much) "better C++" but I'm not sure a better C++ is necessarily what systems programming needs most.

As an embedded consultant, a better C++ is what systems programming needs most not for technical reasons, but social. So many embedded shops are embracing C++ and it's causing all the sorts of problems you might imagine. While it's possible that these shops will tack back towards a lower-level language, my prediction is that would be a much harder sell than something like rust.

Re: What is Rust and why is it so popular?

#90
Wow, that is an extremely well-written brief introduction to Rust. I love the way it manages to address some more technical (e.g. FFIs, distinction between borrow-checker and other parts of compiler) but important concepts despite being so short. Thanks very much Jake Goulding if you're reading.
Post reply on HN