| 2026-06-23 00:01:36 +0000 | dtman34 | (~dtman34@2601:447:d17d:eaf2:8123:c1ff:6dae:d26b) (Quit: ZNC 1.8.2+deb3.1+deb12u1 - https://znc.in) |
| 2026-06-23 00:01:43 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 252 seconds) |
| 2026-06-23 00:01:59 +0000 | dtman34 | (~dtman34@c-73-242-68-179.hsd1.mn.comcast.net) dtman34 |
| 2026-06-23 00:12:56 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn |
| 2026-06-23 00:17:45 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 264 seconds) |
| 2026-06-23 00:28:15 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn |
| 2026-06-23 00:33:03 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 252 seconds) |
| 2026-06-23 00:35:17 +0000 | xff0x | (~xff0x@2405:6580:b080:900:df45:9308:76fe:d30b) (Quit: xff0x) |
| 2026-06-23 00:36:49 +0000 | xff0x | (~xff0x@2405:6580:b080:900:a40e:e1eb:bacb:147b) |
| 2026-06-23 00:37:46 +0000 | czan | (~czan@user/mange) czan |
| 2026-06-23 00:41:35 +0000 | CloneOfNone | (~CloneOfNo@user/CloneOfNone) (Quit: ZNC 1.10.1 - https://znc.in) |
| 2026-06-23 00:43:37 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn |
| 2026-06-23 00:48:05 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 245 seconds) |
| 2026-06-23 00:48:28 +0000 | CloneOfNone | (~CloneOfNo@user/CloneOfNone) CloneOfNone |
| 2026-06-23 00:50:06 +0000 | xff0x | (~xff0x@2405:6580:b080:900:a40e:e1eb:bacb:147b) (Ping timeout: 252 seconds) |
| 2026-06-23 00:50:09 +0000 | Enigmagic | (~Enigmagic@user/Enigmagic) (Ping timeout: 246 seconds) |
| 2026-06-23 00:56:01 +0000 | divya- | (divya@140.238.251.170) divya |
| 2026-06-23 00:57:43 +0000 | divya- | divya |
| 2026-06-23 00:58:59 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn |
| 2026-06-23 01:02:58 +0000 | tremon | (~tremon@83-80-159-219.cable.dynamic.v4.ziggo.nl) (Quit: getting boxed in) |
| 2026-06-23 01:03:27 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 246 seconds) |
| 2026-06-23 01:03:41 +0000 | Enigmagic | (~Enigmagic@user/Enigmagic) Enigmagic |
| 2026-06-23 01:13:51 +0000 | vanishingideal | (~vanishing@user/vanishingideal) (Ping timeout: 271 seconds) |
| 2026-06-23 01:14:22 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn |
| 2026-06-23 01:19:20 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 265 seconds) |
| 2026-06-23 01:24:17 +0000 | bdkl | (~bdkl@user/bdkl) bdkl |
| 2026-06-23 01:29:55 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn |
| 2026-06-23 01:34:31 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 264 seconds) |
| 2026-06-23 01:35:46 +0000 | xff0x | (~xff0x@fsb6a9491c.tkyc517.ap.nuro.jp) |
| 2026-06-23 01:39:36 +0000 | bdkl | (~bdkl@user/bdkl) (Quit: bdkl) |
| 2026-06-23 01:45:20 +0000 | merijn | (~merijn@62.45.136.136) merijn |
| 2026-06-23 01:45:38 +0000 | vanishingideal | (~vanishing@user/vanishingideal) vanishingideal |
| 2026-06-23 01:49:29 +0000 | merijn | (~merijn@62.45.136.136) (Ping timeout: 245 seconds) |
| 2026-06-23 01:58:07 +0000 | weary-traveler | (~user@user/user363627) user363627 |
| 2026-06-23 02:00:39 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn |
| 2026-06-23 02:06:02 +0000 | leppard | (~noOne@ipservice-092-209-218-237.092.209.pools.vodafone-ip.de) (Ping timeout: 248 seconds) |
| 2026-06-23 02:07:27 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 276 seconds) |
| 2026-06-23 02:11:29 +0000 | td_ | (~td@i53870915.versanet.de) (Ping timeout: 256 seconds) |
| 2026-06-23 02:13:14 +0000 | td_ | (~td@i53870934.versanet.de) |
| 2026-06-23 02:16:00 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn |
| 2026-06-23 02:22:36 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 240 seconds) |
| 2026-06-23 02:28:05 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn |
| 2026-06-23 02:36:08 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 245 seconds) |
| 2026-06-23 02:36:12 +0000 | vanishingideal | (~vanishing@user/vanishingideal) (Ping timeout: 256 seconds) |
| 2026-06-23 02:43:28 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn |
| 2026-06-23 02:45:36 +0000 | yin | (~zero@user/zero) (Ping timeout: 252 seconds) |
| 2026-06-23 02:46:06 +0000 | emilym | (~Thunderbi@user/emilym) emilym |
| 2026-06-23 02:48:16 +0000 | statusbot8 | (~statusbot@ec2-34-198-122-184.compute-1.amazonaws.com) statusbot |
| 2026-06-23 02:48:18 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 256 seconds) |
| 2026-06-23 02:48:58 +0000 | AlexNoo_ | (~AlexNoo@178.34.150.149) |
| 2026-06-23 02:50:19 +0000 | emilym | (~Thunderbi@user/emilym) (Ping timeout: 245 seconds) |
| 2026-06-23 02:51:09 +0000 | chromoblob | (~chromoblo@user/chromob1ot1c) (Ping timeout: 245 seconds) |
| 2026-06-23 02:51:59 +0000 | AlexNoo | (~AlexNoo@178.34.150.149) (Ping timeout: 245 seconds) |
| 2026-06-23 02:51:59 +0000 | statusbot | (~statusbot@ec2-34-198-122-184.compute-1.amazonaws.com) (Ping timeout: 245 seconds) |
| 2026-06-23 02:55:23 +0000 | yin | (~zero@user/zero) zero |
| 2026-06-23 02:58:49 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn |
| 2026-06-23 03:03:05 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 245 seconds) |
| 2026-06-23 03:03:14 +0000 | mulk | (~mulk@p5b112c49.dip0.t-ipconnect.de) (Ping timeout: 245 seconds) |
| 2026-06-23 03:05:19 +0000 | siraben | (~siraben@user/siraben) (Ping timeout: 245 seconds) |
| 2026-06-23 03:06:13 +0000 | mulk | (~mulk@p5b112c49.dip0.t-ipconnect.de) mulk |
| 2026-06-23 03:06:34 +0000 | czan | (~czan@user/mange) (Ping timeout: 245 seconds) |
| 2026-06-23 03:08:40 +0000 | siraben | (~siraben@user/siraben) siraben |
| 2026-06-23 03:09:04 +0000 | foul_owl | (~kerry@94.156.149.95) (Ping timeout: 245 seconds) |
| 2026-06-23 03:09:08 +0000 | mesaoptimizer | (~user@user/PapuaHardyNet) (Remote host closed the connection) |
| 2026-06-23 03:09:09 +0000 | rekahsoft | (~rekahsoft@70.51.99.119) (Remote host closed the connection) |
| 2026-06-23 03:11:23 +0000 | bitdex | (~bitdex@gateway/tor-sasl/bitdex) bitdex |
| 2026-06-23 03:13:46 +0000 | foul_owl | (~kerry@94.156.149.95) foul_owl |
| 2026-06-23 03:14:11 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn |
| 2026-06-23 03:19:28 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 276 seconds) |
| 2026-06-23 03:29:40 +0000 | merijn | (~merijn@62.45.136.136) merijn |
| 2026-06-23 03:34:08 +0000 | merijn | (~merijn@62.45.136.136) (Ping timeout: 252 seconds) |
| 2026-06-23 03:44:56 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn |
| 2026-06-23 03:49:21 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 246 seconds) |
| 2026-06-23 04:00:18 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn |
| 2026-06-23 04:06:59 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 245 seconds) |
| 2026-06-23 04:12:25 +0000 | machinedgod | (~machinedg@d108-173-95-19.abhsia.telus.net) (Ping timeout: 248 seconds) |
| 2026-06-23 04:18:15 +0000 | haritz | (~hrtz@user/haritz) (Quit: ZNC 1.8.2+deb3.1+deb12u1 - https://znc.in) |
| 2026-06-23 04:18:21 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn |
| 2026-06-23 04:22:53 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 268 seconds) |
| 2026-06-23 04:25:43 +0000 | takuan | (~takuan@d8D86B9E9.access.telenet.be) |
| 2026-06-23 04:29:05 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn |
| 2026-06-23 04:33:45 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 248 seconds) |
| 2026-06-23 04:35:30 +0000 | chexum | (~quassel@gateway/tor-sasl/chexum) (Remote host closed the connection) |
| 2026-06-23 04:35:45 +0000 | chexum | (~quassel@gateway/tor-sasl/chexum) chexum |
| 2026-06-23 04:43:09 +0000 | michalz | (~michalz@185.246.207.221) |
| 2026-06-23 04:44:27 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn |
| 2026-06-23 04:49:34 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 272 seconds) |
| 2026-06-23 04:59:49 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn |
| 2026-06-23 05:00:30 +0000 | xff0x | (~xff0x@fsb6a9491c.tkyc517.ap.nuro.jp) (Ping timeout: 268 seconds) |
| 2026-06-23 05:01:59 +0000 | xff0x | (~xff0x@fsb6a9491c.tkyc517.ap.nuro.jp) |
| 2026-06-23 05:04:15 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 246 seconds) |
| 2026-06-23 05:13:56 +0000 | ft | (~ft@p508db6b1.dip0.t-ipconnect.de) (Quit: leaving) |
| 2026-06-23 05:15:11 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn |
| 2026-06-23 05:19:25 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 243 seconds) |
| 2026-06-23 05:29:01 +0000 | acidjnk | (~acidjnk@p200300d6e700e5277500ddb9aa62921b.dip0.t-ipconnect.de) acidjnk |
| 2026-06-23 05:29:12 +0000 | acidjnk_new3 | (~acidjnk@p200300d6e700e5277500ddb9aa62921b.dip0.t-ipconnect.de) |
| 2026-06-23 05:30:05 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn |
| 2026-06-23 05:34:42 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 248 seconds) |
| 2026-06-23 05:38:50 +0000 | puke | (~puke@user/puke) (Quit: puke) |
| 2026-06-23 05:45:27 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn |
| 2026-06-23 05:51:59 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 245 seconds) |
| 2026-06-23 05:57:57 +0000 | traxex | (traxex@user/traxex) traxex |
| 2026-06-23 06:03:30 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn |
| 2026-06-23 06:07:57 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 246 seconds) |
| 2026-06-23 06:18:49 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn |
| 2026-06-23 06:21:34 +0000 | <gentauro> | lately, I've been given these suggestions in my IDE (emacs) -> `✲ Name: Infinite: ghc-internal/length`. Is there a way to use a `[]` with the built-in logic and not getting those? |
| 2026-06-23 06:23:27 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 261 seconds) |
| 2026-06-23 06:30:21 +0000 | picnoir | (~picnoir@about/aquilenet/vodoo/NinjaTrappeur) (Ping timeout: 246 seconds) |
| 2026-06-23 06:31:04 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn |
| 2026-06-23 06:35:18 +0000 | jle` | (~jle`@23.240.67.73) (Quit: WeeChat 4.8.1) |
| 2026-06-23 06:35:57 +0000 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 272 seconds) |
| 2026-06-23 06:38:22 +0000 | jle` | (~jle`@2603:8001:3b00:11:181d:91a8:37ba:ce0c) jle` |
| 2026-06-23 06:43:22 +0000 | karenw_ | (~karenw@user/karenw) karenw |
| 2026-06-23 06:47:01 +0000 | picnoir | (~picnoir@about/aquilenet/vodoo/NinjaTrappeur) NinjaTrappeur |
| 2026-06-23 06:48:09 +0000 | <pavonia> | What is that message even saying? |
| 2026-06-23 06:52:36 +0000 | <gentauro> | pavonia: I'm just using `length` on a standard list. |
| 2026-06-23 06:52:39 +0000 | Sgeo | (~Sgeo@user/sgeo) (Read error: Connection reset by peer) |
| 2026-06-23 06:53:23 +0000 | <gentauro> | I'm guessing that (which is correct) that calling `length` on an infinete list could be problematic. But, we don't have dependent types in Haskell right? (Idris comes to mind) |
| 2026-06-23 06:55:22 +0000 | <gentauro> | I really appreciate the messages when using `head` as that could make an application crash on empty list (correct way would be doing pattern-matching). But on `length`? What's the alternative to that? |
| 2026-06-23 06:56:36 +0000 | <pavonia> | No idea, tbh. You can't really check whether a list is infinite |
| 2026-06-23 06:58:57 +0000 | dextaa | (~DV@user/dextaa) (Ping timeout: 271 seconds) |
| 2026-06-23 07:00:59 +0000 | <probie> | I think both are equally valid warnings. `head` is a partial function and `length` is not a productive function |
| 2026-06-23 07:01:56 +0000 | merijn | (~merijn@62.45.136.136) merijn |
| 2026-06-23 07:03:17 +0000 | <pavonia> | How would you check the length of a list in a productive way then? |
| 2026-06-23 07:03:54 +0000 | <probie> | `data N = Z | S N`, `length = foldr (const S) Z` |
| 2026-06-23 07:04:04 +0000 | <gentauro> | hmmm, perhaps that now that I have push access to Hackage. Maybe I should invest time to add my `Data.Array.Log{32|64|128|256}` -> https://blog.stermon.org/articles/2020/05/22/haskell-data-array-log256-safe-idiomatic-and-bottom.h… |
| 2026-06-23 07:06:34 +0000 | <gentauro> | `length (A l _) = l` 👍 |
| 2026-06-23 07:06:58 +0000 | merijn | (~merijn@62.45.136.136) (Ping timeout: 276 seconds) |
| 2026-06-23 07:08:57 +0000 | <pavonia> | probie: But isn't that just deferring the problem to other functions? If you want to do comparisons with the length of the list you could run into the same issue |
| 2026-06-23 07:09:20 +0000 | <probie> | You can compare an `Int` against the length of a list |
| 2026-06-23 07:09:59 +0000 | <probie> | What you can't do is compare the length of two lists or treat the length as an Int |
| 2026-06-23 07:10:03 +0000 | chele | (~chele@user/chele) chele |
| 2026-06-23 07:10:13 +0000 | <probie> | (if you still want your code to be total) |
| 2026-06-23 07:11:36 +0000 | <pavonia> | Right. To me this seems like a too restrictive check |
| 2026-06-23 07:14:06 +0000 | <probie> | > let n `compareWithLength` xs = foldr (\x k acc -> if acc <= 0 then LT else k $! (acc - 1)) (\acc -> if acc == 0 then EQ else GT) xs n in (42 `compareWithLength` [1..5], 42 `compareWithLength` [1..42], 42 `compareWithLength` [1..]) |
| 2026-06-23 07:14:07 +0000 | <lambdabot> | (GT,EQ,LT) |
| 2026-06-23 07:15:50 +0000 | <probie> | If you want to make `length` total, just stick `take n` (for some large n) in front of the list you're calling `length` on |
| 2026-06-23 07:16:34 +0000 | tzh | (~tzh@c-76-115-131-146.hsd1.or.comcast.net) (Quit: zzz) |
| 2026-06-23 07:19:30 +0000 | <probie> | To clarify, I think it's a silly rule to raise a warning about, but not that much more silly than the one for `head` |
| 2026-06-23 07:20:11 +0000 | <gentauro> | probie: tbh, `head` shouldn't even exists in the first place … |
| 2026-06-23 07:20:31 +0000 | <gentauro> | pattern-matching SHOULD be the way |
| 2026-06-23 07:21:41 +0000 | <probie> | We're allowed to diverge right, so you're happy with `head xs = case xs of { x:_ -> x; [] -> let x = x in x }` since it's as "total" as `length` |
| 2026-06-23 07:23:32 +0000 | fp1 | (~Thunderbi@130.233.70.229) fp |
| 2026-06-23 07:23:34 +0000 | tromp | (~textual@2001:1c00:340e:2700:f85c:5d3d:452:a65a) |
| 2026-06-23 07:23:43 +0000 | <mauke> | :t length . take maxBound |
| 2026-06-23 07:23:44 +0000 | <lambdabot> | [a] -> Int |
| 2026-06-23 07:24:50 +0000 | merijn | (~merijn@2a02:a420:22df:d034:8458:927c:ac6e:3896) merijn |
| 2026-06-23 07:25:54 +0000 | humasect | (~humasect@dyn-192-249-132-90.nexicom.net) humasect |
| 2026-06-23 07:34:57 +0000 | <gentauro> | mauke: `length . take maxBound` -> `✲ Name: Infinite: ghc-internal/length` |
| 2026-06-23 07:37:18 +0000 | <mauke> | > (length . take maxBound) [0 ..] |
| 2026-06-23 07:37:25 +0000 | <lambdabot> | *Exception: <<timeout>> |
| 2026-06-23 07:37:41 +0000 | <humasect> | ah i miss haskell . |
| 2026-06-23 07:39:51 +0000 | <gentauro> | > (length . take maxBound) [0 :: Int16 ..] |
| 2026-06-23 07:39:52 +0000 | <lambdabot> | 32768 |
| 2026-06-23 07:40:15 +0000 | karenw_ | (~karenw@user/karenw) (Quit: Deep into that darkness peering...) |
| 2026-06-23 07:42:14 +0000 | terrorjack | (~terrorjac@2a01:4f8:271:2d98::2) (Quit: The Lounge - https://thelounge.chat) |