←back to thread

611 points LorenDB | 1 comments | | HN request time: 0s | source
Show context
choeger ◴[] No.43912866[source]
All this has been known in the PL design community for decades if not half a century by now.

Two things are incredibly frustrating when it comes to safety in software engineering:

1. The arrogance that "practitioners" have against "theorists" (everyone with a PhD in programming languages)

2. The slowness of the adoption of well-tested and thoroughly researched language concepts (think of Haskell type classes, aka, Rust traits)

I like that Rust can pick good concepts and design coherent language from them without inventing its own "pragmatic" solution that breaks horribly in some use cases that some "practitioners" deem "too theoretical."

replies(4): >>43913128 #>>43915349 #>>43916215 #>>43917609 #
Ygg2 ◴[] No.43913128[source]
> I like that Rust can pick good concepts and design coherent language from them without inventing its own "pragmatic" solution that breaks horribly in some use cases that some "practitioners" deem "too theoretical."

I've thought Rust picked some pretty nifty middle ground. On one side, it's not mindfucking unsafe like C. It picked to remove a set of problems like memory safety. On the other side, Rust didn't go for the highest of theoretical grounds. It's not guaranteeing much outside of it, and it also relies a bit on human help (unsafe blocks).

replies(1): >>43913258 #
eptcyka ◴[] No.43913258[source]
As per the article, Rust has benefits beyond the ones afforded by the borrow checker.
replies(1): >>43913710 #
Ygg2 ◴[] No.43913710[source]
Sure, but it is pragmatic in other ways as well :)

It takes ADT, but not function currying, and so on.

replies(2): >>43913760 #>>43913876 #
andrepd ◴[] No.43913876[source]
I don't think currying is that big a deal, it's just syntactic sugar that might or might not make things easier to read, unlike ADTs or closures which are important core concepts.

I'd love to have a syntax like

    { foo(%1, bar) }
standing for

    |x| { foo(x, bar) }
though. I'm not aware of any language that has this!
replies(10): >>43914073 #>>43914288 #>>43914655 #>>43914762 #>>43914803 #>>43915598 #>>43916123 #>>43920249 #>>43922459 #>>43925563 #
1. masijo ◴[] No.43914655{3}[source]
Clojure has this

    user=> (#(println %1 %2) "Hello " "Clojure")
    Hello Clojure