Remix.run Logo
quotemstr 7 hours ago

Good. Rust is fine, but it makes you pay a complexity tax for manual memory management that you just don't need most of the time. In almost all real world cases, a GC is fine. TypeScript is a memory-safe language, just like Rust, and I can't imagine a database ORM of all things needing manual memory management to get good performance. (Talking to the database, not memory management, is the bottleneck!)

amluto 6 hours ago | parent | next [-]

I don’t think the problems they were dealing with had much to do with any of those properties of Rust. Their issue seems to have been that they weren’t using native JavaScript/TypeScript and that their situation was improved by using native TypeScript.

If they had been using something like Java or Go or Haskell, etc, they may well have had even more downsides.

theusus 6 hours ago | parent | prev [-]

> manual memory management

Rust has automatic memory management.

> Complexity tax

Could you be more specific?

honeycrispy 5 hours ago | parent | next [-]

The trait/type system can get pretty complex. Advanced Rust doesn't inherit like typical OOP, you build on generics with trait constraints, and that is a much more complex and unusual thing to model in the mind. Granted you get used to it.

burnt-resistor 4 hours ago | parent [-]

OOP inheritance is an anti-pattern and hype train of the 90's/00's, especially multiple inheritance. Especially the codebases where they create extremely verbose factories and abstract classes for every damn thing ... Java, C++, and the Hack (PHP-kind) shop are frequently guilty of this.

Duck typing and selective traits/protocols are the way to go™. Go, Rust, Erlang+Elixir... they're sane.

What I don't like about Rust is the inability to override blanket trait implementations, and the inability to provide multiple, very narrow, semi-blanket implementations.

Finally: People who can't/don't want to learn multiple programming language platform paradigms probably should turn in their professional software engineer cards. ;)

quotemstr 5 hours ago | parent | prev [-]

> Rust has automatic memory management

Sure, if you define "automatic memory management" in a bespoke way.

> Could you be more specific?

The lifetime system, one of the most complex and challenging parts of the Rust programming model, exists only so that Rust can combine manual memory management with memory safety. Relax the requirement to manage memory manually and you can safely delete lifetimes and end up with a much simpler language.

Have you ever written a Java or Python program?