Live data from Hacker News

Moving from TypeScript to Rust / WebAssembly

nicolodavis.com

281–290 of 428 posts

Re: Moving from TypeScript to Rust / WebAssembly

#281
post #208

Earlier quoted context omitted.

> This really nails why languages like PHP and Ruby have won out over static typed It really doesn't. Languages like PHP and Ruby "have won out" over statically typed languages because the representatives of statically typed languages at the time were Java and C++, both of which were bad (they still are, but they were): verbose, difficult (and verbose) to leverage for type-safety, missing a bunch of tremendously usef…

because the representatives of statically typed languages at the time were Java and C++ And Pascal, Ada, Haskell, Eiffel, Standard ML, ...

None of which really had mainstream visibility with the kind of people who actually made the decisions about what language your company would be using.

Re: Moving from TypeScript to Rust / WebAssembly

#282

Earlier quoted context omitted.

I say this a lot, but if you are this irritated by Rails, then you ought to see the 20+ year old legacy C/C++ some of us get to work with ;)

I'll see your legacy C/C++ and raise you legacy Fortran 77 :)

We needn't fill the young Rubyist's head with nightmares that deep, friend :)

Re: Moving from TypeScript to Rust / WebAssembly

#283

Whenever I write Rust, I have a lot of fun, but I'm still not sold on it for most web dev. The analogy that comes to mind is that Rust is a really nice sports car with a great engine. It handles like a dream and you can feel the powerful engine humming while driving it. With the right open road, it's a great time. You can really optimize code, make great abstractions and work with data easily. Unfortunately, web dev…

[deleted]

Re: Moving from TypeScript to Rust / WebAssembly

#284
post #279
post #209

Earlier quoted context omitted.

The short answer is that because async is not done yet in Rust. The long answer probably includes GATs (generic associated types), and the even longer answer starts with the amazing work that Nico et al. does to reinvent the internals of the Rust type checker. (Basically - if I remember correctly - the compiler team is currently refactoring big parts of rustc, to librarify the type checker, and replace it with a PROL…

Can I ask what you mean when you say that async isn't done? async/await and Futures are on stable now. There is no runtime in the core/std but that's by design, there is no short term intent from the Rust team to do that. Tokio and async-std are both fairly usable as well.

The team itself described the stabilization of async/await as being in an "MVP" state. Stuff that's been fixed since then:

* error messages (I think there may be more to do, but they're better and better all the time)

* size of tasks (Still more to do, but they've shrunk a lot since it was first implemented

* async/await on no_std (initial implementation used TLS to manage some state, that's since been fixed)

Stuff still to do:

* Async functions in traits (this has a library that lets you work around this with one allocation, having this requires GATs)

* More improvements to the stuff above

* other stuff I'm sure I'm forgetting

> There is no runtime in the core/std but that's by design, there is no short term intent from the Rust team to do that.

This is true but with an asterick; https://github.com/rust-lang/rust/pull/65875 ended up being closed with "please write an RFC," rather than "no."

Re: Moving from TypeScript to Rust / WebAssembly

#285

Whenever I write Rust, I have a lot of fun, but I'm still not sold on it for most web dev. The analogy that comes to mind is that Rust is a really nice sports car with a great engine. It handles like a dream and you can feel the powerful engine humming while driving it. With the right open road, it's a great time. You can really optimize code, make great abstractions and work with data easily. Unfortunately, web dev…

[deleted]

Re: Moving from TypeScript to Rust / WebAssembly

#286
Completely off topic, but I'm a front end developer who dabbles with a range of languages and also enjoys trying out new languages, but I've never really used a 'back-end' language and I've been trying to find one that works for me. What do people recommend nowadays? (Only asking as I've seen people talking about Rails/PHP/Node, etc.).

Re: Moving from TypeScript to Rust / WebAssembly

#287

Earlier quoted context omitted.

Less testing, Documentation, Guarding against typos, better IDE support, better performance; But there is a whole new generation of web developers who don't bother to learn algorithms or low level programming, and just churn out code with that hot new framework. That kind of programmers are also the ones that choose a technology because "it looks easier". The world would be nice if management people understood not al…

> the 10x programmer is not a myth You are right that quality of programmer skill and productivity has high variance, but the way people talked about the "10x programmer" was a vague vision that people pasted their ideas and personal bugaboos onto. So people got into increasingly-heated arguments and talked past each other. When we create social concepts, we need to strive for something like falsifiability -- somethi…

I think it's really not that some programmers do 10x more, but some people with the same job title do a different job. Some engineers take responsibility for product or for ecosystem; some engineers tick off tasks on a list. (Both can be very valid, and bleeding for product quality at a company is definitely not inherently good.)

Re: Moving from TypeScript to Rust / WebAssembly

#288

Earlier quoted context omitted.

Won ? Ruby fell off a cliff once it got to a point where people had to maintain that shit in production - I'm currently working on a large mature RoR codebase and I'm switching jobs ASAP because it's incredibly painful to work with and feels like a dead end career wise - and I like the gig otherwise - good product and a decent team - but the technology is draining so much of my life energy on nonsense it's ridiculous…

I say this a lot, but if you are this irritated by Rails, then you ought to see the 20+ year old legacy C/C++ some of us get to work with ;)

I started on C++ back in VS6 days and I wrote tons of it when I was in to game dev and graphics programming - but I would not want to work on those systems and kinds of problems when I can get paid the same to work on higher level stuff - the tooling quality and slow iteration cycle when I'm really stuck on something leads to a lot of stress - I just want low stress dev environment where I focus on solving problems I'm being paid to solve - not problems created by the tools and then having to explain stakeholders why something seemingly simple takes 3x of the estimate. I like environments where I'm confident in my estimates - C# proved to be good in this regard simply because the tooling is there even when I hit a wall and it has a relatively consistent uniformity that makes it easier to navigate unknown territory.

Re: Moving from TypeScript to Rust / WebAssembly

#289

Whenever I write Rust, I have a lot of fun, but I'm still not sold on it for most web dev. The analogy that comes to mind is that Rust is a really nice sports car with a great engine. It handles like a dream and you can feel the powerful engine humming while driving it. With the right open road, it's a great time. You can really optimize code, make great abstractions and work with data easily. Unfortunately, web dev…

You might enjoy this blog post I wrote: http://kyleprifogle.com/churn-based-programming/

Re: Moving from TypeScript to Rust / WebAssembly

#290
post #279

Earlier quoted context omitted.

Can I ask what you mean when you say that async isn't done? async/await and Futures are on stable now. There is no runtime in the core/std but that's by design, there is no short term intent from the Rust team to do that. Tokio and async-std are both fairly usable as well.

The team itself described the stabilization of async/await as being in an "MVP" state. Stuff that's been fixed since then: * error messages (I think there may be more to do, but they're better and better all the time) * size of tasks (Still more to do, but they've shrunk a lot since it was first implemented * async/await on no_std (initial implementation used TLS to manage some state, that's since been fixed) Stuff s…

Huh! Thanks for chiming in and that's good to know!

Side note, I just want to say that I have mad respect for you always finding a way to stay so positive while continuing to be so heavily involved with the community, even with job changes and all of that stuff going on. You're an absolute role model for how to participate in community management and a godsend for Rust.

Post reply on HN