News for hackers. Stuff that matters.
Re:Haskell's Children by jolux on Wednesday September 23, 2020 @04:41PM (#24571753)
The monadic interface is not the only API surface those types have in Haskell. It very rarely is. There’s no “cramming,” they either have monadic structure or they don’t, and if they do it’s very convenient to be able to treat them as monads.
Re:Haskell's Children by eru on Wednesday September 23, 2020 @11:42PM (#24575021)
Just to be pedantic, we also recently got applicative-do. So you can use a subset of do-notation for the much more prevalent Applicative Functors, too.

In practice applicative functors are even more prevalent than their subset, monads.

If you can express your algorithm using the weaker applicative combinators only, there's more opportunity for optimisation and parallelism. (And the code is easier to understand for your readers, because there are fewer interactions for them to worry about, too.)

Re:Haskell's Children by jolux on Thursday September 24, 2020 @12:17AM (#24575200)
That sounds super neat! Haskell always has me jealous of language features, but I’ve committed to focusing on mastering C# and the CLR right now because it’s what I get paid for.
Re:Haskell's Children by eru on Thursday September 24, 2020 @12:23AM (#24575226)
See https://www.microsoft.com/en-us/research/wp-content/uploads/... and https://simonmar.github.io/bib/papers/haxl-icfp14.pdf for more background, if you are interested. It might even contain some ideas you can use in C#.
Re:Haskell's Children by Twisol on Thursday September 24, 2020 @12:06PM (#24580030)
> It might even contain some ideas you can use in C#.

I just implemented the Haxl paper in Java as a weekend project (for implementing GraphQL APIs), so it totally does ;)

Re:Haskell's Children by eru on Friday September 25, 2020 @05:03AM (#24587969)
Cool! Have you posted about your experience anywhere?