News for hackers. Stuff that matters.
Re:We need to talk about parentheses by lex-lightning on Monday February 12, 2024 @08:12PM (#39353042)
If I wanted to deeply pedantic, I think the blocks associated with those monady bits keep the parameters in scope longer than needed.

But I never got into Haskell so I don’t really know.

Re:We need to talk about parentheses by lmm on Monday February 12, 2024 @11:58PM (#39354590)
> If I wanted to deeply pedantic, I think the blocks associated with those monady bits keep the parameters in scope longer than needed.

I don't think so? If you write it as a "flat" block using do notation then anything from earlier in the block is accessible later in the block. But local functions are real functions with lexical scope, they don't get hoisted up to the containing scope or anything. (And FWIW that's Scala-style syntax, although the ideas are very Haskell-like)

Re:We need to talk about parentheses by lex-lightning on Tuesday February 13, 2024 @07:13AM (#39356924)
Dope. Thanks.

Have you written much Prolog?

I was thinking about in Prolog terms and I think it’s the hardest paradigm to avoid the scoping problem in

Re:We need to talk about parentheses by lmm on Tuesday February 13, 2024 @05:23PM (#39363658)
I've never done any Prolog.