2026/01/08

Newest at the top

2026-01-08 22:42:02 +0100peterbecich(~Thunderbi@71.84.33.135) peterbecich
2026-01-08 22:41:43 +0100 <tomsmeding> I've ranted about Num before here
2026-01-08 22:41:23 +0100 <tomsmeding> so that's a low bar
2026-01-08 22:41:21 +0100 <EvanR> most things people try to write a Num instance for are contrived xD
2026-01-08 22:41:19 +0100 <tomsmeding> Num was never principled or based in any way
2026-01-08 22:41:08 +0100 <EvanR> (curiously) Foldable ended up being more principled and based than Num
2026-01-08 22:40:32 +0100 <tomsmeding> but contrary to Foldable, where [a] is merely a common instance, such contrived Num instances are really contrived, I'd guess
2026-01-08 22:40:09 +0100 <tomsmeding> there are probably contrived Num instances for which foldl' would be inappropriate
2026-01-08 22:40:04 +0100 <EvanR> a long time ago
2026-01-08 22:39:44 +0100 <EvanR> maybe, but there was a long thread on the mailing list defending the foldl version xD
2026-01-08 22:39:09 +0100 <tomsmeding> that one was probably just an oversight
2026-01-08 22:38:35 +0100 <jreicher> Oww. How did that happen in the first place?
2026-01-08 22:38:33 +0100 <EvanR> good
2026-01-08 22:38:25 +0100merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 264 seconds)
2026-01-08 22:38:08 +0100 <tomsmeding> it is, but that was fixed; sum is now defined using foldl'
2026-01-08 22:36:26 +0100trickard_trickard
2026-01-08 22:36:25 +0100 <EvanR> this is probably dumb
2026-01-08 22:36:08 +0100 <lambdabot> sum = foldl (+) 0
2026-01-08 22:36:08 +0100 <EvanR> @src sum
2026-01-08 22:36:03 +0100 <EvanR> however the situation with sum
2026-01-08 22:34:48 +0100spew(~spew@user/spew) (Quit: nyaa~)
2026-01-08 22:34:01 +0100Milan_Vanca(~milan@user/Milan-Vanca:32634) (Quit: WeeChat 4.7.2)
2026-01-08 22:33:30 +0100 <jreicher> I agree it's good to have a sandbox of some kind for programmers to experience the consequences of laziness and how they can sometimes be avoided.
2026-01-08 22:32:58 +0100merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn
2026-01-08 22:32:26 +0100 <EvanR> though*
2026-01-08 22:32:15 +0100 <EvanR> considering how many utility functions other languages are sorely missing I am ok if haskell has 1 that is "useless", I'm arguing it's useful for pedagogical purposes
2026-01-08 22:31:19 +0100jmcantrell_(~weechat@user/jmcantrell) jmcantrell
2026-01-08 22:30:31 +0100mulk(~mulk@pd95143a6.dip0.t-ipconnect.de) mulk
2026-01-08 22:30:05 +0100 <EvanR> fold being for the special case where all possible folds result in the same answer (a monoidal fold)
2026-01-08 22:30:04 +0100vanishingideal(~vanishing@user/vanishingideal) (Ping timeout: 246 seconds)
2026-01-08 22:30:01 +0100mulk(~mulk@pd95143a6.dip0.t-ipconnect.de) (Ping timeout: 264 seconds)
2026-01-08 22:29:18 +0100 <EvanR> jreicher, on the subject of how many folds you need in Foldable... there's a huge number of other folding strategies other than left fold and right fold, just for a tree-like DS
2026-01-08 22:26:41 +0100 <EvanR> I'm thinking of the various Writer monads
2026-01-08 22:25:27 +0100 <EvanR> you have to understand it
2026-01-08 22:25:23 +0100 <EvanR> the whole drama stems from haskell's laziness, which you can't really escape
2026-01-08 22:25:01 +0100 <EvanR> we'd have like 10 different other foldl situations and the conversion would get kind of confusing
2026-01-08 22:24:23 +0100 <EvanR> we spend a lot of time hating on foldl because we think we understand it and think it's completely useless. But if we didn't dwell on foldl so much, we might miss all the other things in the standard library which potentially blow up in your face and don't have real answers
2026-01-08 22:24:12 +0100Vizious(~bes@user/Vizious) (Quit: WeeChat 4.8.1)
2026-01-08 22:21:55 +0100merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 240 seconds)
2026-01-08 22:18:08 +0100Square3Square
2026-01-08 22:17:11 +0100merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn
2026-01-08 22:11:51 +0100 <monochrom> hehe
2026-01-08 22:11:36 +0100 <darkling> That's the joke I was thinking of.
2026-01-08 22:11:17 +0100 <monochrom> I think the mathematicians also have a joke along the line of "what's the anagram of Banach-Tarski"
2026-01-08 22:10:30 +0100 <monochrom> haha
2026-01-08 22:10:05 +0100 <darkling> monochrommonochrom. An anagram. :)
2026-01-08 22:09:40 +0100 <monochrom> Oh haha there is also a Banach-Tarski one. :)
2026-01-08 22:08:14 +0100 <monochrom> There is one that says "chop ... into pieces" or something like that.
2026-01-08 22:08:06 +0100trickard_(~trickard@cpe-50-98-47-163.wireline.com.au)
2026-01-08 22:07:45 +0100lambdabotmoulds monochrom into a delicous cookie, and places it in her oven