Conversation

Instead of g(f(x, y), z) OO langs have x.f(y).g(z) class member syntax, which is nice, but it's like having to subscribe to 12mo of an entire shitty cable network for that one show you like /2
1
5
The popularity of extension methods sort of give the game away that the denested syntax is all people want a lot of the time /3
1
2
Haskell has infix operators which bind weaker than named functions, like x |*| y /*/ z. But Haskell libs often get crapped up with obscure symbols so that power users don't have to use parens, and the fixity/associativity can be confusing. /4
1
1
Lisps, the nestiest of languages dodge some of the worst by manually rigging varargs functions to represent repeated application: (+ 1 2 3), and indeed in the list syntax itself to hide the endless dotted pairs /5
1
2
F# has the pipeline operator to give x |> f |> g instead of g(f(x)), and Clojure has the threading macros (-> x f g) /6
1
1
Should languages come out of the box with some purely syntactic operator to flatten visual nesting, without coupling it to a semantic construct? It seems like a common need. 7/7
3
6
Ie. the space is effectively reverse funcion application. No parens at all. 🙃 Check out concatinative programming, and other languages in this space, like Joy, Factor, and Kitten.
2
2