2026/04/03

2026-04-03 00:00:13 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn
2026-04-03 00:05:59 +0000karenw(~karenw@user/karenw) karenw
2026-04-03 00:06:13 +0000jmcantrell_(~weechat@user/jmcantrell) jmcantrell
2026-04-03 00:07:46 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 248 seconds)
2026-04-03 00:12:09 +0000jmcantrell_(~weechat@user/jmcantrell) (Ping timeout: 255 seconds)
2026-04-03 00:18:33 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn
2026-04-03 00:23:07 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 264 seconds)
2026-04-03 00:33:18 +0000peterbecich(~Thunderbi@71.84.33.135) (Ping timeout: 255 seconds)
2026-04-03 00:33:55 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn
2026-04-03 00:38:42 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 255 seconds)
2026-04-03 00:49:18 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn
2026-04-03 00:52:59 +0000bitdex(~bitdex@gateway/tor-sasl/bitdex) (Ping timeout: 265 seconds)
2026-04-03 00:52:59 +0000synchromesh(~john@2406:5a00:2412:2c00:fc97:d0a4:cdd9:afc1) (Read error: Connection reset by peer)
2026-04-03 00:53:42 +0000acidjnk_new3(~acidjnk@p200300d6e700e5001e1160b7d23e5dd6.dip0.t-ipconnect.de) (Ping timeout: 246 seconds)
2026-04-03 00:54:13 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 268 seconds)
2026-04-03 00:54:15 +0000synchromesh(~john@2406:5a00:2412:2c00:fc97:d0a4:cdd9:afc1) synchromesh
2026-04-03 00:57:22 +0000xff0x(~xff0x@2405:6580:b080:900:1644:ff9e:fe83:e2e) (Ping timeout: 248 seconds)
2026-04-03 01:04:40 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn
2026-04-03 01:09:20 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 252 seconds)
2026-04-03 01:13:57 +0000 <mesaoptimizer> "Under the hood, Haskell is not a magical machine that performs side effects despite being pure. Behind every "pure" function in bytestring, text, and vector lies a cheerful little hellscape of mutable allocation, buffer writes, unsafe coercions, and other behavior that would alarm you if you discovered it in a junior engineer's side project. Behind the ST monad lies in-place mutation and side
2026-04-03 01:13:59 +0000 <mesaoptimizer> effects, observable within the computation. What makes it acceptable is that the side effects are encapsulated such that the boundary cannot be violated. The rank-2 type (that is, the type s is scoped within the parenthesis and can't escape) of runST ensures that the mutable references created inside the computation cannot escape due to being tagged with the type s. Internally, all sorts of
2026-04-03 01:14:01 +0000 <mesaoptimizer> imperative nonsense may occur. Externally, the function is pure. The world outside the boundary gets none of the mutation, only the result." https://blog.haskell.org/a-couple-million-lines-of-haskell/ this is an incorrect inference, right? if you use unsafe IO or unsafe side effects, the type system cannot and will not be able to guarantee the purity
2026-04-03 01:15:16 +0000 <c_wraith> It's nearly accurate for ST
2026-04-03 01:15:29 +0000humasect(~humasect@dyn-192-249-132-90.nexicom.net) humasect
2026-04-03 01:15:30 +0000 <c_wraith> which the reference to runST implies is what it's intended to be talking about.
2026-04-03 01:15:48 +0000 <c_wraith> (It's true for ST as long as you don't use any of the unsafe* functions)
2026-04-03 01:16:12 +0000 <glguy> The point isn't that all uses of unsafePerformIO are protected by the type system, it's that unsafePerformIO can be carefully used in ways that benefit from type system protection
2026-04-03 01:19:57 +0000comonad(~comonad@p200300d02717df00adc247ef70bd7367.dip0.t-ipconnect.de) (Ping timeout: 246 seconds)
2026-04-03 01:20:01 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn
2026-04-03 01:21:05 +0000comonad(~comonad@p200300d02717df00adc247ef70bd7367.dip0.t-ipconnect.de)
2026-04-03 01:24:25 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 248 seconds)
2026-04-03 01:35:29 +0000merijn(~merijn@62.45.136.136) merijn
2026-04-03 01:36:34 +0000jmcantrell_(~weechat@user/jmcantrell) jmcantrell
2026-04-03 01:41:59 +0000merijn(~merijn@62.45.136.136) (Ping timeout: 245 seconds)
2026-04-03 01:46:01 +0000foul_owl(~kerry@94.156.149.94) (Read error: Connection reset by peer)
2026-04-03 01:51:21 +0000 <EvanR> even without unsafe perform IO, the primitives GHC has get implemented somehow
2026-04-03 01:51:42 +0000 <EvanR> there are a lot of them
2026-04-03 01:52:06 +0000 <EvanR> if you use GMP based Integer there's also that
2026-04-03 01:53:27 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn
2026-04-03 01:56:14 +0000xff0x(~xff0x@fsb6a9491c.tkyc517.ap.nuro.jp)
2026-04-03 01:57:54 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 255 seconds)
2026-04-03 02:07:24 +0000 <monochrom> I will start with a conversation I overheard. Two 1st-year students were at a cafe discussing logic homework. The homework question was "what is the negation of: everyone wears glasses?". The students first said "is it: no one wears glasses?" But within 10 seconds, "no, that's not right".
2026-04-03 02:08:43 +0000zzz(~zero@user/zero) (Ping timeout: 264 seconds)
2026-04-03 02:08:49 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn
2026-04-03 02:08:54 +0000 <monochrom> So even sophomores can understand that the negation of "all usages of unsafePerformIO are safe" is not "all usages of unsafePerformIO are unsafe".
2026-04-03 02:10:53 +0000 <EvanR> maybe mesaoptimizer wants to see also SafeHaskell
2026-04-03 02:13:20 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 256 seconds)
2026-04-03 02:17:54 +0000zzz(~zero@user/zero) zero
2026-04-03 02:22:12 +0000squid64(~user@fsf/member/squid64) (Ping timeout: 255 seconds)
2026-04-03 02:24:17 +0000merijn(~merijn@62.45.136.136) merijn
2026-04-03 02:24:59 +0000humasect(~humasect@dyn-192-249-132-90.nexicom.net) (Quit: Leaving...)
2026-04-03 02:28:32 +0000merijn(~merijn@62.45.136.136) (Ping timeout: 252 seconds)
2026-04-03 02:33:31 +0000 <mesaoptimizer> c_wraith: it seems like it is accurate for runST, if the type system itself guarantees semantic safety, yes. I do think that the claim is almost deliberately confusing when applied to any expression that contains an `unsafe*` expression though.
2026-04-03 02:34:50 +0000abbies(~abbies@tilde.guru)
2026-04-03 02:35:01 +0000rekahsoft(~rekahsoft@bras-base-orllon1103w-grc-20-76-67-111-168.dsl.bell.ca) (Remote host closed the connection)
2026-04-03 02:35:03 +0000 <geekosaur> given what you quoted, I think it's just making the point that, if you know what you're doing, you can hide known-safe uses of unsafe operations inside pure functions
2026-04-03 02:35:05 +0000 <mesaoptimizer> If you say something is pure, I expect that the language *guarantees* the semantics of it being pure, with the exception of the expression using, say, `unsafePerformIO`. Ergo, you cannot call those functions as those where 'the boundary cannot be violated' -- you already broke the semantic safety guarantees!
2026-04-03 02:35:44 +0000 <mesaoptimizer> geekosaur: yeah that is now my current interpretation of it. it does seem quite confusing though
2026-04-03 02:36:39 +0000abbies(~abbies@tilde.guru) (Client Quit)
2026-04-03 02:37:00 +0000 <mesaoptimizer> reminds me of LLM-generated text, which has triggered similar confusion and dicussion between I and a few of my acquaintances in the past, related to type theory and semantics. I guess its best I abandon reading this essay.
2026-04-03 02:37:48 +0000 <geekosaur> this is no different from https://doc.rust-lang.org/book/ch20-01-unsafe-rust.html
2026-04-03 02:38:40 +0000 <mesaoptimizer> no I get that
2026-04-03 02:38:46 +0000 <geekosaur> since neither compiler can give you static guarantees, it's on you as programmer using unsafe features to prove that you are actually using them safely
2026-04-03 02:39:18 +0000 <davean> geekosaur: About unsafe stuff
2026-04-03 02:39:19 +0000 <mesaoptimizer> I accept the existence of parts of a language that are delineated such that they do not have semantic safety in terms of abstractions that protect you from the underlying computational substrate
2026-04-03 02:39:33 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn
2026-04-03 02:39:47 +0000 <EvanR> that article isn't LLM style at all
2026-04-03 02:39:57 +0000 <EvanR> it's classic "dev speak"
2026-04-03 02:40:00 +0000 <mesaoptimizer> my conclusion is that the essay above is generated using a SOTA LLM, and therefore is adverserially generated to seem insightful, but actually be dangerously wasteful of human time
2026-04-03 02:40:19 +0000 <EvanR> we've seen reports like this for years
2026-04-03 02:40:25 +0000 <EvanR> tales from tech
2026-04-03 02:40:38 +0000 <EvanR> none it seems especially controversial either
2026-04-03 02:40:40 +0000 <Leary> mesaoptimizer: You expect wrong; people use 'pure' just to mean 'pure'; there's no implicit /by construction/.
2026-04-03 02:41:16 +0000 <mesaoptimizer> EvanR: not fully, of course. I imagine maybe the author wrote a bunch of bullet points up and then used an LLM to expand upon it. But all right, I'll give the essay another shot and continue reading it
2026-04-03 02:42:19 +0000 <EvanR> as you wish
2026-04-03 02:42:30 +0000 <mesaoptimizer> Leary: perhaps I misused the word, but my point was about semantic safety, in the sense of Benjamin Pierce's definition in TAPL
2026-04-03 02:42:56 +0000 <mesaoptimizer> so it still stands. It is not specific to Haskell.
2026-04-03 02:42:58 +0000arandombit(~arandombi@user/arandombit) (Ping timeout: 248 seconds)
2026-04-03 02:43:17 +0000 <EvanR> ok if you're going to analyze the article then yeah maybe read it
2026-04-03 02:43:23 +0000 <EvanR> otherwise don't bother
2026-04-03 02:43:57 +0000 <EvanR> (there's a lot in there that is haskell specific, but as far as groundbreaking insights maybe not many)
2026-04-03 02:44:02 +0000 <davean> Yah the obligation is on you to actually think clearly about it.
2026-04-03 02:44:15 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 255 seconds)
2026-04-03 02:44:47 +0000 <mesaoptimizer> EvanR: I disagree about that claim when in a cognitively adverserial environment
2026-04-03 02:44:56 +0000 <mesaoptimizer> ... sorry, that was for davean
2026-04-03 02:45:00 +0000arandombit(~arandombi@2a02:2455:8656:7100:cd4b:38a2:fba4:622b)
2026-04-03 02:45:00 +0000arandombit(~arandombi@2a02:2455:8656:7100:cd4b:38a2:fba4:622b) (Changing host)
2026-04-03 02:45:00 +0000arandombit(~arandombi@user/arandombit) arandombit
2026-04-03 02:45:39 +0000 <mesaoptimizer> EvanR: it started off quite interesting, yes, which is why I even put in the effort to ask about the thing that confused me, so yes, I am reading onwards.
2026-04-03 02:54:22 +0000weary-traveler(~user@user/user363627) user363627
2026-04-03 02:54:56 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn
2026-04-03 02:55:45 +0000bitdex(~bitdex@gateway/tor-sasl/bitdex) bitdex
2026-04-03 02:56:13 +0000 <mesaoptimizer> sidenote: "Your database layer uses connection pooling, retry logic, and mutable state internally. Your cache uses concurrent mutable maps. Your HTTP client probably has circuit breakers, pooled connections, and a small municipal government's worth of bookkeeping." this is a clear indicator that an LLM was used to write this essay
2026-04-03 02:57:22 +0000 <mesaoptimizer> it is quite common for an LLM to add a concrete, supposedly humorous exageration as part of its triadic description for something, and you can see it with "a small municipal government's worth of bookkeeping".
2026-04-03 02:57:31 +0000 <EvanR> we need a new latin fallacy like ad hominem but for attacking the LLM
2026-04-03 02:58:39 +0000 <monochrom> ad machina >:)
2026-04-03 02:58:44 +0000 <mesaoptimizer> erm, I have been paid to do research engineer work on neural networks, and have worked with researchers now at DM and Anthropic
2026-04-03 02:58:54 +0000 <EvanR> that article isn't about LLMs or AI at all so
2026-04-03 02:58:57 +0000 <monochrom> or perhaps ad machinem?
2026-04-03 02:59:37 +0000 <mesaoptimizer> okay, *at least* you aren't saying I'm wrong, I do appreciate that lol
2026-04-03 02:59:37 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 272 seconds)
2026-04-03 02:59:42 +0000 <monochrom> "I do not trust it when a computer says 1+1=2 because it's a stupid computer!"
2026-04-03 03:00:17 +0000 <EvanR> butlerian jihad!
2026-04-03 03:00:20 +0000 <Leary> mesaoptimizer: LLMs do that because they ate a huge amount of text written by humans who did that.
2026-04-03 03:00:44 +0000 <geekosaur> ^
2026-04-03 03:01:19 +0000 <monochrom> Haven't you heard? Those LLMs that have learned from history are doomed to repeat it!
2026-04-03 03:01:27 +0000 <mesaoptimizer> I think the thing you wish to encourage is "read the docs"
2026-04-03 03:01:45 +0000 <mesaoptimizer> or a sort of "hey, look you have to put in the work if you want to master this"
2026-04-03 03:02:14 +0000 <EvanR> what's this in relation to
2026-04-03 03:02:22 +0000 <EvanR> just in general?
2026-04-03 03:02:34 +0000 <EvanR> sure
2026-04-03 03:02:44 +0000 <mesaoptimizer> yeah, I'm confused by the reaction of you guys just now
2026-04-03 03:03:02 +0000 <mesaoptimizer> and yeah I agree, and have found some Haskell papers even more lucid than any introductory textbook, especially the 1997 Wadler / Blott one for typeclasses
2026-04-03 03:04:44 +0000 <mesaoptimizer> this is probably an offtopic thing, but in short, I really really do not think it is a good idea to extend this intuition to text generated by LLMs outright or even partially.
2026-04-03 03:05:27 +0000 <mesaoptimizer> anyway, let's move on
2026-04-03 03:05:28 +0000 <geekosaur> I for one am kinda confused by how you jumped straight to "must be an LLM". there _are_ some clear indications thereof, but your complaints seem more in the "I don't like its style" category
2026-04-03 03:05:55 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn
2026-04-03 03:06:07 +0000 <EvanR> your point started out as the article is a dangerous waste of time but we're still talking about it
2026-04-03 03:06:17 +0000 <geekosaur> LLMs only use the LLM part to interpret prompts and reformat results; the actual work, as best I can determine having read lots of them, is actually generated via Markov chains
2026-04-03 03:06:46 +0000 <geekosaur> the kinds of messes they produce fit that model very well
2026-04-03 03:07:15 +0000 <mesaoptimizer> will reply in #haskell-offtopic.
2026-04-03 03:10:10 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 248 seconds)
2026-04-03 03:21:18 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn
2026-04-03 03:27:49 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 245 seconds)
2026-04-03 03:38:46 +0000bitdex(~bitdex@gateway/tor-sasl/bitdex) (Ping timeout: 265 seconds)
2026-04-03 03:39:21 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn
2026-04-03 03:44:06 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 255 seconds)
2026-04-03 03:54:26 +0000machinedgod(~machinedg@d172-219-48-230.abhsia.telus.net) (Ping timeout: 248 seconds)
2026-04-03 03:55:15 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn
2026-04-03 03:59:52 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 265 seconds)
2026-04-03 04:03:35 +0000sp1ff(~user@2601:1c2:4080:14c0::ace8) sp1ff
2026-04-03 04:09:22 +0000monochrom(trebla@216.138.220.146) (Ping timeout: 244 seconds)
2026-04-03 04:09:29 +0000comonad(~comonad@p200300d02717df00adc247ef70bd7367.dip0.t-ipconnect.de) (Ping timeout: 245 seconds)
2026-04-03 04:10:24 +0000arandombit(~arandombi@user/arandombit) (Ping timeout: 244 seconds)
2026-04-03 04:10:38 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn
2026-04-03 04:10:40 +0000comonad(~comonad@p200300d02717df00adc247ef70bd7367.dip0.t-ipconnect.de)
2026-04-03 04:12:26 +0000monochrom(~trebla@216.138.220.146) monochrom
2026-04-03 04:14:54 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 245 seconds)
2026-04-03 04:15:44 +0000comonad(~comonad@p200300d02717df00adc247ef70bd7367.dip0.t-ipconnect.de) (Ping timeout: 245 seconds)
2026-04-03 04:16:50 +0000comonad(~comonad@p200300d02717df00adc247ef70bd7367.dip0.t-ipconnect.de)
2026-04-03 04:22:53 +0000arandombit(~arandombi@user/arandombit) arandombit
2026-04-03 04:26:00 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn
2026-04-03 04:30:33 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 244 seconds)
2026-04-03 04:32:06 +0000ChaiTRex(~ChaiTRex@user/chaitrex) (Quit: ChaiTRex)
2026-04-03 04:34:54 +0000arandombit(~arandombi@user/arandombit) (Ping timeout: 246 seconds)
2026-04-03 04:40:42 +0000takuan(~takuan@d8D86B9E9.access.telenet.be)
2026-04-03 04:41:27 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn
2026-04-03 04:45:38 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 248 seconds)
2026-04-03 04:46:40 +0000humasect(~humasect@dyn-192-249-132-90.nexicom.net) humasect
2026-04-03 04:49:29 +0000monochrom(~trebla@216.138.220.146) (Ping timeout: 245 seconds)
2026-04-03 04:50:40 +0000monochrom(trebla@216.138.220.146) monochrom
2026-04-03 04:54:10 +0000Nosrep(~jimothy@user/nosrep) (Ping timeout: 248 seconds)
2026-04-03 04:56:58 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn
2026-04-03 04:59:26 +0000somemathguy(~somemathg@user/somemathguy) (Quit: WeeChat 4.1.1)
2026-04-03 05:03:53 +0000ChaiTRex(~ChaiTRex@user/chaitrex) ChaiTRex
2026-04-03 05:03:58 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 268 seconds)
2026-04-03 05:06:21 +0000arandombit(~arandombi@2a02:2455:8656:7100:cd4b:38a2:fba4:622b)
2026-04-03 05:06:21 +0000arandombit(~arandombi@2a02:2455:8656:7100:cd4b:38a2:fba4:622b) (Changing host)
2026-04-03 05:06:21 +0000arandombit(~arandombi@user/arandombit) arandombit
2026-04-03 05:06:56 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn
2026-04-03 05:11:22 +0000arandombit(~arandombi@user/arandombit) (Ping timeout: 268 seconds)
2026-04-03 05:11:43 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 264 seconds)
2026-04-03 05:13:32 +0000ChaiTRex(~ChaiTRex@user/chaitrex) (Quit: ChaiTRex)
2026-04-03 05:22:17 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn
2026-04-03 05:25:50 +0000ChaiTRex(~ChaiTRex@user/chaitrex) ChaiTRex
2026-04-03 05:26:42 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 248 seconds)
2026-04-03 05:32:18 +0000somemathguy(~somemathg@user/somemathguy) somemathguy
2026-04-03 05:37:46 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn
2026-04-03 05:39:57 +0000arandombit(~arandombi@2a02:2455:8656:7100:cd4b:38a2:fba4:622b)
2026-04-03 05:39:57 +0000arandombit(~arandombi@2a02:2455:8656:7100:cd4b:38a2:fba4:622b) (Changing host)
2026-04-03 05:39:57 +0000arandombit(~arandombi@user/arandombit) arandombit
2026-04-03 05:42:06 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 246 seconds)
2026-04-03 05:44:26 +0000arandombit(~arandombi@user/arandombit) (Ping timeout: 244 seconds)
2026-04-03 05:53:05 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn
2026-04-03 05:57:38 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 248 seconds)
2026-04-03 06:00:47 +0000ChaiTRex(~ChaiTRex@user/chaitrex) (Remote host closed the connection)
2026-04-03 06:02:46 +0000ChaiTRex(~ChaiTRex@user/chaitrex) ChaiTRex
2026-04-03 06:02:58 +0000jmcantrell_(~weechat@user/jmcantrell) (Ping timeout: 248 seconds)
2026-04-03 06:07:57 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn
2026-04-03 06:11:50 +0000attlin(~user@user/attlin) (Ping timeout: 245 seconds)
2026-04-03 06:12:36 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 255 seconds)
2026-04-03 06:15:02 +0000arandombit(~arandombi@user/arandombit) arandombit
2026-04-03 06:23:18 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn
2026-04-03 06:23:52 +0000attlin(~user@216.126.236.136)
2026-04-03 06:23:52 +0000attlin(~user@216.126.236.136) (Changing host)
2026-04-03 06:23:52 +0000attlin(~user@user/attlin) attlin
2026-04-03 06:27:46 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 256 seconds)
2026-04-03 06:32:43 +0000karenw(~karenw@user/karenw) (Ping timeout: 264 seconds)
2026-04-03 06:38:40 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn
2026-04-03 06:40:06 +0000somemathguy(~somemathg@user/somemathguy) (Quit: WeeChat 4.1.1)
2026-04-03 06:45:06 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 246 seconds)
2026-04-03 06:45:38 +0000qqq(~qqq@185.54.23.237)
2026-04-03 06:49:13 +0000GdeVolpiano(~GdeVolpia@user/GdeVolpiano) (Ping timeout: 248 seconds)
2026-04-03 06:53:01 +0000GdeVolpiano(~GdeVolpia@user/GdeVolpiano) GdeVolpiano
2026-04-03 06:56:43 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn
2026-04-03 07:01:12 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 255 seconds)
2026-04-03 07:02:42 +0000CiaoSen(~Jura@p549cb690.dip0.t-ipconnect.de) CiaoSen
2026-04-03 07:08:58 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn
2026-04-03 07:13:35 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 272 seconds)
2026-04-03 07:16:33 +0000arandombit(~arandombi@user/arandombit) (Ping timeout: 268 seconds)
2026-04-03 07:17:20 +0000sim590(~simon@2001:18c0:a82:2400::9fb) (Quit: WeeChat 4.8.2)
2026-04-03 07:24:21 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn
2026-04-03 07:25:42 +0000CiaoSen(~Jura@p549cb690.dip0.t-ipconnect.de) (Ping timeout: 244 seconds)
2026-04-03 07:27:55 +0000CiaoSen(~Jura@p549cb690.dip0.t-ipconnect.de) CiaoSen
2026-04-03 07:28:30 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 245 seconds)
2026-04-03 07:32:25 +0000arandombit(~arandombi@2a02:2455:8656:7100:cd4b:38a2:fba4:622b)
2026-04-03 07:32:25 +0000arandombit(~arandombi@2a02:2455:8656:7100:cd4b:38a2:fba4:622b) (Changing host)
2026-04-03 07:32:25 +0000arandombit(~arandombi@user/arandombit) arandombit
2026-04-03 07:37:45 +0000arandombit(~arandombi@user/arandombit) (Ping timeout: 248 seconds)
2026-04-03 07:39:43 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn
2026-04-03 07:44:18 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 268 seconds)
2026-04-03 07:46:45 +0000Sgeo(~Sgeo@user/sgeo) (Read error: Connection reset by peer)
2026-04-03 07:51:11 +0000arandombit(~arandombi@2a02:2455:8656:7100:cd4b:38a2:fba4:622b)
2026-04-03 07:51:11 +0000arandombit(~arandombi@2a02:2455:8656:7100:cd4b:38a2:fba4:622b) (Changing host)
2026-04-03 07:51:11 +0000arandombit(~arandombi@user/arandombit) arandombit
2026-04-03 07:55:04 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn
2026-04-03 07:56:00 +0000humasect(~humasect@dyn-192-249-132-90.nexicom.net) (Remote host closed the connection)
2026-04-03 07:58:01 +0000CiaoSen(~Jura@p549cb690.dip0.t-ipconnect.de) (Ping timeout: 248 seconds)
2026-04-03 07:58:26 +0000arandombit(~arandombi@user/arandombit) (Ping timeout: 256 seconds)
2026-04-03 07:58:46 +0000qqq(~qqq@185.54.23.237) (Remote host closed the connection)
2026-04-03 07:59:34 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 256 seconds)
2026-04-03 08:05:34 +0000humasect(~humasect@dyn-192-249-132-90.nexicom.net) humasect
2026-04-03 08:07:00 +0000merijn(~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn
2026-04-03 08:09:18 +0000CiaoSen(~Jura@p549cb690.dip0.t-ipconnect.de) CiaoSen
2026-04-03 08:10:42 +0000emmanuelux(~em@user/emmanuelux) (Quit: bye)
2026-04-03 08:12:40 +0000qqq(~qqq@185.54.23.237)
2026-04-03 08:20:13 +0000rabbull(~rabbull@user/rabbull) (Read error: Connection reset by peer)
2026-04-03 08:20:33 +0000rabbull(~rabbull@user/rabbull) rabbull
2026-04-03 08:22:12 +0000acidjnk_new3(~acidjnk@p200300d6e700e5002ce9abe45c9e09a5.dip0.t-ipconnect.de)
2026-04-03 08:23:44 +0000__monty__(~toonn@user/toonn) toonn
2026-04-03 08:32:43 +0000CiaoSen(~Jura@p549cb690.dip0.t-ipconnect.de) (Ping timeout: 264 seconds)
2026-04-03 08:36:00 +0000Digit(~user@user/digit) (Ping timeout: 245 seconds)
2026-04-03 08:41:11 +0000arandombit(~arandombi@2a02:2455:8656:7100:cd4b:38a2:fba4:622b)
2026-04-03 08:41:11 +0000arandombit(~arandombi@2a02:2455:8656:7100:cd4b:38a2:fba4:622b) (Changing host)
2026-04-03 08:41:11 +0000arandombit(~arandombi@user/arandombit) arandombit
2026-04-03 08:45:50 +0000arandombit(~arandombi@user/arandombit) (Ping timeout: 252 seconds)
2026-04-03 08:51:24 +0000Guest62(~Guest62@p200300ca8f128700b6df0e37d8ec3f22.dip0.t-ipconnect.de)
2026-04-03 08:55:31 +0000rembo10_(~rembo10@main.remulis.com) (Quit: ZNC 1.10.1 - https://znc.in)
2026-04-03 08:56:21 +0000rembo10(~rembo10@main.remulis.com) rembo10
2026-04-03 08:58:06 +0000Tuplanolla(~Tuplanoll@88-114-89-88.elisa-laajakaista.fi) Tuplanolla
2026-04-03 09:00:52 +0000arandombit(~arandombi@user/arandombit) arandombit
2026-04-03 09:02:55 +0000humasect(~humasect@dyn-192-249-132-90.nexicom.net) (Remote host closed the connection)
2026-04-03 09:07:23 +0000Guest62(~Guest62@p200300ca8f128700b6df0e37d8ec3f22.dip0.t-ipconnect.de) (Quit: Client closed)
2026-04-03 09:10:10 +0000synchromesh(~john@2406:5a00:2412:2c00:fc97:d0a4:cdd9:afc1) (Read error: Connection reset by peer)
2026-04-03 09:11:03 +0000synchromesh(~john@2406:5a00:2412:2c00:343e:4e23:bce:73a3) synchromesh
2026-04-03 09:12:25 +0000Digitteknohippie(~user@user/digit) Digit
2026-04-03 09:12:28 +0000Square3(~Square@user/square) Square
2026-04-03 09:19:14 +0000DigitteknohippieDigit
2026-04-03 09:54:17 +0000xff0x(~xff0x@fsb6a9491c.tkyc517.ap.nuro.jp) (Ping timeout: 248 seconds)
2026-04-03 10:02:26 +0000arandombit(~arandombi@user/arandombit) (Ping timeout: 268 seconds)
2026-04-03 10:07:12 +0000califax(~califax@user/califx) (Remote host closed the connection)
2026-04-03 10:07:22 +0000Square3(~Square@user/square) (Ping timeout: 268 seconds)
2026-04-03 10:07:25 +0000califax(~califax@user/califx) califx
2026-04-03 10:10:37 +0000arandombit(~arandombi@2a02:2455:8656:7100:cd4b:38a2:fba4:622b)
2026-04-03 10:10:37 +0000arandombit(~arandombi@2a02:2455:8656:7100:cd4b:38a2:fba4:622b) (Changing host)
2026-04-03 10:10:37 +0000arandombit(~arandombi@user/arandombit) arandombit
2026-04-03 10:16:14 +0000acidjnk_new(~acidjnk@p200300d6e700e5029fa95e10e4e0754b.dip0.t-ipconnect.de) acidjnk
2026-04-03 10:19:21 +0000acidjnk_new3(~acidjnk@p200300d6e700e5002ce9abe45c9e09a5.dip0.t-ipconnect.de) (Ping timeout: 248 seconds)
2026-04-03 10:20:29 +0000__monty__(~toonn@user/toonn) (Quit: leaving)
2026-04-03 10:47:43 +0000arandombit(~arandombi@user/arandombit) (Ping timeout: 244 seconds)
2026-04-03 10:48:40 +0000 <gentauro> > :i newStdGen
2026-04-03 10:48:41 +0000 <lambdabot> <hint>:1:1: error: parse error on input `:'
2026-04-03 10:48:46 +0000 <gentauro> % :i newStdGen
2026-04-03 10:48:46 +0000 <yahb2> <interactive>:1:1: error: [GHC-76037] Not in scope: ‘newStdGen’
2026-04-03 10:49:05 +0000 <gentauro> % import System.Random
2026-04-03 10:49:05 +0000 <yahb2> <no location info>: error: [GHC-35235] ; Could not find module ‘System.Random’. ; It is not a module in the current program, or in any known package.
2026-04-03 10:49:08 +0000 <gentauro> > import System.Random
2026-04-03 10:49:09 +0000 <lambdabot> <hint>:1:1: error: parse error on input `import'
2026-04-03 11:02:13 +0000wootehfoot(~wootehfoo@user/wootehfoot) (Read error: Connection reset by peer)
2026-04-03 11:43:04 +0000 <tomsmeding> gentauro: random is not a boot library
2026-04-03 11:44:30 +0000 <tomsmeding> %% System.Process.system "ghc-pkg --global list"
2026-04-03 11:44:30 +0000 <yahb2> https://paste.tomsmeding.com/SSJGWZ5X
2026-04-03 11:56:46 +0000wootehfoot(~wootehfoo@user/wootehfoot) wootehfoot
2026-04-03 12:03:32 +0000czan(~czan@user/mange) czan
2026-04-03 12:12:45 +0000 <gentauro> tomsmeding: :(
2026-04-03 12:13:22 +0000 <gentauro> tomsmeding: how do you invoke our Lord and Saviour RNGesus here?
2026-04-03 12:24:35 +0000xff0x(~xff0x@2405:6580:b080:900:ec01:f28c:6f01:3489)
2026-04-03 12:25:54 +0000tromp(~textual@2001:1c00:340e:2700:f5b2:b468:1c7d:8570)
2026-04-03 12:30:57 +0000somemathguy(~somemathg@user/somemathguy) somemathguy
2026-04-03 12:32:25 +0000 <tomsmeding> % :m Data.Bits Data.Word
2026-04-03 12:32:25 +0000 <yahb2> <no output>
2026-04-03 12:32:37 +0000 <tomsmeding> % data RNG = RNG Word64 Word64 Word64 Word64 deriving (Show) -- https://arxiv.org/pdf/2312.17043 CWG64
2026-04-03 12:32:37 +0000 <yahb2> <no output>
2026-04-03 12:32:43 +0000 <tomsmeding> % cwg64 :: RNG -> (Word64, RNG) ; cwg64 (RNG x a w s) = let x' = (x `quot` 2) * ((a + x) .|. 1) `xor` (w + s) in (a `shiftR` 48 `xor` x', RNG x' (a+x) (w+s) s)
2026-04-03 12:32:43 +0000 <yahb2> <no output>
2026-04-03 12:32:48 +0000 <tomsmeding> % newRNG :: Word64 -> RNG ; newRNG seed = iterate (snd . cwg64) (RNG 0 0 0 (2*seed+1)) !! 48
2026-04-03 12:32:48 +0000 <yahb2> <no output>
2026-04-03 12:33:24 +0000 <tomsmeding> % take 4 . map fst . iterate (cwg64 . snd) $ cwg64 (newRNG 42)
2026-04-03 12:33:24 +0000 <yahb2> [14283230361796893884,4031505161053706,7205329903210052340,4002821135440951121]
2026-04-03 12:34:53 +0000 <tomsmeding> % cwg64 :: RNG -> (Word64, RNG) ; cwg64 (RNG x a w s) = let x' = (x `quot` 2) * ((a + x) .|. 1) `xor` (w + s) in ((a+x) `shiftR` 48 `xor` x', RNG x' (a+x) (w+s) s)
2026-04-03 12:34:53 +0000 <yahb2> <no output>
2026-04-03 12:34:56 +0000 <tomsmeding> % take 4 . map fst . iterate (cwg64 . snd) $ cwg64 (newRNG 42)
2026-04-03 12:34:56 +0000 <yahb2> [14283230361796891556,4031505161050178,7205329903210052357,4002821135440958291]
2026-04-03 12:35:48 +0000 <tomsmeding> ... interesting, that typo didn't change the results; I wonder if that means that x just doesn't have high bits?
2026-04-03 12:36:00 +0000 <tomsmeding> ¯\_(ツ)_/¯
2026-04-03 12:50:32 +0000craunts795335385(~craunts@152.32.99.2) (Quit: The Lounge - https://thelounge.chat)
2026-04-03 13:02:57 +0000tromp(~textual@2001:1c00:340e:2700:f5b2:b468:1c7d:8570) (Quit: My iMac has gone to sleep. ZZZzzz…)
2026-04-03 13:05:00 +0000divlamir(~divlamir@user/divlamir) (Read error: Connection reset by peer)
2026-04-03 13:05:19 +0000 <int-e> % Data.ByteString.Lazy.take 32 <$> Data.ByteString.Lazy.readFile "/dev/urandom"
2026-04-03 13:05:19 +0000 <yahb2> *** Exception: /dev/urandom: openBinaryFile: does not exist (No such file or directory) ; ; HasCallStack backtrace: ; ioError, called at libraries/ghc-internal/src/GHC/Internal/Foreign/C/Error.h...
2026-04-03 13:05:26 +0000divlamir(~divlamir@user/divlamir) divlamir
2026-04-03 13:05:27 +0000 <int-e> oh, haha
2026-04-03 13:05:52 +0000czan(~czan@user/mange) (Quit: Zzz...)
2026-04-03 13:11:11 +0000tromp(~textual@2001:1c00:340e:2700:f5b2:b468:1c7d:8570)
2026-04-03 13:18:40 +0000 <int-e> % foreign import ccall getrandom :: Ptr a -> CSize -> CInt -> IO CSize
2026-04-03 13:18:40 +0000 <yahb2> <no output>
2026-04-03 13:18:40 +0000synchromesh(~john@2406:5a00:2412:2c00:343e:4e23:bce:73a3) (Read error: Connection reset by peer)
2026-04-03 13:18:50 +0000 <int-e> % alloca (\p -> getrandom p 8 0 >> peek p) :: IO Word
2026-04-03 13:18:50 +0000 <yahb2> 1080570571463088587
2026-04-03 13:19:48 +0000synchromesh(~john@2406:5a00:2412:2c00:343e:4e23:bce:73a3) synchromesh
2026-04-03 13:32:30 +0000 <tomsmeding> int-e: cool
2026-04-03 13:33:45 +0000 <tomsmeding> % :q
2026-04-03 13:33:45 +0000 <yahb2> <bye>
2026-04-03 13:33:51 +0000 <tomsmeding> % Data.ByteString.Lazy.take 32 <$> Data.ByteString.Lazy.readFile "/dev/urandom"
2026-04-03 13:33:51 +0000 <yahb2> "V4\205\ESC\247Kv\194\EOT\144\DLEf\165\211%\201\197&\156\ESC\190\CAN*\RS\CAN\215Fj\"\226n\CAN"
2026-04-03 13:34:07 +0000 <tomsmeding> added it to the sandbox
2026-04-03 13:34:38 +0000 <tomsmeding> gentauro: ^
2026-04-03 13:42:18 +0000somemathguy(~somemathg@user/somemathguy) (Ping timeout: 246 seconds)
2026-04-03 13:47:29 +0000byorgey(~byorgey@user/byorgey) (Quit: leaving)
2026-04-03 13:48:13 +0000 <gentauro> :)
2026-04-03 13:57:40 +0000acidjnk_new(~acidjnk@p200300d6e700e5029fa95e10e4e0754b.dip0.t-ipconnect.de) (Ping timeout: 245 seconds)
2026-04-03 13:59:35 +0000Nosrep(~jimothy@user/nosrep) Nosrep
2026-04-03 14:05:23 +0000GdeVolpiano(~GdeVolpia@user/GdeVolpiano) (Ping timeout: 252 seconds)
2026-04-03 14:07:22 +0000GdeVolpiano(~GdeVolpia@user/GdeVolpiano) GdeVolpiano
2026-04-03 14:14:38 +0000haritz(~hrtz@140.228.70.141)
2026-04-03 14:14:38 +0000haritz(~hrtz@140.228.70.141) (Changing host)
2026-04-03 14:14:38 +0000haritz(~hrtz@user/haritz) haritz
2026-04-03 14:25:12 +0000qqq(~qqq@185.54.23.237) (Remote host closed the connection)
2026-04-03 14:27:15 +0000somemathguy(~somemathg@user/somemathguy) somemathguy
2026-04-03 14:38:27 +0000tromp(~textual@2001:1c00:340e:2700:f5b2:b468:1c7d:8570) (Quit: My iMac has gone to sleep. ZZZzzz…)
2026-04-03 14:44:32 +0000tromp(~textual@2001:1c00:340e:2700:f5b2:b468:1c7d:8570)
2026-04-03 14:51:27 +0000Digit(~user@user/digit) (Ping timeout: 255 seconds)
2026-04-03 14:53:13 +0000craunts795335385(~craunts@152.32.99.2)
2026-04-03 15:12:31 +0000jmcantrell_(~weechat@user/jmcantrell) jmcantrell
2026-04-03 15:23:21 +0000absurdvoid(~absurdvoi@user/absurdvoid) absurdvoid
2026-04-03 15:24:30 +0000 <monochrom> % Data.ByteString.Lazy.take 32 <$> Data.ByteString.Lazy.readFile "/dev/urandom"
2026-04-03 15:24:30 +0000 <yahb2> ":>\164\&6\135-;\215\226?\250a\130\DC1\162\159\234\130\145p9\235\244YPY\DC1\241\240l\148{"
2026-04-03 15:24:50 +0000 <monochrom> (Just testing whether it's always the same string. >:) )
2026-04-03 15:25:06 +0000olivial(~benjaminl@user/benjaminl) (Ping timeout: 248 seconds)
2026-04-03 15:30:22 +0000pavonia(~user@user/siracusa) (Quit: Bye!)
2026-04-03 15:35:14 +0000olivial(~benjaminl@user/benjaminl) benjaminl
2026-04-03 15:37:31 +0000Ranhir(~Ranhir@157.97.53.139) (Ping timeout: 264 seconds)
2026-04-03 15:43:08 +0000tromp(~textual@2001:1c00:340e:2700:f5b2:b468:1c7d:8570) (Quit: My iMac has gone to sleep. ZZZzzz…)
2026-04-03 15:50:04 +0000 <EvanR> does lowenheim skolem paradox have anything to do with the occasional "surprise" that haskell can have uncountable "sets", since this paradox relies on the idea of a first order logic
2026-04-03 15:50:09 +0000 <EvanR> er skolem's paradox
2026-04-03 15:51:22 +0000L29Ah(~L29Ah@wikipedia/L29Ah) ()
2026-04-03 15:51:50 +0000 <EvanR> since haskell isn't logic and I'm not sure where it sits on first or second orderness, maybe not. But seems like a similar phenomenon
2026-04-03 16:04:43 +0000tromp(~textual@2001:1c00:340e:2700:f5b2:b468:1c7d:8570)
2026-04-03 16:23:04 +0000rekahsoft(~rekahsoft@76.67.111.168) rekahsoft
2026-04-03 16:37:08 +0000 <gentauro> https://abuseofnotation.github.io/category-theory-illustrated/ <- 🤯
2026-04-03 16:37:14 +0000 <gentauro> just wow !!!
2026-04-03 16:37:29 +0000gentauroI can see that Panic is going to be present at Zurihach 2026
2026-04-03 16:51:01 +0000machinedgod(~machinedg@d172-219-48-230.abhsia.telus.net) machinedgod
2026-04-03 17:00:29 +0000 <monochrom> Yes I think Skolem's paradox applies. Maybe with adjustments to technical details that don't really change the conclusion.
2026-04-03 17:01:55 +0000 <monochrom> (Natural -> Bool) looks like an uncountable space, from inside the system.
2026-04-03 17:02:18 +0000L29Ah(~L29Ah@wikipedia/L29Ah) L29Ah
2026-04-03 17:04:26 +0000tromp(~textual@2001:1c00:340e:2700:f5b2:b468:1c7d:8570) (Quit: My iMac has gone to sleep. ZZZzzz…)
2026-04-03 17:06:25 +0000jmcantrell_(~weechat@user/jmcantrell) (Ping timeout: 245 seconds)
2026-04-03 17:06:39 +0000 <monochrom> If you worry about Haskell not having a nice correspondence with logic (it has some correspondence, just messier), Lean would be a nicer example to look at. For Lean, I haven't thought about Skolem's paradox, but I have thought about parametricity. If you define a "foo :: a -> [a]" in Lean, you cannot prove that it's parametric from inside Lean. (You can and have to step outside and make it a meta-level theorem and proof.)
2026-04-03 17:07:12 +0000 <c_wraith> Haskell is perfectly logical. It just doesn't require a consistent logic.
2026-04-03 17:07:37 +0000 <monochrom> The analogy being: From inside Lean, the space of forall a. a -> [a] looks larger than what parametricity promises.
2026-04-03 17:12:39 +0000puke(~puke@user/puke) puke
2026-04-03 17:12:59 +0000 <monochrom> Err I misspoke. For each individual foo that you know the implementation of, you can prove the free theorem for that foo based on its implementation. But you can't within Lean prove the free theorem for the type "forall a. a -> [a]".
2026-04-03 17:13:00 +0000puke(~puke@user/puke) (Max SendQ exceeded)
2026-04-03 17:13:33 +0000arandombit(~arandombi@user/arandombit) arandombit
2026-04-03 17:14:56 +0000 <EvanR> what is the free theorem, that foo has to yield some number of copies of the input
2026-04-03 17:15:16 +0000 <monochrom> @free foo :: a -> [a]
2026-04-03 17:15:17 +0000 <lambdabot> $map f . foo = foo . f
2026-04-03 17:15:26 +0000 <EvanR> o_O
2026-04-03 17:15:27 +0000puke(~puke@user/puke) puke
2026-04-03 17:16:01 +0000 <c_wraith> I mean... yes. that *is* the same as saying it's producing some number of copies of the input, though it's expressed in a slightly funny way
2026-04-03 17:16:01 +0000 <monochrom> That's abstract. But if you try one single test case "foo ()" and get [(), ()], then you know that foo x = [x,x] for all x for all types.
2026-04-03 17:16:56 +0000 <monochrom> If you add the wording "that 'some number' is the same for all inputs for all types", then it's right on.
2026-04-03 17:16:57 +0000puke(~puke@user/puke) (Max SendQ exceeded)
2026-04-03 17:17:42 +0000puke(~puke@user/puke) puke
2026-04-03 17:19:14 +0000puke(~puke@user/puke) (Max SendQ exceeded)
2026-04-03 17:19:59 +0000puke(~puke@user/puke) puke
2026-04-03 17:21:08 +0000tromp(~textual@2001:1c00:340e:2700:f5b2:b468:1c7d:8570)
2026-04-03 17:21:17 +0000jmcantrell_(~weechat@user/jmcantrell) jmcantrell
2026-04-03 17:21:26 +0000puke(~puke@user/puke) (Max SendQ exceeded)
2026-04-03 17:21:28 +0000 <monochrom> Suppose you know from testing foo () = [(),()], and now you wonder about foo 4. Choose f = const 4. So map (const 4) (foo ()) = foo (const 4 ()), so [4,4] = foo 4.
2026-04-03 17:21:57 +0000puke(~puke@user/puke) puke
2026-04-03 17:21:59 +0000puke(~puke@user/puke) (Remote host closed the connection)
2026-04-03 17:22:02 +0000humasect(~humasect@dyn-192-249-132-90.nexicom.net) humasect
2026-04-03 17:30:34 +0000puke(~puke@user/puke) puke
2026-04-03 17:32:13 +0000craunts795335385(~craunts@152.32.99.2) (Quit: The Lounge - https://thelounge.chat)
2026-04-03 17:32:22 +0000 <monochrom> Here is how your idea is not too far off from the abstract equation. Suppose you say "∃n. ∀x. foo x = replicate n x".
2026-04-03 17:33:27 +0000 <EvanR> ok, I messed up because it's not just some arbitrary n, it's the same n for all types
2026-04-03 17:33:29 +0000 <monochrom> That "∃n" is annoying and elusive, especially since we know exactly how to obtain that n. It's length (foo ()).
2026-04-03 17:34:17 +0000 <monochrom> ∀x. foo x = replicate (length (foo ()) x
2026-04-03 17:34:35 +0000 <dolio> Common lean practice is to assume there are non-parametric functions.
2026-04-03 17:34:55 +0000 <monochrom> But I can simplify "replicate (length (foo ()) x" to "map (const x) (foo ())". Bonus: Now it covers infinite lists too!
2026-04-03 17:36:05 +0000 <monochrom> ∀x. foo x = map (const x) (foo ()). Now @pointfree to get: foo . const x = map (const x) . foo
2026-04-03 17:36:09 +0000 <int-e> :t \x -> [undefined, x, undefined]
2026-04-03 17:36:10 +0000 <lambdabot> a -> [a]
2026-04-03 17:36:18 +0000arandombit(~arandombi@user/arandombit) (Ping timeout: 268 seconds)
2026-04-03 17:36:25 +0000 <monochrom> The abstract equation merely generalizes from const x to arbitrary f.
2026-04-03 17:37:03 +0000 <EvanR> what's a "non-parametric function" besides the obvious
2026-04-03 17:37:07 +0000puke(~puke@user/puke) (Quit: puke)
2026-04-03 17:37:17 +0000 <EvanR> a function that's not parametric
2026-04-03 17:37:23 +0000puke(~puke@user/puke) puke
2026-04-03 17:37:41 +0000 <monochrom> foo x = if x is an Int and x==4 then [1,2,3,x,x^2,42,67] else [x,x,x]
2026-04-03 17:37:48 +0000 <dolio> E.G. `f : ∀a. a -> a` where `f` is the identity on most types, but `not` on `Bool`.
2026-04-03 17:38:05 +0000 <monochrom> anything that violates free theorems.
2026-04-03 17:38:48 +0000 <int-e> dolio: nice use of `not` in a sentence :)
2026-04-03 17:38:48 +0000 <EvanR> I might be too far gone, I never think of stuff like that xD
2026-04-03 17:38:59 +0000 <EvanR> but it comes up a lot when trying to explain haskell polymorphism
2026-04-03 17:39:57 +0000 <EvanR> oh a double not
2026-04-03 17:40:17 +0000 <dolio> Java is not parametric, either, because of `instanceof`.
2026-04-03 17:40:20 +0000 <EvanR> didn't see the quotes at first
2026-04-03 17:40:41 +0000 <monochrom> Also of toString().
2026-04-03 17:40:57 +0000 <dolio> But in lean's case it's because people usually assume excluded middle and global choice.
2026-04-03 17:41:25 +0000 <EvanR> excluded middle ruins parametricity?
2026-04-03 17:41:30 +0000 <dolio> Yeah.
2026-04-03 17:41:38 +0000 <EvanR> o_O
2026-04-03 17:42:07 +0000 <monochrom> So on parametricity homework I pose "if we listened to Java people, then foo :: Show a => a -> [a], now write your foo so that foo () = [(),()] but foo 4 = [1,2,3]"
2026-04-03 17:42:53 +0000 <dolio> Excluded middle tells you whether a type is empty or not.
2026-04-03 17:43:05 +0000 <monochrom> Oh darn haha
2026-04-03 17:43:14 +0000 <EvanR> how does that help
2026-04-03 17:43:26 +0000 <dolio> It's just not parametric over all types.
2026-04-03 17:43:48 +0000 <dolio> Some are empty, some aren't. You don't get back the same 'yes/no' answer regardless of type.
2026-04-03 17:44:13 +0000 <EvanR> oh
2026-04-03 17:44:36 +0000 <monochrom> With parametricity, bar :: [a] implies bar = []. But what if you wrote "bar = if a is empty then [] else let x = choose an element from a in [x,x,x]"
2026-04-03 17:45:09 +0000 <EvanR> list makes it clear again
2026-04-03 17:45:57 +0000 <monochrom> But I like dolio's. tellMe :: a -> Bool should be const True or const False, not tell you whether a is empty.
2026-04-03 17:46:44 +0000 <dolio> It's really `tellMe :: forall a. Bool`
2026-04-03 17:47:00 +0000 <dolio> If you have to provide an a, then the answer must be yes. :)
2026-04-03 17:47:09 +0000 <monochrom> haha
2026-04-03 17:47:18 +0000 <monochrom> Proxy a -> Bool!
2026-04-03 17:47:36 +0000 <dolio> Yeah, that'd work.
2026-04-03 17:48:35 +0000 <EvanR> yeah
2026-04-03 17:48:38 +0000 <monochrom> I guess today's Haskell has "forall a -> Bool" as a middle ground.
2026-04-03 17:48:43 +0000 <EvanR> I was trying to figure out how to fix a -> Bool
2026-04-03 17:49:11 +0000 <EvanR> forall a . Bool ...
2026-04-03 17:49:13 +0000 <EvanR> lol
2026-04-03 17:49:28 +0000 <monochrom> @free tellMe :: [a] -> Bool
2026-04-03 17:49:28 +0000 <lambdabot> tellMe = tellMe . $map f
2026-04-03 17:49:29 +0000 <dolio> Apparently that is a way of characterizing parametricity 'semantically', too. For all `A : U` then `f : U -> A` must be constant, basically.
2026-04-03 17:49:45 +0000confusedalex(~confuseda@user/confusedalex) (Ping timeout: 245 seconds)
2026-04-03 17:49:47 +0000 <dolio> Where U is the 'universe'.
2026-04-03 17:49:52 +0000confusedalex_(~confuseda@user/confusedalex) confusedalex
2026-04-03 17:50:03 +0000confusedalex_confusedalex
2026-04-03 17:50:28 +0000L29Ah(~L29Ah@wikipedia/L29Ah) ()
2026-04-03 17:50:35 +0000 <dolio> Instead of the relational way.
2026-04-03 17:53:01 +0000 <monochrom> Oh interesting, because "constant [over types]" is short for "the same code for all types".
2026-04-03 17:53:32 +0000 <monochrom> which is what I tell beginners if I'm not ready to tell the relational story.
2026-04-03 17:54:14 +0000 <dolio> Yeah. I recently heard about this, and like it better, because it seems closer to the intuitive idea of parametricity.
2026-04-03 17:57:54 +0000 <dolio> You can probably generalize it so that it doesn't depend so much on relative 'size' too.
2026-04-03 17:59:31 +0000 <dolio> Like, there is T parametricity for a class of types if for all A in that class, functions T -> A must be constant, or something.
2026-04-03 18:07:02 +0000confusedalex_(~confuseda@user/confusedalex) confusedalex
2026-04-03 18:07:15 +0000jmcantrell_(~weechat@user/jmcantrell) (Ping timeout: 246 seconds)
2026-04-03 18:08:06 +0000confusedalex(~confuseda@user/confusedalex) (Ping timeout: 255 seconds)
2026-04-03 18:08:06 +0000confusedalex_confusedalex