Live data from Hacker News

Ask HN: Why do you use Rust, when D is available?

news.ycombinator.com

121–130 of 262 posts

Re: Ask HN: Why do you use Rust, when D is available?

#121
post #71

Earlier quoted context omitted.

I’m currently trying to get into robotics. But why does everyone want c++? Surely robots can be programmed in other languages.

Because the real world doesn't really match the expectations and statements of the HN community. It's really rare that I see here anything pragmatic regarding what programming languages to learn/use. The community lives in a bubble and is out of touch with mainstream software development.

I'm a very senior engineer. I've had a strong desire to find a better alternative to C++ since the 90s when I was first exposed to it (I worked with it for about a decade, after a few years with C). Now, decades later, enough bandaids have been applied that it's somewhat tolerable. Congratulations...?

The industry has needed good alternatives for a long time. Finally, they're coming, and not nearly soon enough to suit me! :-)

Re: Ask HN: Why do you use Rust, when D is available?

#122
post #28

Personally, at some point Rust was just clearly better and after a while - I lost interest in D. I don't have time to keep track of D catching up, when I'm so happy with Rust, and ecosystem is growing so fast. Maybe D got much better in last few years... but I kind of don't care anymore. It's hard enough to introduce a raising star like Rust to your coworkers and D just don't have traction anymore. I've been followin…

I got scared away by rust's syntax.

I feel that people can learn rust faster if they know c++ beforehand.

c++'s syntax is scary too. But there are different levels of c++. You don't need to use the scary part to make things work.

Re: Ask HN: Why do you use Rust, when D is available?

#124
post #77

Earlier quoted context omitted.

You don't replace languages but program's, go into physic-space, fortran is alive an well, go into systems programming c is alive an well, go into business java is alive and well. It's the same BS like NoSql will kill all R-D's. You just don't invest millions just to rewrite programs that work's perfectly (and that's often the case with old battle-hardened software)

The reason that RDMSes aren't dead isn't that they have too much momentum to be displaced by NoSQL. The reason they're not dead is that they're a good data model for lots of applications, and their consistency semantics and tooling provide real boosts to developer productivity.

I know, but around 2009/10 every hipster programmer said RD's are a thing of the past..like C like Java etc...

Re: Ask HN: Why do you use Rust, when D is available?

#125

Because Rust is new and shiny. People who use Rust aren't using it to solve real world problems, they're using it to scratch a novelty itch. D is a tragedy in my opinion. It's an excellent language that just doesn't fit the political needs of any of the big players. We have Swift which is a worse version of C#, we have Go, we have Java. Why don't we have a single language so that we can do cross platform development…

why is everyone blowing Blow? c'mon, respect yourself son

Re: Ask HN: Why do you use Rust, when D is available?

#126

Earlier quoted context omitted.

One of the reasons why I haven't approached Rust is its syntax. Subjectively ugly and polluted with punctuation symbols that tell you little about their semantics. D looks cleaner and more readable even for a person not familiar with the language. D's readability is on par with scripting languages. Rust is far away from that. Type names after variable or before? When you think about declaring a variable, do you think…

The reason behind putting the type after the variable is that the resulting syntax plays way better with type inference. Scala is a clear inspiration for Rust in that regard.

(Let me nip a little here). Looks like not only Scala inference types but also its compile times too migrated into Rust.

Re: Ask HN: Why do you use Rust, when D is available?

#127

For those you want the context of D please check its development history [1]. If history telling us something, python only take off after 20 years and now D language is around the 20 years mark. But fortunately D has passed the growing pain similar to python 2 to 3 when it transitioned to D2. Personally I think D just need a big breakthrough in a form of a killer application like Ruby with RoR, and Go with Kubernetes…

> For rust since it came from Mozilla team I'd expect by now Firefox is already re-written in rust by now but it seems yet to happen, and this article probably tell us why [2]

Nope. In fact that article says:

> By 2017, Mozilla had made two previous attempts to parallelize the style system using C++. Both had failed.

And goes on to say how they were successfully able to re-write it in Rust, and then talks about the kind of security problems Rust solves and the ones beyond language scope (correctness).

But I don't think we really needed an article to tell us why a 20+ year old browser that has a billion man-hours of development hasn't been re-written in a language that has only been stable for five years, and has a relatively small team working on it.

Re: Ask HN: Why do you use Rust, when D is available?

#128
post #28

Personally, at some point Rust was just clearly better and after a while - I lost interest in D. I don't have time to keep track of D catching up, when I'm so happy with Rust, and ecosystem is growing so fast. Maybe D got much better in last few years... but I kind of don't care anymore. It's hard enough to introduce a raising star like Rust to your coworkers and D just don't have traction anymore. I've been followin…

> It's a C++-killer: same strengths, none of the weaknesses Not used Rust yet, used a lot of C++; isn't a weakness that it also is extremely slow in compiling? Not sure about others but to me that's a big weakness (if it still applies, but as far as I can find on Google it does).

From my experience building (not writing) relatively complex Rust applications like Alacritty, it's really not that bad. Building for release is definitely slower than C++, but development builds are almost always instant for me, as they're done incrementally.

Re: Ask HN: Why do you use Rust, when D is available?

#129
post #45

Earlier quoted context omitted.

A language is more than just a technology: it's an ecosystem of libraries, platform APIs, developer mindshare and experience, familiarity, legacy codebases, product support. Don't discount the weight of all of those auxiliary, human factors. Rust, culturally, comes from the web. That's why it has the most traction in the web server/WASM space for now. It's starting to poke its head into Systems use-cases because of t…

Not really. While there is a growing set of web-based application for Rust, it's not like PHP, where the very purpose of the language is the web. Rust is a system language before it is a web language. WASM as a target is actually a great indication that it's a system language -- performance is a primary consideration.

You're missing the point. The point is that Rust came from Mozilla. Its mind-share started with web people and is expanding from there. What I'm trying to get across is that those social forces can matter more for adoption than just the tech's appropriateness, considered in a vacuum.

Re: Ask HN: Why do you use Rust, when D is available?

#130
Let me throw my uneducated and biased opinion on the table.

It's amazing how Rust development and popularity progressed over the years. Uncompromising features, no trade-offs except for complexity and compilation speed but what language is ideal, right?

For me personally, D was just easier and faster to learn than C/C++/Rust. I got basically the same speed without memory management and learning curve overhead. Coming from Python land I enjoyed fast rdmd compile-and-run times that made me feel like I am working with an interpreted language while having much more control and access to the system. Nowadays, D forum, IRC is so helpful that I get an answer within minutes. I expected quite the opposite considering how smaller the community is.

So, these are my reasons for why D. You can see that I didn't care whether the language was backed up by some global company or was trendy. I got tired of Python that fallbacks to C/C++ when performance matters and if you want some real work done good luck with C/C++. JVM based languages were also not my cup of tea due to memory appetites and being comparably slower. D came as a surprise managing to be faster both in execution and compilation. It is later that I learnt about some of the shortcomings, smaller community, fewer available libraries, etc. etc.

Post reply on HN