| 2022-12-23 00:01:37 +0000 | ChaiTRex | (~ChaiTRex@user/chaitrex) (Remote host closed the connection) |
| 2022-12-23 00:02:38 +0000 | ChaiTRex | (~ChaiTRex@user/chaitrex) |
| 2022-12-23 00:03:21 +0000 | thegeekinside | (~thegeekin@189.128.148.159) |
| 2022-12-23 00:07:14 +0000 | v0id_ptr | (~adrift@user/ptr-frac7al/x-0038398) |
| 2022-12-23 00:09:24 +0000 | jinsun | (~jinsun@user/jinsun) (Ping timeout: 255 seconds) |
| 2022-12-23 00:10:11 +0000 | Midjak | (~Midjak@82.66.147.146) (Quit: This computer has gone to sleep) |
| 2022-12-23 00:17:02 +0000 | Tuplanolla | (~Tuplanoll@91-159-68-152.elisa-laajakaista.fi) (Quit: Leaving.) |
| 2022-12-23 00:25:32 +0000 | eggplantade | (~Eggplanta@2600:1700:38c5:d800:1dcc:166b:1177:c3e0) |
| 2022-12-23 00:30:05 +0000 | eggplantade | (~Eggplanta@2600:1700:38c5:d800:1dcc:166b:1177:c3e0) (Ping timeout: 255 seconds) |
| 2022-12-23 00:48:16 +0000 | wroathe | (~wroathe@207-153-38-140.fttp.usinternet.com) |
| 2022-12-23 00:48:16 +0000 | wroathe | (~wroathe@207-153-38-140.fttp.usinternet.com) (Changing host) |
| 2022-12-23 00:48:16 +0000 | wroathe | (~wroathe@user/wroathe) |
| 2022-12-23 00:49:06 +0000 | fizbin | (~fizbin@user/fizbin) |
| 2022-12-23 00:54:33 +0000 | gurkenglas | (~gurkengla@p548ac72e.dip0.t-ipconnect.de) |
| 2022-12-23 01:00:05 +0000 | [itchyjunk] | (~itchyjunk@user/itchyjunk/x-7353470) |
| 2022-12-23 01:05:00 +0000 | slack1256 | (~slack1256@186.11.29.60) |
| 2022-12-23 01:05:11 +0000 | thongpv87 | (~thongpv87@2402:9d80:3c4:ae3b:4b13:46b3:cad7:5da8) |
| 2022-12-23 01:09:34 +0000 | jargon | (~jargon@174-22-192-24.phnx.qwest.net) (Remote host closed the connection) |
| 2022-12-23 01:10:48 +0000 | albet70 | (~xxx@2400:8902::f03c:92ff:fe60:98d8) (Remote host closed the connection) |
| 2022-12-23 01:12:18 +0000 | elevenkb | (~elevenkb@105.224.37.128) (Ping timeout: 260 seconds) |
| 2022-12-23 01:16:29 +0000 | wroathe | (~wroathe@user/wroathe) (Ping timeout: 252 seconds) |
| 2022-12-23 01:16:55 +0000 | albet70 | (~xxx@2400:8902::f03c:92ff:fe60:98d8) |
| 2022-12-23 01:17:29 +0000 | gurkenglas | (~gurkengla@p548ac72e.dip0.t-ipconnect.de) (Ping timeout: 268 seconds) |
| 2022-12-23 01:18:29 +0000 | bilegeek | (~bilegeek@2600:1008:b057:74f5:d377:f773:aec0:435a) |
| 2022-12-23 01:22:50 +0000 | bitdex | (~bitdex@gateway/tor-sasl/bitdex) (Ping timeout: 255 seconds) |
| 2022-12-23 01:26:41 +0000 | bitdex | (~bitdex@gateway/tor-sasl/bitdex) |
| 2022-12-23 01:35:33 +0000 | bilegeek | (~bilegeek@2600:1008:b057:74f5:d377:f773:aec0:435a) (Quit: Leaving) |
| 2022-12-23 01:35:34 +0000 | finsternis | (~X@23.226.237.192) (Read error: Connection reset by peer) |
| 2022-12-23 01:37:53 +0000 | xff0x | (~xff0x@ai071162.d.east.v6connect.net) (Ping timeout: 246 seconds) |
| 2022-12-23 01:47:20 +0000 | freeside | (~mengwong@103.252.202.159) (Ping timeout: 246 seconds) |
| 2022-12-23 01:52:43 +0000 | thongpv87 | (~thongpv87@2402:9d80:3c4:ae3b:4b13:46b3:cad7:5da8) (Ping timeout: 248 seconds) |
| 2022-12-23 01:56:34 +0000 | thongpv87 | (~thongpv87@123.31.184.254) |
| 2022-12-23 01:57:01 +0000 | ddellacosta | (~ddellacos@89.45.224.51) |
| 2022-12-23 01:58:38 +0000 | freeside | (~mengwong@103.252.202.159) |
| 2022-12-23 02:06:00 +0000 | <ddellacosta> | how do I decode a sum type from Dhall into Haskell, like `data Foo = A | B | C`? I don't know if I should be using `constructor` with some kind of decoder argument but it's not obvious what that would be https://hackage.haskell.org/package/dhall-1.31.1/docs/Dhall.html#t:UnionDecoder |
| 2022-12-23 02:22:39 +0000 | xff0x | (~xff0x@125x103x176x34.ap125.ftth.ucom.ne.jp) |
| 2022-12-23 02:26:09 +0000 | fizbin | (~fizbin@user/fizbin) (Ping timeout: 252 seconds) |
| 2022-12-23 02:27:06 +0000 | troydm | (~troydm@host-176-37-124-197.b025.la.net.ua) (Ping timeout: 272 seconds) |
| 2022-12-23 02:27:09 +0000 | eggplantade | (~Eggplanta@2600:1700:38c5:d800:1dcc:166b:1177:c3e0) |
| 2022-12-23 02:30:36 +0000 | motherfsck | (~motherfsc@user/motherfsck) |
| 2022-12-23 02:31:39 +0000 | eggplantade | (~Eggplanta@2600:1700:38c5:d800:1dcc:166b:1177:c3e0) (Ping timeout: 252 seconds) |
| 2022-12-23 02:32:58 +0000 | travv0 | (sid293381@user/travv0) |
| 2022-12-23 02:38:38 +0000 | razetime | (~quassel@49.207.230.181) |
| 2022-12-23 02:40:56 +0000 | cheater | (~Username@user/cheater) (Quit: Going offline, see ya! (www.adiirc.com)) |
| 2022-12-23 02:41:32 +0000 | cheater | (~Username@user/cheater) |
| 2022-12-23 02:52:11 +0000 | motherfsck | (~motherfsc@user/motherfsck) (Ping timeout: 252 seconds) |
| 2022-12-23 03:05:54 +0000 | morb | (~morb@pool-72-80-94-112.nycmny.fios.verizon.net) |
| 2022-12-23 03:13:02 +0000 | Kaiepi | (~Kaiepi@108.175.84.104) (Ping timeout: 246 seconds) |
| 2022-12-23 03:17:23 +0000 | thongpv | (~thongpv87@2001:ee0:54a8:aee0:7c8f:cdb6:1db0:5cd9) |
| 2022-12-23 03:18:14 +0000 | Inst | (~Inst@2601:6c4:4081:54f0:5c02:2b13:b462:4536) (Read error: Connection reset by peer) |
| 2022-12-23 03:19:22 +0000 | eggplantade | (~Eggplanta@2600:1700:38c5:d800:1dcc:166b:1177:c3e0) |
| 2022-12-23 03:19:40 +0000 | thongpv87 | (~thongpv87@123.31.184.254) (Ping timeout: 272 seconds) |
| 2022-12-23 03:27:36 +0000 | td_ | (~td@83.135.9.52) (Ping timeout: 268 seconds) |
| 2022-12-23 03:28:49 +0000 | td_ | (~td@83.135.9.52) |
| 2022-12-23 03:38:42 +0000 | bjourne | (~bjorn@94.191.153.229) (Read error: Connection reset by peer) |
| 2022-12-23 03:44:56 +0000 | terrorjack | (~terrorjac@2a01:4f8:1c1e:509a::1) (Ping timeout: 246 seconds) |
| 2022-12-23 03:50:20 +0000 | terrorjack | (~terrorjac@2a01:4f8:1c1e:509a::1) |
| 2022-12-23 03:52:26 +0000 | <sm> | would anyone have an example of using megaparsec's dbg ? I cannot figure it out |
| 2022-12-23 03:54:31 +0000 | <sm> | seems simplel enough >:( |
| 2022-12-23 03:56:00 +0000 | <sm> | oh well, moving on |
| 2022-12-23 04:03:22 +0000 | freeside | (~mengwong@103.252.202.159) (Ping timeout: 268 seconds) |
| 2022-12-23 04:04:12 +0000 | <sm> | I get the impression dbg in megaparsec 9.2.2 works only for ParsecT parsers. Mine have StateT on top of that. And dbg in megaparsec 9.3 might be more flexible. |
| 2022-12-23 04:09:04 +0000 | ddellacosta | (~ddellacos@89.45.224.51) (Ping timeout: 272 seconds) |
| 2022-12-23 04:09:10 +0000 | <sm> | how does any of this code work when I understand so little.. |
| 2022-12-23 04:09:30 +0000 | mbuf | (~Shakthi@49.204.130.4) |
| 2022-12-23 04:12:23 +0000 | <sm> | yes! dbg from megaparsec 9.3 just worked. \o/ |
| 2022-12-23 04:15:27 +0000 | machinedgod | (~machinedg@d198-53-218-113.abhsia.telus.net) (Ping timeout: 260 seconds) |
| 2022-12-23 04:16:18 +0000 | <iqubic> | What is dbg? |
| 2022-12-23 04:16:53 +0000 | <iqubic> | Oh, it's like traceShowId, but for Megaparec Parsers |
| 2022-12-23 04:17:01 +0000 | <iqubic> | :t traceShowId |
| 2022-12-23 04:17:02 +0000 | <lambdabot> | error: Variable not in scope: traceShowId |
| 2022-12-23 04:17:20 +0000 | freeside | (~mengwong@103.252.202.159) |
| 2022-12-23 04:17:42 +0000 | <iqubic> | Wait... actually it's just trace |
| 2022-12-23 04:17:46 +0000 | <iqubic> | :t trace |
| 2022-12-23 04:17:47 +0000 | <lambdabot> | error: Variable not in scope: trace |
| 2022-12-23 04:18:02 +0000 | morb | (~morb@pool-72-80-94-112.nycmny.fios.verizon.net) (Remote host closed the connection) |
| 2022-12-23 04:18:02 +0000 | <iqubic> | @import Debug.Trace |
| 2022-12-23 04:18:02 +0000 | <lambdabot> | Unknown command, try @list |
| 2022-12-23 04:18:20 +0000 | <sm> | it gives output like this. Better than the home-grown one I used to use. Great!... (full message at <https://libera.ems.host/_matrix/media/v3/download/libera.chat/2a034e4c39f94bb40df5277422581bddd5d2…>) |
| 2022-12-23 04:18:40 +0000 | <iqubic> | sm: I think dbg is sorta like trace from Debug.Trace: https://hackage.haskell.org/package/base-4.17.0.0/docs/Debug-Trace.html#v:trace |
| 2022-12-23 04:19:12 +0000 | <iqubic> | Oh, that's even better |
| 2022-12-23 04:19:16 +0000 | <sm> | it uses trace, but shows useful parser-related info without having to figure that out yourself. A must have for debugging parsers |
| 2022-12-23 04:19:28 +0000 | wroathe | (~wroathe@207-153-38-140.fttp.usinternet.com) |
| 2022-12-23 04:19:28 +0000 | wroathe | (~wroathe@207-153-38-140.fttp.usinternet.com) (Changing host) |
| 2022-12-23 04:19:28 +0000 | wroathe | (~wroathe@user/wroathe) |
| 2022-12-23 04:20:32 +0000 | <iqubic> | I've not seen a need to use it myself. |
| 2022-12-23 04:21:18 +0000 | <iqubic> | I tend to just use errorBundlePretty to get Megaparsec errors printed in a nice way. |
| 2022-12-23 04:22:19 +0000 | <iqubic> | https://hackage.haskell.org/package/megaparsec-9.3.0/docs/Text-Megaparsec.html#v:runParser |
| 2022-12-23 04:23:11 +0000 | <iqubic> | That gives me either an complex error type, or something of type a. I then use errorBundlePretty to pretty print the error message. |
| 2022-12-23 04:24:13 +0000 | <sm> | sometimes you need to see intermediate state, not just the final error |
| 2022-12-23 04:28:22 +0000 | <iqubic> | I've never needed to see the intermediate state. But I can imagine with more complicated parsers that can be useful. |
| 2022-12-23 04:32:21 +0000 | beefbambi | (~beefbambi@183.82.204.74) (Ping timeout: 268 seconds) |
| 2022-12-23 04:32:36 +0000 | Sciencentistguy5 | (~sciencent@hacksoc/ordinary-member) |
| 2022-12-23 04:34:13 +0000 | Unicorn_Princess | (~Unicorn_P@user/Unicorn-Princess/x-3540542) (Remote host closed the connection) |
| 2022-12-23 04:34:29 +0000 | Sciencentistguy | (~sciencent@hacksoc/ordinary-member) (Ping timeout: 260 seconds) |
| 2022-12-23 04:34:29 +0000 | Sciencentistguy5 | Sciencentistguy |
| 2022-12-23 04:35:19 +0000 | ezzieyguywuf | (~Unknown@user/ezzieyguywuf) (Remote host closed the connection) |
| 2022-12-23 04:37:10 +0000 | beefbambi | (~beefbambi@2401:4900:230d:f57c:538c:d7cc:50c0:e377) |
| 2022-12-23 04:44:56 +0000 | ezzieyguywuf | (~Unknown@user/ezzieyguywuf) |
| 2022-12-23 04:47:34 +0000 | quazimodo | (~quazimodo@122-199-39-221.ip4.superloop.com) |
| 2022-12-23 04:56:01 +0000 | <sm> | yeah it just saved me here where I couldn't figure out what was happening. dbg + emacs coloured highlighting of key parts ftw |
| 2022-12-23 04:57:19 +0000 | sm | uploaded an image: (96KiB) < https://libera.ems.host/_matrix/media/v3/download/matrix.org/SDBAoBibDYbYCoyZnyVfjvXp/Screen%20Sho… > |
| 2022-12-23 04:58:00 +0000 | <sm> | that second last MATCH was consuming a ( needed by the next parser, until I added a try |
| 2022-12-23 05:03:15 +0000 | use-value | (~Thunderbi@2a00:23c6:8a03:2f01:75c2:a71f:beaa:29bf) (Quit: use-value) |
| 2022-12-23 05:11:42 +0000 | L29Ah | (~L29Ah@wikipedia/L29Ah) |
| 2022-12-23 05:17:35 +0000 | thegeekinside | (~thegeekin@189.128.148.159) (Ping timeout: 264 seconds) |
| 2022-12-23 05:24:58 +0000 | [itchyjunk] | (~itchyjunk@user/itchyjunk/x-7353470) (Remote host closed the connection) |
| 2022-12-23 05:25:10 +0000 | mbuf | (~Shakthi@49.204.130.4) (Remote host closed the connection) |
| 2022-12-23 05:25:36 +0000 | mbuf | (~Shakthi@49.204.130.4) |
| 2022-12-23 05:33:09 +0000 | Kaiepi | (~Kaiepi@108.175.84.104) |
| 2022-12-23 05:57:44 +0000 | poscat | (~poscat@2408:8206:4823:14c6:2d43:62ac:d2b8:b823) (Quit: Bye) |
| 2022-12-23 05:58:03 +0000 | poscat | (~poscat@114.245.108.192) |
| 2022-12-23 06:05:09 +0000 | L29Ah | (~L29Ah@wikipedia/L29Ah) () |
| 2022-12-23 06:13:44 +0000 | trev | (~trev@user/trev) |
| 2022-12-23 06:27:08 +0000 | freeside | (~mengwong@103.252.202.159) (Ping timeout: 272 seconds) |
| 2022-12-23 06:32:41 +0000 | johnw | (~johnw@2600:1700:cf00:db0:3017:1dda:5aaf:2264) (Quit: ZNC - http://znc.in) |
| 2022-12-23 06:33:27 +0000 | takuan | (~takuan@178-116-218-225.access.telenet.be) |
| 2022-12-23 06:33:35 +0000 | <iqubic> | @pl \f -> f x y |
| 2022-12-23 06:33:35 +0000 | <lambdabot> | flip ($ x) y |
| 2022-12-23 06:33:39 +0000 | <iqubic> | Eww... |
| 2022-12-23 06:37:04 +0000 | <c_wraith> | that makes sense. And I'd never use it |
| 2022-12-23 06:41:03 +0000 | freeside | (~mengwong@103.252.202.159) |
| 2022-12-23 06:42:34 +0000 | shriekingnoise | (~shrieking@186.137.167.202) (Quit: Quit) |
| 2022-12-23 06:45:42 +0000 | <int-e> | ($ y) . ($ x) would be more systematic |
| 2022-12-23 06:47:27 +0000 | <int-e> | But I'd use (\f -> f x y) too |
| 2022-12-23 06:48:20 +0000 | freeside | (~mengwong@103.252.202.159) (Ping timeout: 246 seconds) |
| 2022-12-23 06:51:06 +0000 | jinsun | (~jinsun@user/jinsun) |
| 2022-12-23 06:59:25 +0000 | cheater_ | (~Username@user/cheater) |
| 2022-12-23 07:01:29 +0000 | cheater__ | (~Username@user/cheater) |
| 2022-12-23 07:01:35 +0000 | cheater | (~Username@user/cheater) (Ping timeout: 268 seconds) |
| 2022-12-23 07:01:44 +0000 | cheater__ | cheater |
| 2022-12-23 07:03:28 +0000 | ezzieyguywuf | (~Unknown@user/ezzieyguywuf) (Read error: Connection reset by peer) |
| 2022-12-23 07:03:44 +0000 | ezzieyguywuf | (~Unknown@user/ezzieyguywuf) |
| 2022-12-23 07:05:08 +0000 | cheater_ | (~Username@user/cheater) (Ping timeout: 272 seconds) |
| 2022-12-23 07:07:39 +0000 | <iqubic> | int-e: The code I just wrote contains a line of the form "map (\f -> f x y) xs" |
| 2022-12-23 07:08:55 +0000 | <int-e> | iqubic: mine has `... >>= \f -> f x y` |
| 2022-12-23 07:09:18 +0000 | Inst | (~Inst@2601:6c4:4081:54f0:c13a:1faa:a088:6fcb) |
| 2022-12-23 07:09:23 +0000 | <iqubic> | Isn't that essentially the same thing? |
| 2022-12-23 07:09:23 +0000 | <Inst> | do I understand hylomorphisms? |
| 2022-12-23 07:09:27 +0000 | <Inst> | oh, sorry, i'll wait |
| 2022-12-23 07:09:45 +0000 | <iqubic> | Inst: Please ask your questions now. No need to wait. |
| 2022-12-23 07:09:51 +0000 | <int-e> | iqubic: yes, that's the point. (but >>= instead of map is a tiny difference) |
| 2022-12-23 07:10:16 +0000 | <iqubic> | Yeah, (>>=) = concatMap for lists. |
| 2022-12-23 07:10:23 +0000 | <Inst> | I'm addicted to accumulating parameters, not sure if others are aware of that |
| 2022-12-23 07:10:44 +0000 | <int-e> | iqubic: The real point was, I think I know what your code is for, given the timing, mainly. |
| 2022-12-23 07:11:01 +0000 | <Inst> | shouldn't it be flip (>>=) => concatMap? |
| 2022-12-23 07:11:02 +0000 | <iqubic> | My code is for Advent of Code, yes. |
| 2022-12-23 07:11:18 +0000 | <int-e> | Inst: yep |
| 2022-12-23 07:11:31 +0000 | <Inst> | but, i'm abotu to benchmark it properly via criterion |
| 2022-12-23 07:11:42 +0000 | <int-e> | I actually had to go back and check that I didn't use a list comprehension :-P |
| 2022-12-23 07:11:46 +0000 | <Inst> | it seems that hylomorphisms are faster than accumulating parameters? |
| 2022-12-23 07:12:03 +0000 | <iqubic> | int-e: What you might not know is that I actually have a value of type [Set (Int, Int) -> (Int, Int) -> Maybe Int] |
| 2022-12-23 07:12:24 +0000 | <iqubic> | And no, it's not the trivial empty listt. |
| 2022-12-23 07:12:35 +0000 | <c_wraith> | Inst: they're just not even the same thing. If you're using both to solve a problem, you're using different algorithms. That's the difference you're measuring. |
| 2022-12-23 07:12:50 +0000 | <Inst> | are they not? |
| 2022-12-23 07:12:56 +0000 | <Inst> | https://reasonablypolymorphic.com/blog/recursion-schemes/ |
| 2022-12-23 07:13:25 +0000 | <Inst> | i rewrote using foldl', got a 150% speed-up on GHCI |
| 2022-12-23 07:13:38 +0000 | <c_wraith> | well, don't benchmark anything in ghci |
| 2022-12-23 07:14:16 +0000 | <iqubic> | Yeah. Compiling the code allows you to get better benchmark results. |
| 2022-12-23 07:16:16 +0000 | <Inst> | my hylo is about 1% faster than my accumulating parameter version in GHCI, but then again, this is crap, because I'm fixing to int |
| 2022-12-23 07:17:19 +0000 | <iqubic> | It's also a test being done in GHCI, which will inherently give worse results |
| 2022-12-23 07:17:31 +0000 | freeside | (~mengwong@103.252.202.159) |
| 2022-12-23 07:18:04 +0000 | <Inst> | erm, not GHCI, criterion |
| 2022-12-23 07:18:11 +0000 | <Inst> | criterion finally compiled |
| 2022-12-23 07:19:09 +0000 | <Inst> | huh, forget it |
| 2022-12-23 07:19:23 +0000 | <Inst> | when i swap out to integer, the fastest factorial i have is the iterate version |
| 2022-12-23 07:19:58 +0000 | <Inst> | i'm just looking for a general purpose replacement for accumulating parameter code i use; I know when foldl' / foldr can be used for other simple recursions |
| 2022-12-23 07:22:08 +0000 | freeside | (~mengwong@103.252.202.159) (Ping timeout: 260 seconds) |
| 2022-12-23 07:22:33 +0000 | wroathe | (~wroathe@user/wroathe) (Ping timeout: 268 seconds) |
| 2022-12-23 07:25:45 +0000 | <Inst> | about 15% faster, but iterate wins out if i change types from int to integer, i wonder why |
| 2022-12-23 07:26:56 +0000 | freeside | (~mengwong@103.252.202.159) |
| 2022-12-23 07:28:54 +0000 | <int-e> | iqubic: same here :) |
| 2022-12-23 07:29:48 +0000 | <int-e> | iqubic: actually, no. the arguments are the same; the result is [(Int,Int)] |
| 2022-12-23 07:31:10 +0000 | <iqubic> | Also, technically it's a V2 Int, instead of an (Int, Int), but it's mostly the same here. |
| 2022-12-23 07:31:28 +0000 | <iqubic> | https://hackage.haskell.org/package/linear-1.22/docs/Linear-V2.html |
| 2022-12-23 07:32:06 +0000 | <iqubic> | V2 has some helpful numerical instances like (Num a) => Num (V2 a) which do pairwise operations |
| 2022-12-23 07:32:52 +0000 | <int-e> | Makes sense. |
| 2022-12-23 07:34:43 +0000 | tromp | (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) |
| 2022-12-23 07:40:16 +0000 | <Inst> | c_wraith: why aren't they the same thing? shouldn't unfoldr / foldl' result in code that's equivalent to a for loop via list fusion? |
| 2022-12-23 07:40:33 +0000 | <Inst> | and shouldn't accumulating parameter, via TCO, result in a for loop as well? |
| 2022-12-23 07:41:25 +0000 | Sgeo | (~Sgeo@user/sgeo) (Read error: Connection reset by peer) |
| 2022-12-23 07:42:28 +0000 | Invariance | (~Invarianc@ppp1093.dsl.ontario.net) |
| 2022-12-23 07:45:31 +0000 | Invariance | (~Invarianc@ppp1093.dsl.ontario.net) (Client Quit) |
| 2022-12-23 07:58:20 +0000 | MajorBiscuit | (~MajorBisc@31-23-159.netrun.cytanet.com.cy) |
| 2022-12-23 08:00:18 +0000 | <int-e> | Inst: ghci essentially doesn't optimize... there's no fusion (since that's usually based on rewrite rules and heavy inlining). TCO should still work most of the time. |
| 2022-12-23 08:00:28 +0000 | <Inst> | i'm doing it via criterion now |
| 2022-12-23 08:00:47 +0000 | <Inst> | and i'm pissed, because i feel like, i must have screwed up somewhere, but the iterate solution is massively beating everything else |
| 2022-12-23 08:01:23 +0000 | <Inst> | ugh, sigh |
| 2022-12-23 08:01:47 +0000 | <Inst> | i want to quit my accumulating parameter habit, iterate is almost worse, because iterate uses a partial function to make it work |
| 2022-12-23 08:02:48 +0000 | <Inst> | my goto when i don't know how to solve anything is to get an accumulating parameter, which is basically just getting a for loop, and this is in haskell |
| 2022-12-23 08:03:01 +0000 | <int-e> | Well iterate is usually quite good, thanks to build/foldr fusion. |
| 2022-12-23 08:03:26 +0000 | <Inst> | iterate is technically a hylomorphism, isn't it? |
| 2022-12-23 08:04:11 +0000 | <Inst> | it's a very specific fold; i think, but tbh it should be possible to implement (!!) via foldr, no? |
| 2022-12-23 08:05:01 +0000 | <int-e> | It's a specific unfold, so an anamorphism. You need a subsequent fold (catamorphism) to make a hylomorphism. |
| 2022-12-23 08:05:13 +0000 | <Inst> | and (!!) counts? |
| 2022-12-23 08:06:03 +0000 | <Inst> | i guess when i say iterate, i mean the (iterate (nextIteration) seed !!) pattern |
| 2022-12-23 08:06:56 +0000 | <int-e> | > foldr (\x f n -> if n == 0 then x else f (n-1)) undefined "abcdef" 3 |
| 2022-12-23 08:06:58 +0000 | <lambdabot> | 'd' |
| 2022-12-23 08:07:29 +0000 | thongpv87 | (~thongpv87@2402:9d80:3c4:ae3b:5372:83e0:6f97:a164) |
| 2022-12-23 08:08:08 +0000 | <int-e> | Oh that's essentially the implementation in GHC.List. |
| 2022-12-23 08:09:34 +0000 | quazimodo | (~quazimodo@122-199-39-221.ip4.superloop.com) (Remote host closed the connection) |
| 2022-12-23 08:09:36 +0000 | <int-e> | So anyway, yes, it's a `foldr`. |
| 2022-12-23 08:10:19 +0000 | thongpv | (~thongpv87@2001:ee0:54a8:aee0:7c8f:cdb6:1db0:5cd9) (Ping timeout: 248 seconds) |
| 2022-12-23 08:10:28 +0000 | <Inst> | at least i have the fig leaf of a recursion scheme over iterate |
| 2022-12-23 08:11:05 +0000 | <int-e> | So build/foldr fusion will turn `iterate f x !! g` into code that uses an accumulator; no point in doing that manually. |
| 2022-12-23 08:11:53 +0000 | eggplantade | (~Eggplanta@2600:1700:38c5:d800:1dcc:166b:1177:c3e0) (Remote host closed the connection) |
| 2022-12-23 08:12:41 +0000 | <Inst> | i think, when i'm benchmarking under criterion, if i let float my accum parameter, it's still the fastest of all my facs |
| 2022-12-23 08:12:44 +0000 | <Inst> | i can send you the pastebin |
| 2022-12-23 08:13:23 +0000 | <Inst> | https://pastebin.com/UKHpt5Y0 |
| 2022-12-23 08:14:41 +0000 | <Inst> | when it's all int, accumulating parameter benches best, without the let float, hylomorphism benches better, when it's in integer, only thing that's actually fast is the iterate version |
| 2022-12-23 08:17:01 +0000 | <int-e> | try this silly thing... http://paste.debian.net/1265028/ |
| 2022-12-23 08:17:37 +0000 | <int-e> | Unless your arguments are tiny, with Integer you're spending most of the time multiplying numbers. |
| 2022-12-23 08:17:42 +0000 | <int-e> | arg, I messed up |
| 2022-12-23 08:18:05 +0000 | <int-e> | http://paste.debian.net/1265029/ is what I wanted |
| 2022-12-23 08:18:38 +0000 | <int-e> | (this is still not the best way to compute large factorials... for that, you should count prime factors) |
| 2022-12-23 08:19:45 +0000 | <Inst> | tbh, it's just benchmarking to get an idea of how algorithms and approaches behave in Haskell |
| 2022-12-23 08:19:57 +0000 | <int-e> | Inst: and on the non-silly front, have you tried product [1..n] ? |
| 2022-12-23 08:19:59 +0000 | <Inst> | i probably should go into some willy nilly phase wherein i want to foldl' or foldr everything |
| 2022-12-23 08:21:18 +0000 | <Inst> | benchmarking that now |
| 2022-12-23 08:22:05 +0000 | Tuplanolla | (~Tuplanoll@91-159-68-152.elisa-laajakaista.fi) |
| 2022-12-23 08:22:32 +0000 | <int-e> | anyway, I wouldn't be able to say without benchmarking whether fac, fac''', or fac'''' are significantly different; they all have a chance to produce essentially the same accumulating code. Though fac''' may end up maintaining two counters so that may suffer. |
| 2022-12-23 08:23:12 +0000 | <int-e> | fac' and fac'' should be inferior. |
| 2022-12-23 08:23:26 +0000 | <int-e> | (and about equal to each other) |
| 2022-12-23 08:24:15 +0000 | <Inst> | this for me, at least, is the consummate weirdness |
| 2022-12-23 08:24:21 +0000 | <int-e> | (because after inlining `fix` and desugaring the case analysis of `fac'`, they're really the same thing) |
| 2022-12-23 08:24:23 +0000 | <Inst> | https://media.discordapp.net/attachments/968989726633779215/1055762707296559135/image.png |
| 2022-12-23 08:25:04 +0000 | <Inst> | ,bgroup "someCrap" [bench "iterate" $ nf fac''' 100_000] |
| 2022-12-23 08:27:23 +0000 | johnw | (~johnw@76-234-69-149.lightspeed.frokca.sbcglobal.net) |
| 2022-12-23 08:28:27 +0000 | cheater_ | (~Username@user/cheater) |
| 2022-12-23 08:28:28 +0000 | <int-e> | Is that for Integer? I think it's more meaningful to do all this with `Int` rather than with code that deals with 100ks of digits. |
| 2022-12-23 08:30:10 +0000 | <int-e> | (There'll be *a lot* of garbage and it's quite conceivable that different versions of the code spend different proportions of their time in the garbage collector.) |
| 2022-12-23 08:30:43 +0000 | cheater | (~Username@user/cheater) (Ping timeout: 260 seconds) |
| 2022-12-23 08:30:52 +0000 | cheater_ | cheater |
| 2022-12-23 08:33:52 +0000 | Xeroine | (~Xeroine@user/xeroine) (Quit: ZNC 1.8.2+deb2+b1 - https://znc.in) |
| 2022-12-23 08:34:54 +0000 | Xeroine | (~Xeroine@user/xeroine) |
| 2022-12-23 08:35:55 +0000 | thongpv87 | (~thongpv87@2402:9d80:3c4:ae3b:5372:83e0:6f97:a164) (Ping timeout: 248 seconds) |
| 2022-12-23 08:38:16 +0000 | Midjak | (~Midjak@82.66.147.146) |
| 2022-12-23 08:43:32 +0000 | <Inst> | yeah, that's for integer |
| 2022-12-23 08:44:39 +0000 | <Inst> | with int, you have the problem that you start getting overflows too quickly, though |
| 2022-12-23 08:44:48 +0000 | <Inst> | only 30 iirc, gets you an overflow |
| 2022-12-23 08:44:50 +0000 | thongpv87 | (~thongpv87@2402:9d80:346:901d:874b:931b:303e:63a1) |
| 2022-12-23 08:44:54 +0000 | <int-e> | Doesn't matter; the compiler doesn't know. |
| 2022-12-23 08:45:23 +0000 | <int-e> | You could compute triangular numbers instead. |
| 2022-12-23 08:45:42 +0000 | <int-e> | > product [1..128] :: Int |
| 2022-12-23 08:45:43 +0000 | <lambdabot> | 0 |
| 2022-12-23 08:46:37 +0000 | <Inst> | 20 is the max you get before you start overflowing |
| 2022-12-23 08:47:00 +0000 | <int-e> | you still get meaningful performance measurements though |
| 2022-12-23 08:47:10 +0000 | <Inst> | ummm, n^2 - 1? |
| 2022-12-23 08:47:21 +0000 | <Inst> | wait, that's not the pattern |
| 2022-12-23 08:47:27 +0000 | <Inst> | (n-1)^2 + 1 |
| 2022-12-23 08:47:41 +0000 | <Inst> | welp, still wrong |
| 2022-12-23 08:47:49 +0000 | <int-e> | If you actually want to compute factorials for n > 200, none of those implementations is |
| 2022-12-23 08:47:57 +0000 | <Inst> | (n^2 + n) / 2 |
| 2022-12-23 08:47:58 +0000 | <int-e> | > sum [1..100] |
| 2022-12-23 08:47:59 +0000 | <lambdabot> | 5050 |
| 2022-12-23 08:48:11 +0000 | <int-e> | > product [1..100] |
| 2022-12-23 08:48:12 +0000 | <lambdabot> | 9332621544394415268169923885626670049071596826438162146859296389521759999322... |
| 2022-12-23 08:48:20 +0000 | <Jadesheit[m]> | > zip [1..] [product [1..n] :: Int | n <- [1..100]] |
| 2022-12-23 08:48:21 +0000 | <lambdabot> | [(1,1),(2,2),(3,6),(4,24),(5,120),(6,720),(7,5040),(8,40320),(9,362880),(10,... |
| 2022-12-23 08:48:27 +0000 | <int-e> | it's the same recursive pattern with addition instead of multiplication |
| 2022-12-23 08:48:57 +0000 | <int-e> | > scanl (*) 1 [1..] !! 10 |
| 2022-12-23 08:48:59 +0000 | <lambdabot> | 3628800 |
| 2022-12-23 08:49:09 +0000 | thongpv87 | (~thongpv87@2402:9d80:346:901d:874b:931b:303e:63a1) (Ping timeout: 256 seconds) |
| 2022-12-23 08:51:18 +0000 | <Jadesheit[m]> | > filter (== 0) $ zip [1..] (scanl (*) 1 [1..100]) |
| 2022-12-23 08:51:20 +0000 | <lambdabot> | error: |
| 2022-12-23 08:51:20 +0000 | <lambdabot> | • No instance for (Num (Integer, Integer)) |
| 2022-12-23 08:51:20 +0000 | <lambdabot> | arising from a use of ‘e_10111100’ |
| 2022-12-23 08:51:42 +0000 | <int-e> | Inst: http://paste.debian.net/1265029/ is a decent (but not great) implementation of factorials for integers... it'll be much faster for 100,000! than what you have. |
| 2022-12-23 08:51:50 +0000 | <Jadesheit[m]> | * 1 [1..100] :: [Int]) |
| 2022-12-23 08:51:56 +0000 | <int-e> | (same paste as earlier) |
| 2022-12-23 08:53:12 +0000 | thongpv87 | (~thongpv87@2402:9d80:346:901d:126:7968:86ee:f4cf) |
| 2022-12-23 08:54:47 +0000 | <Inst> | testing now |
| 2022-12-23 08:56:30 +0000 | machinedgod | (~machinedg@d198-53-218-113.abhsia.telus.net) |
| 2022-12-23 08:57:05 +0000 | <Inst> | see, i get the feeling the iterate is broken |
| 2022-12-23 08:57:21 +0000 | <Inst> | it's still faster than your version, which, admittedly, is MUUUCH faster than all the other versions |
| 2022-12-23 08:57:38 +0000 | <Inst> | 45.66 ms vs 1 second vs 1 ms |
| 2022-12-23 08:57:52 +0000 | freeside | (~mengwong@103.252.202.159) (Ping timeout: 272 seconds) |
| 2022-12-23 08:59:20 +0000 | <Jadesheit[m]> | Where's the git repo for lambdabot: |
| 2022-12-23 09:00:03 +0000 | Player-205[m] | (~sashaserp@2001:470:69fc:105::2:30b8) (Quit: You have been kicked for being idle) |
| 2022-12-23 09:00:04 +0000 | AdamConner-Sax[m | (~adamcsmat@2001:470:69fc:105::1:e2c8) (Quit: You have been kicked for being idle) |
| 2022-12-23 09:00:08 +0000 | yl53[m] | (~yl53matri@2001:470:69fc:105::85b) (Quit: You have been kicked for being idle) |
| 2022-12-23 09:00:36 +0000 | freeside | (~mengwong@103.252.202.159) |
| 2022-12-23 09:00:52 +0000 | <mauke> | @where lambdabot |
| 2022-12-23 09:00:52 +0000 | <lambdabot> | http://haskell.org/haskellwiki/Lambdabot |
| 2022-12-23 09:01:21 +0000 | vpan | (~0@212.117.1.172) |
| 2022-12-23 09:02:28 +0000 | <mauke> | @where+ lambdabot https://hackage.haskell.org/package/lambdabot https://github.com/lambdabot/lambdabot |
| 2022-12-23 09:02:28 +0000 | <lambdabot> | I will remember. |
| 2022-12-23 09:02:29 +0000 | <Jadesheit[m]> | thank you |
| 2022-12-23 09:02:36 +0000 | <mauke> | the wiki is out of date |
| 2022-12-23 09:05:51 +0000 | <Inst> | in general, though, is an imperative algorithm just a hylomorphism? |
| 2022-12-23 09:05:57 +0000 | freeside | (~mengwong@103.252.202.159) (Ping timeout: 265 seconds) |
| 2022-12-23 09:06:27 +0000 | <Inst> | or rather, can a for loop be categorized as a hylomorphism? |
| 2022-12-23 09:07:30 +0000 | <Inst> | tbh, no, i'm wrong, it's a traversal |
| 2022-12-23 09:09:11 +0000 | <Inst> | nah, i'm still probably wrong, traversals are the essence of the iterator pattern |
| 2022-12-23 09:09:13 +0000 | tromp | (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…) |
| 2022-12-23 09:12:23 +0000 | eggplantade | (~Eggplanta@2600:1700:38c5:d800:1dcc:166b:1177:c3e0) |
| 2022-12-23 09:16:20 +0000 | arahael | (~arahael@193-119-109-208.tpgi.com.au) (Ping timeout: 246 seconds) |
| 2022-12-23 09:16:41 +0000 | eggplantade | (~Eggplanta@2600:1700:38c5:d800:1dcc:166b:1177:c3e0) (Ping timeout: 246 seconds) |
| 2022-12-23 09:23:00 +0000 | econo | (uid147250@user/econo) (Quit: Connection closed for inactivity) |
| 2022-12-23 09:23:15 +0000 | arahael | (~arahael@193-119-109-208.tpgi.com.au) |
| 2022-12-23 09:25:34 +0000 | bollu | (~bollu@159.65.151.13) (Ping timeout: 260 seconds) |
| 2022-12-23 09:26:32 +0000 | freeside | (~mengwong@103.252.202.159) |
| 2022-12-23 09:27:17 +0000 | thongpv87 | (~thongpv87@2402:9d80:346:901d:126:7968:86ee:f4cf) (Remote host closed the connection) |
| 2022-12-23 09:27:36 +0000 | thongpv87 | (~thongpv87@2402:9d80:346:901d:bbbb:324b:8132:73e8) |
| 2022-12-23 09:33:19 +0000 | freeside | (~mengwong@103.252.202.159) (Ping timeout: 252 seconds) |
| 2022-12-23 09:36:29 +0000 | arahael | (~arahael@193-119-109-208.tpgi.com.au) (Read error: Connection reset by peer) |
| 2022-12-23 09:43:03 +0000 | troydm | (~troydm@host-176-37-124-197.b025.la.net.ua) |
| 2022-12-23 09:45:15 +0000 | Midjak | (~Midjak@82.66.147.146) (Quit: Leaving) |
| 2022-12-23 09:54:08 +0000 | cheater | (~Username@user/cheater) (Quit: Going offline, see ya! (www.adiirc.com)) |
| 2022-12-23 09:54:28 +0000 | cheater | (~Username@user/cheater) |
| 2022-12-23 09:56:34 +0000 | Inst | (~Inst@2601:6c4:4081:54f0:c13a:1faa:a088:6fcb) (Ping timeout: 252 seconds) |
| 2022-12-23 10:01:15 +0000 | arahael | (~arahael@193-119-109-208.tpgi.com.au) |
| 2022-12-23 10:01:36 +0000 | __monty__ | (~toonn@user/toonn) |
| 2022-12-23 10:01:56 +0000 | mc47 | (~mc47@xmonad/TheMC47) |
| 2022-12-23 10:07:49 +0000 | azimut | (~azimut@gateway/tor-sasl/azimut) (Quit: ZNC - https://znc.in) |
| 2022-12-23 10:08:30 +0000 | azimut | (~azimut@gateway/tor-sasl/azimut) |
| 2022-12-23 10:11:58 +0000 | tabaqui | (~root@88.231.57.48) (Ping timeout: 272 seconds) |
| 2022-12-23 10:12:29 +0000 | Lycurgus | (~juan@user/Lycurgus) |
| 2022-12-23 10:18:03 +0000 | tzh | (~tzh@c-24-21-73-154.hsd1.wa.comcast.net) (Quit: zzz) |
| 2022-12-23 10:18:13 +0000 | waleee | (~waleee@2001:9b0:213:7200:cc36:a556:b1e8:b340) |
| 2022-12-23 10:19:41 +0000 | raym | (~ray@user/raym) (Quit: server reboot) |
| 2022-12-23 10:20:12 +0000 | Kaiepi | (~Kaiepi@108.175.84.104) (Ping timeout: 272 seconds) |
| 2022-12-23 10:20:13 +0000 | fserucas | (~fserucas@a85-138-107-42.cpe.netcabo.pt) |
| 2022-12-23 10:25:16 +0000 | xff0x | (~xff0x@125x103x176x34.ap125.ftth.ucom.ne.jp) (Ping timeout: 272 seconds) |
| 2022-12-23 10:25:49 +0000 | Lycurgus | (~juan@user/Lycurgus) (Quit: Exeunt: personae.ai-integration.biz) |
| 2022-12-23 10:26:04 +0000 | `2jt | (~jtomas@84.red-88-17-186.dynamicip.rima-tde.net) |
| 2022-12-23 10:26:12 +0000 | akegalj | (~akegalj@93-136-77-137.adsl.net.t-com.hr) |
| 2022-12-23 10:27:22 +0000 | shapr | (~user@68.54.166.125) (Ping timeout: 252 seconds) |
| 2022-12-23 10:27:45 +0000 | Lord_of_Life_ | (~Lord@user/lord-of-life/x-2819915) |
| 2022-12-23 10:28:13 +0000 | Lord_of_Life | (~Lord@user/lord-of-life/x-2819915) (Ping timeout: 260 seconds) |
| 2022-12-23 10:30:35 +0000 | Lord_of_Life_ | Lord_of_Life |
| 2022-12-23 10:30:46 +0000 | tromp | (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) |
| 2022-12-23 10:35:19 +0000 | thongpv87 | (~thongpv87@2402:9d80:346:901d:bbbb:324b:8132:73e8) (Ping timeout: 260 seconds) |
| 2022-12-23 10:36:15 +0000 | <cheater> | [exa] hi |
| 2022-12-23 10:36:57 +0000 | <Jadesheit[m]> | hello |
| 2022-12-23 10:37:27 +0000 | <Jadesheit[m]> | https://en.wikipedia.org/wiki/Haskell,_Texas |
| 2022-12-23 10:43:27 +0000 | <Hecate> | indeed |
| 2022-12-23 10:43:28 +0000 | Vajb | (~Vajb@2001:999:250:c9:8588:6e93:7809:7816) (Read error: Connection reset by peer) |
| 2022-12-23 10:44:03 +0000 | akegalj | (~akegalj@93-136-77-137.adsl.net.t-com.hr) (Quit: leaving) |
| 2022-12-23 10:44:43 +0000 | Vajb | (~Vajb@hag-jnsbng11-58c3a5-27.dhcp.inet.fi) |
| 2022-12-23 10:50:54 +0000 | bgs | (~bgs@212-85-160-171.dynamic.telemach.net) |
| 2022-12-23 10:50:59 +0000 | unit73e | (~emanuel@2001:818:e8dd:7c00:656:e5ff:fe72:9d36) |
| 2022-12-23 10:51:25 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 252 seconds) |
| 2022-12-23 10:53:15 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 10:53:53 +0000 | cheater | (~Username@user/cheater) (Ping timeout: 260 seconds) |
| 2022-12-23 10:55:00 +0000 | kenaryn | (~aurele@cre71-h03-89-88-44-27.dsl.sta.abo.bbox.fr) |
| 2022-12-23 10:56:00 +0000 | CiaoSen | (~Jura@p200300c9571ee1002a3a4dfffe84dbd5.dip0.t-ipconnect.de) |
| 2022-12-23 10:58:27 +0000 | Vajb | (~Vajb@hag-jnsbng11-58c3a5-27.dhcp.inet.fi) (Read error: Connection reset by peer) |
| 2022-12-23 10:59:22 +0000 | zer0bitz | (~zer0bitz@196.244.192.57) (Read error: Connection reset by peer) |
| 2022-12-23 10:59:41 +0000 | Vajb | (~Vajb@hag-jnsbng11-58c3a5-27.dhcp.inet.fi) |
| 2022-12-23 11:05:02 +0000 | <kjlid[m]> | How do I indicate a failure when parsing an optparse-applicative option? |
| 2022-12-23 11:07:01 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 268 seconds) |
| 2022-12-23 11:08:43 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 11:09:12 +0000 | <Hecate> | kjlid[m]: abortOption perhaps? |
| 2022-12-23 11:09:43 +0000 | <Hecate> | or return a manual https://hackage.haskell.org/package/optparse-applicative-0.17.0.0/docs/Options-Applicative.html#t:… |
| 2022-12-23 11:15:20 +0000 | arahael | (~arahael@193-119-109-208.tpgi.com.au) (Ping timeout: 246 seconds) |
| 2022-12-23 11:16:27 +0000 | xff0x | (~xff0x@ai071162.d.east.v6connect.net) |
| 2022-12-23 11:19:39 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 260 seconds) |
| 2022-12-23 11:20:21 +0000 | <kjlid[m]> | I wonder if I'm using the wrong type. According to the documentation: "Options: options with an argument. An option can define a reader, which converts its argument from String to the desired value, or throws a parse error if the argument does not validate correctly" |
| 2022-12-23 11:21:08 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 11:22:09 +0000 | <kjlid[m]> | I'm not sure I'm using a reader |
| 2022-12-23 11:23:30 +0000 | Kaiepi | (~Kaiepi@108.175.84.104) |
| 2022-12-23 11:23:32 +0000 | TheCoffeMaker | (~TheCoffeM@user/thecoffemaker) (Ping timeout: 272 seconds) |
| 2022-12-23 11:24:01 +0000 | waleee | (~waleee@2001:9b0:213:7200:cc36:a556:b1e8:b340) (Ping timeout: 252 seconds) |
| 2022-12-23 11:24:06 +0000 | TheCoffeMaker | (~TheCoffeM@user/thecoffemaker) |
| 2022-12-23 11:25:52 +0000 | gnalzo | (~gnalzo@2a01:e0a:498:fd50:fcc6:bb5d:489a:ce8c) |
| 2022-12-23 11:28:44 +0000 | L29Ah | (~L29Ah@wikipedia/L29Ah) |
| 2022-12-23 11:33:15 +0000 | coot | (~coot@2a02:a310:e241:1b00:ec1a:e9df:79ac:66ba) |
| 2022-12-23 11:36:45 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 265 seconds) |
| 2022-12-23 11:38:36 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 11:39:20 +0000 | bjourne | (~bjorn@94.191.152.226) |
| 2022-12-23 11:39:46 +0000 | <kjlid[m]> | Yeah I think I solved it with an eitherReader |
| 2022-12-23 11:39:54 +0000 | <mniip> | kjlid[m], a reader in the common sense, not the "reader monad" |
| 2022-12-23 11:42:16 +0000 | <kjlid[m]> | well yeah |
| 2022-12-23 11:42:23 +0000 | bjourne | (~bjorn@94.191.152.226) (Client Quit) |
| 2022-12-23 11:43:59 +0000 | zer0bitz | (~zer0bitz@196.244.192.61) |
| 2022-12-23 11:45:08 +0000 | raym | (~ray@user/raym) |
| 2022-12-23 11:46:08 +0000 | waleee | (~waleee@2001:9b0:213:7200:cc36:a556:b1e8:b340) |
| 2022-12-23 11:50:46 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 272 seconds) |
| 2022-12-23 11:52:02 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 11:55:54 +0000 | gurkenglas | (~gurkengla@p548ac72e.dip0.t-ipconnect.de) |
| 2022-12-23 11:58:31 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 252 seconds) |
| 2022-12-23 12:00:23 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 12:02:24 +0000 | gnalzo | (~gnalzo@2a01:e0a:498:fd50:fcc6:bb5d:489a:ce8c) (Quit: WeeChat 3.7.1) |
| 2022-12-23 12:03:49 +0000 | freeside | (~mengwong@101.100.175.180) |
| 2022-12-23 12:05:48 +0000 | waleee | (~waleee@2001:9b0:213:7200:cc36:a556:b1e8:b340) (Quit: WeeChat 3.7.1) |
| 2022-12-23 12:07:27 +0000 | akegalj | (~akegalj@141-136-145-147.dsl.iskon.hr) |
| 2022-12-23 12:08:11 +0000 | freeside | (~mengwong@101.100.175.180) (Ping timeout: 248 seconds) |
| 2022-12-23 12:14:14 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 268 seconds) |
| 2022-12-23 12:15:57 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 12:20:08 +0000 | thongpv87 | (~thongpv87@2402:9d80:34e:5a49:8993:bc07:c810:9d83) |
| 2022-12-23 12:24:53 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 260 seconds) |
| 2022-12-23 12:26:21 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 12:28:24 +0000 | fizbin | (~fizbin@user/fizbin) |
| 2022-12-23 12:31:12 +0000 | freeside | (~mengwong@101.100.175.180) |
| 2022-12-23 12:31:18 +0000 | jakalx | (~jakalx@base.jakalx.net) () |
| 2022-12-23 12:32:20 +0000 | phma | (~phma@host-67-44-208-203.hnremote.net) (Read error: Connection reset by peer) |
| 2022-12-23 12:33:14 +0000 | phma | (phma@2001:5b0:210d:bff8:d3d6:20cf:c049:77a5) |
| 2022-12-23 12:33:19 +0000 | CiaoSen | (~Jura@p200300c9571ee1002a3a4dfffe84dbd5.dip0.t-ipconnect.de) (Ping timeout: 252 seconds) |
| 2022-12-23 12:36:05 +0000 | kenaryn | (~aurele@cre71-h03-89-88-44-27.dsl.sta.abo.bbox.fr) (Quit: leaving) |
| 2022-12-23 12:36:11 +0000 | freeside | (~mengwong@101.100.175.180) (Ping timeout: 264 seconds) |
| 2022-12-23 12:36:56 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 246 seconds) |
| 2022-12-23 12:39:20 +0000 | TheCoffeMaker | (~TheCoffeM@user/thecoffemaker) (Ping timeout: 246 seconds) |
| 2022-12-23 12:39:32 +0000 | tromp | (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…) |
| 2022-12-23 12:43:45 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 12:44:30 +0000 | coot | (~coot@2a02:a310:e241:1b00:ec1a:e9df:79ac:66ba) (Quit: coot) |
| 2022-12-23 12:45:53 +0000 | TheCoffeMaker | (~TheCoffeM@user/thecoffemaker) |
| 2022-12-23 12:46:10 +0000 | jakalx | (~jakalx@base.jakalx.net) |
| 2022-12-23 12:48:15 +0000 | <unit73e> | now that I think about, didn't Rust also try to copy Haskell, but poorly? |
| 2022-12-23 12:48:54 +0000 | <stefan-_> | xml-conduit's Text.XML.Cursor does not have very good error handling, it just returns an empty result if for example an attribute is missing, is there a better way to parse xml which also produces human-readable errors? |
| 2022-12-23 12:52:04 +0000 | <unit73e> | stefan-_, what I usually do is search on hackage: https://hackage.haskell.org/packages/search?terms=xml |
| 2022-12-23 12:52:06 +0000 | <unit73e> | and just pick one |
| 2022-12-23 12:52:26 +0000 | <unit73e> | there's haxpat and haxml |
| 2022-12-23 12:52:26 +0000 | <c_wraith> | what sort of errors? malformed xml? failed schema validation? Some sort of additional semantic layer? |
| 2022-12-23 12:52:50 +0000 | <unit73e> | but yeah it seems a rather popular package to have those kinds of problems |
| 2022-12-23 12:53:44 +0000 | <stefan-_> | c_wraith, if for example an attribute is queried for, then the processing should fail with an error message "missing attribute" |
| 2022-12-23 12:54:04 +0000 | <stefan-_> | malformed xml would also be nice, I guess most xml libraries do this already |
| 2022-12-23 12:54:06 +0000 | <c_wraith> | that doesn't sound like any kind of xml error condition I'm aware of |
| 2022-12-23 12:54:12 +0000 | <stefan-_> | for schema there is no need |
| 2022-12-23 12:54:34 +0000 | dextaa4 | (~DV@user/dextaa) |
| 2022-12-23 12:54:59 +0000 | <unit73e> | an attribute doesn't necessarily have to exist to be queried, it can just return nothing |
| 2022-12-23 12:55:12 +0000 | <unit73e> | *to be queried, and fail |
| 2022-12-23 12:55:56 +0000 | <stefan-_> | correction: "if for example an attribute which is queried for is missing" |
| 2022-12-23 12:56:43 +0000 | dextaa | (~DV@user/dextaa) (Ping timeout: 260 seconds) |
| 2022-12-23 12:56:44 +0000 | dextaa4 | dextaa |
| 2022-12-23 12:57:29 +0000 | <unit73e> | stefan-_, so be clear, you're calling 'attribute :: Name -> Cursor' and returns []? |
| 2022-12-23 12:58:15 +0000 | <unit73e> | but you want that function to fail if the attribute doesn't exist? |
| 2022-12-23 12:58:17 +0000 | <stefan-_> | correct, attribute :: Name -> Cursor -> [T.Text] returns an empty list |
| 2022-12-23 12:58:21 +0000 | <stefan-_> | yep :) |
| 2022-12-23 13:00:20 +0000 | freeside | (~mengwong@101.100.175.180) |
| 2022-12-23 13:00:53 +0000 | <c_wraith> | I don't see how else it could possibly indicate that there are zero matching attributes... |
| 2022-12-23 13:02:43 +0000 | <stefan-_> | c_wraith, with this I need to do the error handling manually, I thought there would be an existing monad-like parser |
| 2022-12-23 13:03:47 +0000 | <Rembane> | You could see empty list as failure if you squint. A `[a]` is in some ways a much more powerful `Maybe a` where Nothing is empty list and `Just a` is a list with one element. |
| 2022-12-23 13:04:16 +0000 | <unit73e> | so attribute returns all attributes that exist, and [] if there's none. Looks okay to me. yeah [] means it doesn't have any. |
| 2022-12-23 13:04:28 +0000 | <unit73e> | why not check with that? |
| 2022-12-23 13:04:33 +0000 | <c_wraith> | like, that's *not* an error condition |
| 2022-12-23 13:04:40 +0000 | <c_wraith> | that's why there's no error logic involved |
| 2022-12-23 13:04:48 +0000 | freeside | (~mengwong@101.100.175.180) (Ping timeout: 268 seconds) |
| 2022-12-23 13:05:15 +0000 | <unit73e> | agreed, I'd use the same library if I'm used to it. not that there's anything wrong with others like haxml or whatever |
| 2022-12-23 13:05:28 +0000 | <unit73e> | and just figure out with code what to do |
| 2022-12-23 13:05:32 +0000 | <unit73e> | or want to do |
| 2022-12-23 13:06:57 +0000 | <unit73e> | also there's check and other functions that.. check.. conditions |
| 2022-12-23 13:08:35 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 264 seconds) |
| 2022-12-23 13:10:25 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 13:10:56 +0000 | cheater | (~Username@user/cheater) |
| 2022-12-23 13:11:58 +0000 | <stefan-_> | so, that basically means "roll your own error-handling"? |
| 2022-12-23 13:12:44 +0000 | Guest17 | (~Guest17@194.42.11.29) |
| 2022-12-23 13:13:03 +0000 | tromp | (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) |
| 2022-12-23 13:13:19 +0000 | <unit73e> | yeah because failing because an attribute doesn't exist is not really that common |
| 2022-12-23 13:14:07 +0000 | <unit73e> | that's more like, logic you want in your application |
| 2022-12-23 13:14:07 +0000 | Guest17 | (~Guest17@194.42.11.29) (Client Quit) |
| 2022-12-23 13:15:59 +0000 | eggplantade | (~Eggplanta@2600:1700:38c5:d800:1dcc:166b:1177:c3e0) |
| 2022-12-23 13:16:27 +0000 | <unit73e> | you can easily roll out your own Exception or Either, pick your poison, and make it all monadic |
| 2022-12-23 13:16:48 +0000 | fizbin | (~fizbin@user/fizbin) (Ping timeout: 260 seconds) |
| 2022-12-23 13:18:34 +0000 | <stefan-_> | ok, thanks |
| 2022-12-23 13:18:49 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 252 seconds) |
| 2022-12-23 13:19:25 +0000 | <stefan-_> | then one more question, say I have this name: "Martín Abadi", having this as Text and printing it out shows: "Mart\237n Abadi" |
| 2022-12-23 13:19:43 +0000 | <stefan-_> | is that the common behaviour for Text with non-ascii characters? |
| 2022-12-23 13:20:17 +0000 | eggplantade | (~Eggplanta@2600:1700:38c5:d800:1dcc:166b:1177:c3e0) (Ping timeout: 252 seconds) |
| 2022-12-23 13:20:25 +0000 | <stefan-_> | unpacking as String and printing it shows: "Martín Abadi" |
| 2022-12-23 13:20:47 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 13:24:26 +0000 | freeside | (~mengwong@101.100.175.180) |
| 2022-12-23 13:25:11 +0000 | <unit73e> | statusbot, you should use Data.Text.IO.putStrLn or Text.Printf if you need it |
| 2022-12-23 13:25:37 +0000 | <unit73e> | lol wrong person |
| 2022-12-23 13:25:41 +0000 | <unit73e> | stefan-_, see above |
| 2022-12-23 13:27:55 +0000 | <stefan-_> | coolio, thanks |
| 2022-12-23 13:28:08 +0000 | <stefan-_> | am I right that this is a "feature" of the Show instance for Text? |
| 2022-12-23 13:28:43 +0000 | freeside | (~mengwong@101.100.175.180) (Ping timeout: 248 seconds) |
| 2022-12-23 13:29:22 +0000 | <unit73e> | it's sort of a feature. the thing is Text can have multiple encodings, so it will show unicode with Show |
| 2022-12-23 13:29:50 +0000 | <unit73e> | I think utf-8 is the default afaik |
| 2022-12-23 13:31:00 +0000 | <unit73e> | so basically what matter is Show is showing unicode because that's what Text actually stores |
| 2022-12-23 13:31:16 +0000 | gnalzo | (~gnalzo@2a01:e0a:498:fd50:fcc6:bb5d:489a:ce8c) |
| 2022-12-23 13:32:31 +0000 | Guest323 | (~finn@roc37-h01-176-170-197-243.dsl.sta.abo.bbox.fr) |
| 2022-12-23 13:32:46 +0000 | <__monty__> | I think Data.Text uses UTF-16 internally. |
| 2022-12-23 13:34:36 +0000 | <__monty__> | I think the Show instance uses escape codes because that's more reliable. Show isn't for rendering pretty things, it's to give a String representation of a value that can (usually) be parsed back into the value by passing it to the corresponding `read`. |
| 2022-12-23 13:35:07 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 248 seconds) |
| 2022-12-23 13:35:08 +0000 | <__monty__> | String is just as "unicode" as Text is BTW, it's not restricted to ASCII. |
| 2022-12-23 13:36:20 +0000 | <stefan-_> | ok, makes sense, thanks for the explanations |
| 2022-12-23 13:36:27 +0000 | fizbin | (~fizbin@user/fizbin) |
| 2022-12-23 13:36:53 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 13:41:43 +0000 | <geekosaur> | Text 2.x is UTF-8 internally |
| 2022-12-23 13:42:22 +0000 | acarrico | (~acarrico@dhcp-68-142-49-34.greenmountainaccess.net) (Quit: Leaving.) |
| 2022-12-23 13:43:02 +0000 | fizbin | (~fizbin@user/fizbin) (Ping timeout: 268 seconds) |
| 2022-12-23 13:43:23 +0000 | Kaiepi | (~Kaiepi@108.175.84.104) (Ping timeout: 246 seconds) |
| 2022-12-23 13:44:51 +0000 | gurkenglas | (~gurkengla@p548ac72e.dip0.t-ipconnect.de) (Ping timeout: 252 seconds) |
| 2022-12-23 13:44:54 +0000 | Kaiepi | (~Kaiepi@108.175.84.104) |
| 2022-12-23 13:47:28 +0000 | Reinhilde | MelMalik |
| 2022-12-23 13:48:04 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 260 seconds) |
| 2022-12-23 13:49:31 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 13:49:58 +0000 | AlexNoo | (~AlexNoo@94.233.241.57) (Read error: Connection reset by peer) |
| 2022-12-23 13:50:21 +0000 | AlexNoo | (~AlexNoo@94.233.241.57) |
| 2022-12-23 13:50:37 +0000 | coot | (~coot@213.134.171.3) |
| 2022-12-23 13:52:59 +0000 | [itchyjunk] | (~itchyjunk@user/itchyjunk/x-7353470) |
| 2022-12-23 13:54:00 +0000 | AlexNoo | (~AlexNoo@94.233.241.57) (Read error: Connection reset by peer) |
| 2022-12-23 13:55:44 +0000 | freeside | (~mengwong@101.100.175.180) |
| 2022-12-23 13:57:24 +0000 | gurkenglas | (~gurkengla@84.138.199.46) |
| 2022-12-23 13:57:24 +0000 | AlexZenon | (~alzenon@94.233.241.57) (Ping timeout: 265 seconds) |
| 2022-12-23 13:57:31 +0000 | Alex_test | (~al_test@94.233.241.57) (Ping timeout: 248 seconds) |
| 2022-12-23 13:57:59 +0000 | <mauke> | > "Martín Abadi" |
| 2022-12-23 13:58:01 +0000 | <lambdabot> | "Mart\237n Abadi" |
| 2022-12-23 13:58:27 +0000 | <mauke> | also the Show instance for String |
| 2022-12-23 13:58:36 +0000 | <unit73e> | looks like it |
| 2022-12-23 13:58:54 +0000 | <unit73e> | yeah tested in ghci, same result |
| 2022-12-23 13:59:17 +0000 | <unit73e> | so it's always unicode |
| 2022-12-23 14:00:06 +0000 | freeside | (~mengwong@101.100.175.180) (Ping timeout: 255 seconds) |
| 2022-12-23 14:03:33 +0000 | jmdaemon | (~jmdaemon@user/jmdaemon) (Ping timeout: 252 seconds) |
| 2022-12-23 14:06:19 +0000 | CiaoSen | (~Jura@p200300c9571ee1002a3a4dfffe84dbd5.dip0.t-ipconnect.de) |
| 2022-12-23 14:08:58 +0000 | <__monty__> | geekosaur: Thanks! |
| 2022-12-23 14:09:06 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 255 seconds) |
| 2022-12-23 14:09:39 +0000 | <geekosaur> | > text "Martín Abadi" -- hack for lambdabot |
| 2022-12-23 14:09:41 +0000 | <lambdabot> | Martín Abadi |
| 2022-12-23 14:10:16 +0000 | <Jadesheit[m]> | @src (<*>) |
| 2022-12-23 14:10:17 +0000 | <lambdabot> | Source not found. Abort, Retry, Panic? |
| 2022-12-23 14:10:21 +0000 | freeside | (~mengwong@101.100.175.180) |
| 2022-12-23 14:10:21 +0000 | <geekosaur> | the prettyprinting lib lambdabot has loaded has a Show instance of id for String. (I don't think it supports Text.) |
| 2022-12-23 14:10:56 +0000 | <geekosaur> | actually for Doc, which `text` converts String into |
| 2022-12-23 14:11:04 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 14:11:16 +0000 | <geekosaur> | and the @src database predates Applicative so none of those are in it |
| 2022-12-23 14:12:03 +0000 | <geekosaur> | it's not actually looking up the source, it's dumping from a small database mostly populated from the Haskell 98 Report |
| 2022-12-23 14:12:23 +0000 | thegeekinside | (~thegeekin@189.128.148.159) |
| 2022-12-23 14:13:09 +0000 | <[itchyjunk]> | Woha, I am reading an article on "Promises" in js and apparently, Haskell order of operation is already like this ( idk what "this" mean but let me vaguely point to the univers) |
| 2022-12-23 14:13:50 +0000 | <__monty__> | [itchyjunk]: The "this" is probably referring to call-by-need semantics? |
| 2022-12-23 14:14:10 +0000 | <mauke> | yes, <- (in a do block) is a lot like await (in an async function) |
| 2022-12-23 14:14:26 +0000 | <mauke> | and >>= correspinds to .then() |
| 2022-12-23 14:14:32 +0000 | troydm | (~troydm@host-176-37-124-197.b025.la.net.ua) (Ping timeout: 272 seconds) |
| 2022-12-23 14:14:49 +0000 | <[itchyjunk]> | hmm, something like that. http://robotlolita.me/2015/11/15/how-do-promises-work.html |
| 2022-12-23 14:15:06 +0000 | <[itchyjunk]> | :o |
| 2022-12-23 14:17:15 +0000 | jakalx | (~jakalx@base.jakalx.net) (Error from remote client) |
| 2022-12-23 14:18:08 +0000 | <mauke> | ah, that's about laziness in general |
| 2022-12-23 14:18:33 +0000 | jakalx | (~jakalx@base.jakalx.net) |
| 2022-12-23 14:18:45 +0000 | Kaipei | (~Kaiepi@108.175.84.104) |
| 2022-12-23 14:21:02 +0000 | Unicorn_Princess | (~Unicorn_P@user/Unicorn-Princess/x-3540542) |
| 2022-12-23 14:21:54 +0000 | Kaiepi | (~Kaiepi@108.175.84.104) (Ping timeout: 260 seconds) |
| 2022-12-23 14:22:05 +0000 | slack1256 | (~slack1256@186.11.29.60) (Remote host closed the connection) |
| 2022-12-23 14:22:13 +0000 | AlexNoo | (~AlexNoo@178.34.150.54) |
| 2022-12-23 14:23:03 +0000 | AlexZenon | (~alzenon@178.34.150.54) |
| 2022-12-23 14:23:31 +0000 | Alex_test | (~al_test@178.34.150.54) |
| 2022-12-23 14:27:12 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 272 seconds) |
| 2022-12-23 14:27:52 +0000 | <Jadesheit[m]> | How is the list monad instance defined using list comprehension? |
| 2022-12-23 14:28:10 +0000 | <Jadesheit[m]> | Does it not desugar to itself? |
| 2022-12-23 14:28:36 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 14:28:53 +0000 | Kaiepi | (~Kaiepi@108.175.84.104) |
| 2022-12-23 14:29:01 +0000 | <geekosaur> | list coomprehensions actually desugar to regular functions, unless MonadComprehensions is enabled in the source file |
| 2022-12-23 14:29:29 +0000 | Kaipei | (~Kaiepi@108.175.84.104) (Ping timeout: 260 seconds) |
| 2022-12-23 14:30:01 +0000 | <mauke> | @undo [ f x | x <- xs, p x ] |
| 2022-12-23 14:30:01 +0000 | <lambdabot> | concatMap (\ x -> if p x then [f x] else []) xs |
| 2022-12-23 14:30:20 +0000 | bunnyhamer | (~bunnyhame@2a10:8012:21:46dc:6456:24ad:beee:35aa) |
| 2022-12-23 14:30:28 +0000 | <Jadesheit[m]> | geekosaur: how would `[y | x <- xs, y <- f x]` desugar then? |
| 2022-12-23 14:30:36 +0000 | <Jadesheit[m]> | oh |
| 2022-12-23 14:30:39 +0000 | <Jadesheit[m]> | @undo [y | x <- xs, y <- f x] |
| 2022-12-23 14:30:39 +0000 | <lambdabot> | concatMap (\ x -> concatMap (\ y -> [y]) (f x)) xs |
| 2022-12-23 14:31:59 +0000 | <Jadesheit[m]> | Why is the monad instance for `[]` not `(>>=) = concatMap` |
| 2022-12-23 14:32:28 +0000 | <geekosaur> | :t concatMap |
| 2022-12-23 14:32:29 +0000 | <lambdabot> | Foldable t => (a -> [b]) -> t a -> [b] |
| 2022-12-23 14:32:52 +0000 | <geekosaur> | it's reversed. concatMap is actually =<< iirc |
| 2022-12-23 14:33:20 +0000 | <Rembane> | :t (=<<) |
| 2022-12-23 14:33:21 +0000 | <lambdabot> | Monad m => (a -> m b) -> m a -> m b |
| 2022-12-23 14:33:39 +0000 | Rembane | squints |
| 2022-12-23 14:33:39 +0000 | <Rembane> | Yup |
| 2022-12-23 14:34:33 +0000 | <Jadesheit[m]> | ah yeah |
| 2022-12-23 14:34:48 +0000 | <Jadesheit[m]> | `(>>=) = flip concatMap` |
| 2022-12-23 14:35:12 +0000 | <Jadesheit[m]> | wait no it's not |
| 2022-12-23 14:35:23 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 256 seconds) |
| 2022-12-23 14:35:40 +0000 | manj-gnome | (~manjaro-g@85.195.196.52) |
| 2022-12-23 14:36:04 +0000 | Guest323 | (~finn@roc37-h01-176-170-197-243.dsl.sta.abo.bbox.fr) (Ping timeout: 272 seconds) |
| 2022-12-23 14:36:56 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 14:38:05 +0000 | <Rembane> | Jadesheit[m]: I like that definition: https://hackage.haskell.org/package/base-4.17.0.0/docs/src/GHC.Base.html#%3D%3C%3C |
| 2022-12-23 14:41:23 +0000 | <mauke> | Jadesheit[m]: https://hackage.haskell.org/package/base-4.17.0.0/docs/src/GHC.Base.html#line-315 |
| 2022-12-23 14:42:17 +0000 | <Rembane> | TIL! Sweet! |
| 2022-12-23 14:50:00 +0000 | freeside | (~mengwong@101.100.175.180) (Ping timeout: 272 seconds) |
| 2022-12-23 14:53:09 +0000 | motherfsck | (~motherfsc@user/motherfsck) |
| 2022-12-23 14:59:23 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 246 seconds) |
| 2022-12-23 14:59:57 +0000 | tromp | (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…) |
| 2022-12-23 15:00:39 +0000 | themc47 | (~mc47@xmonad/TheMC47) |
| 2022-12-23 15:00:44 +0000 | <unit73e> | Yesterday I had did an interview with a Junior for a Java+React position, but I asked what a Monad was just as a joke, but joke's on me because he was able to explain what a monad is. we're getting somewhere. |
| 2022-12-23 15:01:34 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 15:01:45 +0000 | <unit73e> | no he didn't open a browser to see, he explained some functions and laws |
| 2022-12-23 15:02:10 +0000 | mc47 | (~mc47@xmonad/TheMC47) (Read error: Connection reset by peer) |
| 2022-12-23 15:03:54 +0000 | <Jadesheit[m]> | very nice |
| 2022-12-23 15:04:33 +0000 | <Rembane> | unit73e: Awesome! |
| 2022-12-23 15:04:34 +0000 | <Jadesheit[m]> | so many people now start saying "A monad is a monoid in the category of endofunctors" when I talk about monads on a java server |
| 2022-12-23 15:04:36 +0000 | <Jadesheit[m]> | because of the meme |
| 2022-12-23 15:04:42 +0000 | <Rembane> | Good meme |
| 2022-12-23 15:06:47 +0000 | <Jadesheit[m]> | indeed |
| 2022-12-23 15:06:54 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 268 seconds) |
| 2022-12-23 15:08:21 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 15:08:52 +0000 | shriekingnoise | (~shrieking@186.137.167.202) |
| 2022-12-23 15:10:59 +0000 | Sauvin | (~sauvin@user/Sauvin) (Remote host closed the connection) |
| 2022-12-23 15:11:21 +0000 | Sauvin | (~sauvin@user/Sauvin) |
| 2022-12-23 15:13:35 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 252 seconds) |
| 2022-12-23 15:14:24 +0000 | mikoto-chan | (~mikoto-ch@85-76-3-8-nat.elisa-mobile.fi) |
| 2022-12-23 15:14:39 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 15:16:43 +0000 | tromp | (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) |
| 2022-12-23 15:17:38 +0000 | eggplantade | (~Eggplanta@2600:1700:38c5:d800:1dcc:166b:1177:c3e0) |
| 2022-12-23 15:17:51 +0000 | freeside | (~mengwong@101.100.175.180) |
| 2022-12-23 15:19:39 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 260 seconds) |
| 2022-12-23 15:21:21 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 15:22:20 +0000 | eggplantade | (~Eggplanta@2600:1700:38c5:d800:1dcc:166b:1177:c3e0) (Ping timeout: 260 seconds) |
| 2022-12-23 15:22:34 +0000 | freeside | (~mengwong@101.100.175.180) (Ping timeout: 260 seconds) |
| 2022-12-23 15:22:47 +0000 | igghibu | (~igghibu@178.249.211.100) |
| 2022-12-23 15:23:15 +0000 | jakalx | (~jakalx@base.jakalx.net) (Error from remote client) |
| 2022-12-23 15:26:55 +0000 | igghibu | (~igghibu@178.249.211.100) (Client Quit) |
| 2022-12-23 15:27:35 +0000 | igghibu | (~igghibu@178.249.211.100) |
| 2022-12-23 15:27:55 +0000 | akegalj | (~akegalj@141-136-145-147.dsl.iskon.hr) (Quit: leaving) |
| 2022-12-23 15:28:58 +0000 | jakalx | (~jakalx@base.jakalx.net) |
| 2022-12-23 15:31:25 +0000 | pavonia | (~user@user/siracusa) (Quit: Bye!) |
| 2022-12-23 15:33:04 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 272 seconds) |
| 2022-12-23 15:33:05 +0000 | igghibu | (~igghibu@178.249.211.100) (Quit: WeeChat 3.7.1) |
| 2022-12-23 15:33:22 +0000 | igghibu | (~igghibu@178.249.211.100) |
| 2022-12-23 15:34:47 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 15:38:54 +0000 | Sgeo | (~Sgeo@user/sgeo) |
| 2022-12-23 15:39:45 +0000 | bunnyhamer | (~bunnyhame@2a10:8012:21:46dc:6456:24ad:beee:35aa) (Quit: Client closed) |
| 2022-12-23 15:40:02 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 272 seconds) |
| 2022-12-23 15:40:44 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 15:43:56 +0000 | Guest323 | (~finn@roc37-h01-176-170-197-243.dsl.sta.abo.bbox.fr) |
| 2022-12-23 15:46:13 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 256 seconds) |
| 2022-12-23 15:46:51 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 15:50:25 +0000 | freeside | (~mengwong@101.100.175.180) |
| 2022-12-23 15:50:36 +0000 | MajorBiscuit | (~MajorBisc@31-23-159.netrun.cytanet.com.cy) (Quit: WeeChat 3.6) |
| 2022-12-23 15:51:18 +0000 | jimki | (~jmaki@gazorpazorp.fixme.fi) (Ping timeout: 268 seconds) |
| 2022-12-23 15:54:47 +0000 | freeside | (~mengwong@101.100.175.180) (Ping timeout: 264 seconds) |
| 2022-12-23 15:54:47 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 264 seconds) |
| 2022-12-23 15:56:13 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 15:58:39 +0000 | jimki | (~jmaki@gazorpazorp.fixme.fi) |
| 2022-12-23 15:59:10 +0000 | caryhartline | (~caryhartl@2600:1700:2d0:8d30:68e0:626e:e762:49ca) |
| 2022-12-23 16:05:00 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 265 seconds) |
| 2022-12-23 16:06:36 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 16:09:30 +0000 | beteigeuze | (~Thunderbi@bl14-81-220.dsl.telepac.pt) |
| 2022-12-23 16:09:30 +0000 | beteigeuze | (~Thunderbi@bl14-81-220.dsl.telepac.pt) (Client Quit) |
| 2022-12-23 16:09:43 +0000 | beteigeuze | (~Thunderbi@bl14-81-220.dsl.telepac.pt) |
| 2022-12-23 16:12:15 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 265 seconds) |
| 2022-12-23 16:12:54 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 16:15:31 +0000 | freeside | (~mengwong@101.100.175.180) |
| 2022-12-23 16:16:17 +0000 | razetime | (~quassel@49.207.230.181) (Quit: https://quassel-irc.org - Chat comfortably. Anywhere.) |
| 2022-12-23 16:17:41 +0000 | igghibu | (~igghibu@178.249.211.100) (Quit: igghibu) |
| 2022-12-23 16:17:55 +0000 | igghibu | (~igghibu@178.249.211.100) |
| 2022-12-23 16:18:11 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 264 seconds) |
| 2022-12-23 16:18:38 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 16:18:54 +0000 | califax | (~califax@user/califx) (Quit: ZNC 1.8.2 - https://znc.in) |
| 2022-12-23 16:19:55 +0000 | freeside | (~mengwong@101.100.175.180) (Ping timeout: 248 seconds) |
| 2022-12-23 16:20:58 +0000 | califax | (~califax@user/califx) |
| 2022-12-23 16:21:08 +0000 | gurkenglas | (~gurkengla@84.138.199.46) (Ping timeout: 260 seconds) |
| 2022-12-23 16:22:09 +0000 | gnalzo | (~gnalzo@2a01:e0a:498:fd50:fcc6:bb5d:489a:ce8c) (Quit: WeeChat 3.7.1) |
| 2022-12-23 16:25:19 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 260 seconds) |
| 2022-12-23 16:26:54 +0000 | texasmynsted | (~texasmyns@99.96.221.112) (Ping timeout: 272 seconds) |
| 2022-12-23 16:26:58 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 16:27:01 +0000 | manj-gnome | (~manjaro-g@85.195.196.52) (Quit: Leaving) |
| 2022-12-23 16:27:19 +0000 | mikoto-chan | (~mikoto-ch@85-76-3-8-nat.elisa-mobile.fi) (Ping timeout: 260 seconds) |
| 2022-12-23 16:28:38 +0000 | motherfsck | (~motherfsc@user/motherfsck) (Quit: quit) |
| 2022-12-23 16:28:49 +0000 | mikoto-chan | (~mikoto-ch@85-76-142-82-nat.elisa-mobile.fi) |
| 2022-12-23 16:30:41 +0000 | themc47 | (~mc47@xmonad/TheMC47) (Remote host closed the connection) |
| 2022-12-23 16:31:01 +0000 | themc47 | (~mc47@xmonad/TheMC47) |
| 2022-12-23 16:31:06 +0000 | themc47 | (~mc47@xmonad/TheMC47) (Client Quit) |
| 2022-12-23 16:33:19 +0000 | Heffalump | (~ganesh@urchin.earth.li) |
| 2022-12-23 16:33:38 +0000 | califax | (~califax@user/califx) (Ping timeout: 255 seconds) |
| 2022-12-23 16:33:50 +0000 | <Heffalump> | what's the best way to request a GHC bug fix that's already committed on master be backported to 9.4.x? |
| 2022-12-23 16:34:44 +0000 | tromp | (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…) |
| 2022-12-23 16:35:15 +0000 | califax | (~califax@user/califx) |
| 2022-12-23 16:35:41 +0000 | freeside | (~mengwong@101.100.175.180) |
| 2022-12-23 16:37:10 +0000 | dsrt^ | (~dsrt@76.145.185.103) |
| 2022-12-23 16:39:40 +0000 | mauke | (~mauke@user/mauke) (Quit: leaving) |
| 2022-12-23 16:39:50 +0000 | freeside | (~mengwong@101.100.175.180) (Ping timeout: 246 seconds) |
| 2022-12-23 16:40:39 +0000 | mauke | (~mauke@user/mauke) |
| 2022-12-23 16:41:06 +0000 | kenran | (~user@user/kenran) |
| 2022-12-23 16:41:07 +0000 | mbuf | (~Shakthi@49.204.130.4) (Quit: Leaving) |
| 2022-12-23 16:41:14 +0000 | kenran | (~user@user/kenran) (Remote host closed the connection) |
| 2022-12-23 16:45:25 +0000 | <lyxia> | open an issue? |
| 2022-12-23 16:45:47 +0000 | <Heffalump> | lyxia: open a new issue rather than commenting on the existing one? |
| 2022-12-23 16:46:44 +0000 | <monochrom> | Ugh please don't bring up monads in java communities. :( Here in #haskell we don't bring up checked exceptions either. :D |
| 2022-12-23 16:50:14 +0000 | Kaipei | (~Kaiepi@108.175.84.104) |
| 2022-12-23 16:51:07 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 268 seconds) |
| 2022-12-23 16:51:11 +0000 | CiaoSen | (~Jura@p200300c9571ee1002a3a4dfffe84dbd5.dip0.t-ipconnect.de) (Ping timeout: 264 seconds) |
| 2022-12-23 16:52:05 +0000 | bitdex | (~bitdex@gateway/tor-sasl/bitdex) (Ping timeout: 255 seconds) |
| 2022-12-23 16:52:50 +0000 | tromp | (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) |
| 2022-12-23 16:52:52 +0000 | Kaiepi | (~Kaiepi@108.175.84.104) (Ping timeout: 272 seconds) |
| 2022-12-23 16:52:52 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 16:54:31 +0000 | eggplantade | (~Eggplanta@2600:1700:38c5:d800:1dcc:166b:1177:c3e0) |
| 2022-12-23 16:54:53 +0000 | bitdex | (~bitdex@gateway/tor-sasl/bitdex) |
| 2022-12-23 16:57:11 +0000 | `2jt | (~jtomas@84.red-88-17-186.dynamicip.rima-tde.net) (Ping timeout: 264 seconds) |
| 2022-12-23 17:00:21 +0000 | freeside | (~mengwong@101.100.175.180) |
| 2022-12-23 17:04:41 +0000 | hpc | (~juzz@ip98-169-35-163.dc.dc.cox.net) (Ping timeout: 268 seconds) |
| 2022-12-23 17:04:54 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 272 seconds) |
| 2022-12-23 17:04:54 +0000 | Kaipei | (~Kaiepi@108.175.84.104) (Ping timeout: 272 seconds) |
| 2022-12-23 17:05:03 +0000 | jpds2 | (~jpds@gateway/tor-sasl/jpds) (Remote host closed the connection) |
| 2022-12-23 17:05:03 +0000 | azimut | (~azimut@gateway/tor-sasl/azimut) (Remote host closed the connection) |
| 2022-12-23 17:05:06 +0000 | <lyxia> | Heffalump: yeah |
| 2022-12-23 17:05:18 +0000 | freeside | (~mengwong@101.100.175.180) (Ping timeout: 268 seconds) |
| 2022-12-23 17:05:53 +0000 | jpds2 | (~jpds@gateway/tor-sasl/jpds) |
| 2022-12-23 17:06:16 +0000 | hpc | (~juzz@ip98-169-35-163.dc.dc.cox.net) |
| 2022-12-23 17:06:17 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 17:06:48 +0000 | <geekosaur> | if you have access, I think you're also supposed to attach the issue to the appropriate milestone |
| 2022-12-23 17:07:51 +0000 | azimut | (~azimut@gateway/tor-sasl/azimut) |
| 2022-12-23 17:10:35 +0000 | hpc | (~juzz@ip98-169-35-163.dc.dc.cox.net) (Ping timeout: 248 seconds) |
| 2022-12-23 17:12:02 +0000 | thongpv87 | (~thongpv87@2402:9d80:34e:5a49:8993:bc07:c810:9d83) (Ping timeout: 246 seconds) |
| 2022-12-23 17:16:29 +0000 | hpc | (~juzz@ip98-169-35-163.dc.dc.cox.net) |
| 2022-12-23 17:18:03 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 248 seconds) |
| 2022-12-23 17:19:22 +0000 | seriously_guest | (~seriously@2001:1c06:2715:c200:3b35:92eb:bf95:36ea) |
| 2022-12-23 17:19:42 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 17:20:40 +0000 | <Profpatsch> | Hm, can I have a Coercible instance for a type with a “smart” constructor? |
| 2022-12-23 17:21:03 +0000 | <Profpatsch> | In particular, I’d like to be able to coerce in and out of the `Label` type here https://gist.github.com/Profpatsch/c1992885fd28294968c549e2237ced3f |
| 2022-12-23 17:21:05 +0000 | <geekosaur> | not if the real constructor is hidden |
| 2022-12-23 17:21:11 +0000 | Vajb | (~Vajb@hag-jnsbng11-58c3a5-27.dhcp.inet.fi) (Read error: Connection reset by peer) |
| 2022-12-23 17:21:20 +0000 | Vajb | (~Vajb@2001:999:250:c9:8588:6e93:7809:7816) |
| 2022-12-23 17:21:22 +0000 | <Profpatsch> | But I don’t want to export the constructor, otherwise people start matching on it, but I want them to use the HasField instance |
| 2022-12-23 17:21:26 +0000 | <geekosaur> | you may need a .Internal module which exposes it |
| 2022-12-23 17:22:00 +0000 | <Profpatsch> | eh, it’s just an optimization anyway |
| 2022-12-23 17:22:08 +0000 | <Profpatsch> | in that case I’ll just manually map |
| 2022-12-23 17:22:17 +0000 | <Profpatsch> | sufficiently smart compiler and all that |
| 2022-12-23 17:22:36 +0000 | <Profpatsch> | geekosaur: but good idea, if I ever put it into a library I might want to export it via .Internal |
| 2022-12-23 17:22:48 +0000 | <seriously_guest> | Hey, is anyone familiar with Excercise 3 of Yorgey CIS194 HW 10? https://www.cis.upenn.edu/~cis1940/spring13/hw/10-applicative.pdf . I don't understand this line " Do not implement |
| 2022-12-23 17:22:49 +0000 | <seriously_guest> | them using the low-level definition of a Parser! In other words, pre- |
| 2022-12-23 17:22:49 +0000 | <seriously_guest> | tend that you do not have access to the Parser constructor or even |
| 2022-12-23 17:22:50 +0000 | <seriously_guest> | know how the Parser type is defined." |
| 2022-12-23 17:23:22 +0000 | <Profpatsch> | seriously_guest: don’t use the right side of the Parser difinition |
| 2022-12-23 17:23:24 +0000 | <Profpatsch> | *definition |
| 2022-12-23 17:24:02 +0000 | <seriously_guest> | Profpatsch how would I write this function without using the Parser constructor? abParser :: Parser (Char, Char) |
| 2022-12-23 17:24:30 +0000 | <Profpatsch> | seriously_guest: given that you implemented an Applicative instance just before |
| 2022-12-23 17:24:56 +0000 | tromp | (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…) |
| 2022-12-23 17:25:03 +0000 | <Profpatsch> | You want to use the functions from Applicative to turn a :: Parser Char b :: Parser Char into abParser :: Parser (Char, Char) |
| 2022-12-23 17:25:20 +0000 | <Profpatsch> | so you can get a feel for how Applicative works |
| 2022-12-23 17:25:30 +0000 | <seriously_guest> | ok gotcha thanks for the hint |
| 2022-12-23 17:26:10 +0000 | <Profpatsch> | seriously_guest: If you want to make sure you are doing the right thing, implement the function abParserA :: Applicative m => m (Char, Char) instead |
| 2022-12-23 17:26:36 +0000 | <Profpatsch> | You can use it everywhere you’d use `abParser`, but in the definition you are restricted to only things that Applicative gives you |
| 2022-12-23 17:26:57 +0000 | fizbin | (~fizbin@user/fizbin) |
| 2022-12-23 17:27:06 +0000 | <Profpatsch> | In fact, you can use it for anything that implements Applicative, not just parsers |
| 2022-12-23 17:27:23 +0000 | <Profpatsch> | So you could use it as abParserA :: IO (Char, Char) |
| 2022-12-23 17:27:57 +0000 | <seriously_guest> | *thumbsup* |
| 2022-12-23 17:30:09 +0000 | tromp | (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) |
| 2022-12-23 17:30:47 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 264 seconds) |
| 2022-12-23 17:31:20 +0000 | <Profpatsch> | seriously_guest: correction, abParserA :: Applicative m => m Char -> m (Char, Char) |
| 2022-12-23 17:31:30 +0000 | hpc | (~juzz@ip98-169-35-163.dc.dc.cox.net) (Ping timeout: 272 seconds) |
| 2022-12-23 17:32:07 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 17:35:32 +0000 | Neuromancer | (~Neuromanc@user/neuromancer) |
| 2022-12-23 17:36:22 +0000 | Guest323 | (~finn@roc37-h01-176-170-197-243.dsl.sta.abo.bbox.fr) (Ping timeout: 252 seconds) |
| 2022-12-23 17:38:23 +0000 | econo | (uid147250@user/econo) |
| 2022-12-23 17:39:04 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 260 seconds) |
| 2022-12-23 17:40:29 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 17:42:07 +0000 | gnalzo | (~gnalzo@2a01:e0a:498:fd50:fcc6:bb5d:489a:ce8c) |
| 2022-12-23 17:42:46 +0000 | <seriously_guest> | sorry to bother Profpatsch, but is this cheating according to the assignment? https://paste.tomsmeding.com/MjsokyUC |
| 2022-12-23 17:43:24 +0000 | <seriously_guest> | theres a function char :: Char -> Parser Char thats defined in the hw already; but that techically uses the Parser constructor itself |
| 2022-12-23 17:46:02 +0000 | FragByte | (~christian@user/fragbyte) (Ping timeout: 252 seconds) |
| 2022-12-23 17:46:51 +0000 | FragByte | (~christian@user/fragbyte) |
| 2022-12-23 17:47:13 +0000 | <int-e> | seriously_guest: That's fine. You're putting together simpler parsers (defined earlier) into more complex ones. |
| 2022-12-23 17:47:25 +0000 | <int-e> | > (,) 1 'a' |
| 2022-12-23 17:47:27 +0000 | <lambdabot> | (1,'a') |
| 2022-12-23 17:47:41 +0000 | <int-e> | seriously_guest: you don't really need pairCons, that's just (,) |
| 2022-12-23 17:47:54 +0000 | <seriously_guest> | ^^thanks for that; was looking for something simpler |
| 2022-12-23 17:49:05 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 268 seconds) |
| 2022-12-23 17:50:51 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 17:51:33 +0000 | Kaiepi | (~Kaiepi@2605:b100:b28:783c:5975:664c:67a5:edf) |
| 2022-12-23 17:55:59 +0000 | zmt00 | (~zmt00@user/zmt00) |
| 2022-12-23 17:56:08 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 246 seconds) |
| 2022-12-23 17:56:10 +0000 | unit73e | (~emanuel@2001:818:e8dd:7c00:656:e5ff:fe72:9d36) (Ping timeout: 252 seconds) |
| 2022-12-23 17:56:57 +0000 | tromp | (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…) |
| 2022-12-23 17:58:11 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 17:58:22 +0000 | zmt01 | (~zmt00@user/zmt00) (Ping timeout: 252 seconds) |
| 2022-12-23 18:01:42 +0000 | Bocaneri | (~sauvin@user/Sauvin) |
| 2022-12-23 18:01:58 +0000 | mvk | (~mvk@2607:fea8:5ce3:8500::6126) |
| 2022-12-23 18:02:05 +0000 | Bocaneri | Guest4522 |
| 2022-12-23 18:02:32 +0000 | igghibu | (~igghibu@178.249.211.100) (Quit: igghibu) |
| 2022-12-23 18:03:02 +0000 | <Profpatsch> | seriously_guest: yeah, I’d say that’s the correct solution |
| 2022-12-23 18:03:30 +0000 | <Profpatsch> | seriously_guest: if you want to go fancy you can enable ApplicativeDo notation, then you can write |
| 2022-12-23 18:03:32 +0000 | <Profpatsch> | do |
| 2022-12-23 18:03:37 +0000 | <Profpatsch> | a <- char 'a' |
| 2022-12-23 18:03:39 +0000 | <Profpatsch> | b <- char 'b' |
| 2022-12-23 18:03:42 +0000 | <Profpatsch> | pure (a, b) |
| 2022-12-23 18:04:26 +0000 | Sauvin | (~sauvin@user/Sauvin) (Ping timeout: 272 seconds) |
| 2022-12-23 18:04:27 +0000 | igghibu | (~igghibu@178.249.211.100) |
| 2022-12-23 18:05:10 +0000 | acidjnk | (~acidjnk@p200300d6e7137a614441a736a9b750c4.dip0.t-ipconnect.de) |
| 2022-12-23 18:05:35 +0000 | <Profpatsch> | (I wanted to link the GHC user guide page on that extension here but then I read the page and … lol … a simple concept described in the most complicated way possible) |
| 2022-12-23 18:05:59 +0000 | <Profpatsch> | The Haskell Foundation really needs to hire some good techincal writers |
| 2022-12-23 18:06:09 +0000 | <Profpatsch> | *technical |
| 2022-12-23 18:08:30 +0000 | <seriously_guest> | tbh, Im trying my hardest not to use any language options until I get to a point where i've mastered everything that comes out the box in ghc |
| 2022-12-23 18:09:14 +0000 | <seriously_guest> | otherwise I won't know how we got there... might be the wrong approach but it helps me feel less stressed |
| 2022-12-23 18:09:39 +0000 | <seriously_guest> | but thank you |
| 2022-12-23 18:09:51 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 260 seconds) |
| 2022-12-23 18:11:38 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 18:12:05 +0000 | Ram-Z_ | (Ram-Z@2a01:7e01::f03c:91ff:fe57:d2df) (Ping timeout: 255 seconds) |
| 2022-12-23 18:12:47 +0000 | vpan | (~0@212.117.1.172) (Quit: Leaving.) |
| 2022-12-23 18:13:59 +0000 | Ram-Z | (~Ram-Z@li1814-254.members.linode.com) |
| 2022-12-23 18:17:11 +0000 | mvk | (~mvk@2607:fea8:5ce3:8500::6126) (Quit: Going elsewhere) |
| 2022-12-23 18:18:15 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 260 seconds) |
| 2022-12-23 18:19:59 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 18:20:16 +0000 | fizbin | (~fizbin@user/fizbin) (Ping timeout: 272 seconds) |
| 2022-12-23 18:23:07 +0000 | freeside | (~mengwong@103.252.202.159) |
| 2022-12-23 18:24:48 +0000 | cheater_ | (~Username@user/cheater) |
| 2022-12-23 18:25:34 +0000 | trev | (~trev@user/trev) (Remote host closed the connection) |
| 2022-12-23 18:27:35 +0000 | cheater | (~Username@user/cheater) (Ping timeout: 260 seconds) |
| 2022-12-23 18:27:43 +0000 | cheater_ | cheater |
| 2022-12-23 18:29:01 +0000 | seriously_guest | (~seriously@2001:1c06:2715:c200:3b35:92eb:bf95:36ea) (Quit: Client closed) |
| 2022-12-23 18:30:22 +0000 | tromp | (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) |
| 2022-12-23 18:32:43 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 248 seconds) |
| 2022-12-23 18:34:32 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 18:36:01 +0000 | jakalx | (~jakalx@base.jakalx.net) () |
| 2022-12-23 18:41:35 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 264 seconds) |
| 2022-12-23 18:42:20 +0000 | motherfsck | (~motherfsc@user/motherfsck) |
| 2022-12-23 18:42:54 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 18:45:21 +0000 | jakalx | (~jakalx@base.jakalx.net) |
| 2022-12-23 18:46:13 +0000 | igghibu | (~igghibu@178.249.211.100) (Quit: igghibu) |
| 2022-12-23 18:47:52 +0000 | hpc | (~juzz@ip98-169-35-163.dc.dc.cox.net) |
| 2022-12-23 18:48:41 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 256 seconds) |
| 2022-12-23 18:48:46 +0000 | fserucas | (~fserucas@a85-138-107-42.cpe.netcabo.pt) (Ping timeout: 272 seconds) |
| 2022-12-23 18:50:14 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 18:56:29 +0000 | Guest4522 | Sauvin |
| 2022-12-23 18:56:55 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 268 seconds) |
| 2022-12-23 18:58:34 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 18:59:07 +0000 | finsternis | (~X@23.226.237.192) |
| 2022-12-23 19:00:00 +0000 | tzh | (~tzh@c-24-21-73-154.hsd1.or.comcast.net) |
| 2022-12-23 19:06:47 +0000 | mikoto-chan | (~mikoto-ch@85-76-142-82-nat.elisa-mobile.fi) (Ping timeout: 268 seconds) |
| 2022-12-23 19:10:25 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 252 seconds) |
| 2022-12-23 19:11:59 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 19:19:16 +0000 | <iqubic> | Parsers are really cool, yeah |
| 2022-12-23 19:19:44 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 268 seconds) |
| 2022-12-23 19:21:28 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 19:22:23 +0000 | fryguybob | (~fryguybob@cpe-74-67-169-145.rochester.res.rr.com) (Ping timeout: 264 seconds) |
| 2022-12-23 19:27:24 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 272 seconds) |
| 2022-12-23 19:27:38 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 19:32:44 +0000 | azimut | (~azimut@gateway/tor-sasl/azimut) (Ping timeout: 255 seconds) |
| 2022-12-23 19:33:06 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 272 seconds) |
| 2022-12-23 19:33:14 +0000 | gmg | (~user@user/gehmehgeh) |
| 2022-12-23 19:33:43 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 19:34:54 +0000 | Guest323 | (~finn@roc37-h01-176-170-197-243.dsl.sta.abo.bbox.fr) |
| 2022-12-23 19:35:07 +0000 | [itchyjunk] | (~itchyjunk@user/itchyjunk/x-7353470) (Read error: Connection reset by peer) |
| 2022-12-23 19:36:20 +0000 | pavonia | (~user@user/siracusa) |
| 2022-12-23 19:39:28 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 268 seconds) |
| 2022-12-23 19:41:03 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 19:46:06 +0000 | gurkenglas | (~gurkengla@p548ac72e.dip0.t-ipconnect.de) |
| 2022-12-23 19:47:52 +0000 | Kaiepi | (~Kaiepi@2605:b100:b28:783c:5975:664c:67a5:edf) (Read error: Connection reset by peer) |
| 2022-12-23 19:48:43 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 268 seconds) |
| 2022-12-23 19:50:25 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 19:51:11 +0000 | tromp | (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…) |
| 2022-12-23 19:55:54 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 272 seconds) |
| 2022-12-23 19:56:30 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 20:01:21 +0000 | `2jt | (~jtomas@84.red-88-17-186.dynamicip.rima-tde.net) |
| 2022-12-23 20:02:03 +0000 | jakalx | (~jakalx@base.jakalx.net) () |
| 2022-12-23 20:06:18 +0000 | jmdaemon | (~jmdaemon@user/jmdaemon) |
| 2022-12-23 20:06:52 +0000 | fserucas | (~fserucas@a85-138-107-42.cpe.netcabo.pt) |
| 2022-12-23 20:07:13 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 268 seconds) |
| 2022-12-23 20:08:42 +0000 | tromp | (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) |
| 2022-12-23 20:08:56 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 20:10:48 +0000 | jakalx | (~jakalx@base.jakalx.net) |
| 2022-12-23 20:12:57 +0000 | fserucas | (~fserucas@a85-138-107-42.cpe.netcabo.pt) (Ping timeout: 265 seconds) |
| 2022-12-23 20:19:43 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 265 seconds) |
| 2022-12-23 20:21:20 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 20:27:59 +0000 | foul_owl | (~kerry@157.97.134.158) (Ping timeout: 260 seconds) |
| 2022-12-23 20:28:11 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 268 seconds) |
| 2022-12-23 20:29:41 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 20:30:08 +0000 | fizbin | (~fizbin@user/fizbin) |
| 2022-12-23 20:37:29 +0000 | harveypwca | (~harveypwc@2601:246:c180:a570:3828:d8:e523:3f67) |
| 2022-12-23 20:39:35 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 246 seconds) |
| 2022-12-23 20:40:26 +0000 | jargon | (~jargon@174-22-192-24.phnx.qwest.net) |
| 2022-12-23 20:41:29 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 20:43:31 +0000 | foul_owl | (~kerry@71.212.143.88) |
| 2022-12-23 20:50:57 +0000 | caryhartline | (~caryhartl@2600:1700:2d0:8d30:68e0:626e:e762:49ca) (Ping timeout: 255 seconds) |
| 2022-12-23 20:52:10 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 252 seconds) |
| 2022-12-23 20:53:53 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 20:56:26 +0000 | Sciencentistguy | (~sciencent@hacksoc/ordinary-member) (Read error: Connection reset by peer) |
| 2022-12-23 20:56:42 +0000 | <dgpratt[m]> | is there an easy way to render a Rational (aka Ratio Integer) as a decimal formatted string? |
| 2022-12-23 20:56:46 +0000 | Sciencentistguy | (~sciencent@hacksoc/ordinary-member) |
| 2022-12-23 20:57:07 +0000 | <monochrom> | I would convert to Double. |
| 2022-12-23 20:59:52 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 272 seconds) |
| 2022-12-23 21:00:34 +0000 | mesaoptimizer | (apotheosis@user/PapuaHardyNet) |
| 2022-12-23 21:01:08 +0000 | beefbambi | (~beefbambi@2401:4900:230d:f57c:538c:d7cc:50c0:e377) (Read error: Connection reset by peer) |
| 2022-12-23 21:02:24 +0000 | beefbambi | (~beefbambi@183.82.30.144) |
| 2022-12-23 21:04:19 +0000 | <dgpratt[m]> | thanks monochrom |
| 2022-12-23 21:06:14 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 21:06:55 +0000 | <mauke> | > unfoldr (\x -> if x == 0 then Nothing else Just (properFraction x)) (0.5 :: Rational) |
| 2022-12-23 21:06:57 +0000 | <lambdabot> | [0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0... |
| 2022-12-23 21:06:57 +0000 | motherfsck | (~motherfsc@user/motherfsck) (Ping timeout: 256 seconds) |
| 2022-12-23 21:07:12 +0000 | <mauke> | > unfoldr (\x -> if x == 0 then Nothing else Just (properFraction (x * 10))) (0.5 :: Rational) |
| 2022-12-23 21:07:13 +0000 | <lambdabot> | [5] |
| 2022-12-23 21:07:27 +0000 | <mauke> | > unfoldr (\x -> if x == 0 then Nothing else Just (properFraction (x * 10))) (1/7 :: Rational) |
| 2022-12-23 21:07:29 +0000 | <lambdabot> | [1,4,2,8,5,7,1,4,2,8,5,7,1,4,2,8,5,7,1,4,2,8,5,7,1,4,2,8,5,7,1,4,2,8,5,7,1,4... |
| 2022-12-23 21:08:44 +0000 | Guest323 | (~finn@roc37-h01-176-170-197-243.dsl.sta.abo.bbox.fr) (Ping timeout: 272 seconds) |
| 2022-12-23 21:09:14 +0000 | <mauke> | > (\n -> chr (n + ord '0')) <$> unfoldr (\x -> if x == 0 then Nothing else Just (properFraction (x * 10))) (1/7 :: Rational) |
| 2022-12-23 21:09:16 +0000 | <lambdabot> | "142857142857142857142857142857142857142857142857142857142857142857142857142... |
| 2022-12-23 21:09:57 +0000 | beefbambi | (~beefbambi@183.82.30.144) (Read error: Connection reset by peer) |
| 2022-12-23 21:10:20 +0000 | beefbambi | (~beefbambi@183.82.30.144) |
| 2022-12-23 21:15:04 +0000 | gurkenglas | (~gurkengla@p548ac72e.dip0.t-ipconnect.de) (Ping timeout: 272 seconds) |
| 2022-12-23 21:18:16 +0000 | ircbrowse_tom | (~ircbrowse@2a01:4f8:1c1c:9319::1) |
| 2022-12-23 21:18:22 +0000 | Server | +Cnt |
| 2022-12-23 21:18:31 +0000 | <Jadesheit[m]> | hahaha |
| 2022-12-23 21:18:59 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 260 seconds) |
| 2022-12-23 21:19:19 +0000 | <mauke> | @let showRat r | r < 0 = '-' : showRat (negate r) | otherwise = case properFraction r of (show -> i, map (chr . (ord '0' +)) . unfoldr (\x -> if x == 0 then Nothing else Just (properFraction (x * 10))) -> f) -> i ++ case f of "" -> ""; _ -> '.' : f |
| 2022-12-23 21:19:21 +0000 | <lambdabot> | Defined. |
| 2022-12-23 21:19:34 +0000 | <mauke> | > showRat (1/3) |
| 2022-12-23 21:19:35 +0000 | <lambdabot> | "0.333333333333333303727386009995825588703155517578125" |
| 2022-12-23 21:19:59 +0000 | <Jadesheit[m]> | hm |
| 2022-12-23 21:20:08 +0000 | <mauke> | > showRat (1/3 :: Rational) |
| 2022-12-23 21:20:10 +0000 | <lambdabot> | "0.3333333333333333333333333333333333333333333333333333333333333333333333333... |
| 2022-12-23 21:20:40 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 21:21:03 +0000 | <mauke> | > showRat (355/113 :: Rational) |
| 2022-12-23 21:21:05 +0000 | <lambdabot> | "3.1415929203539823008849557522123893805309734513274336283185840707964601769... |
| 2022-12-23 21:21:13 +0000 | beefbambi | (~beefbambi@183.82.30.144) (Read error: Connection reset by peer) |
| 2022-12-23 21:21:38 +0000 | <mauke> | > showRat (0/0) |
| 2022-12-23 21:21:40 +0000 | <lambdabot> | "-26965397022934738615939577861835371004269654684134598591014512173659901370... |
| 2022-12-23 21:21:47 +0000 | <Jadesheit[m]> | lol |
| 2022-12-23 21:22:05 +0000 | <mauke> | > toRational (0/0) |
| 2022-12-23 21:22:07 +0000 | <lambdabot> | (-26965397022934738615939577861835371004269654684134598591014512173659901370... |
| 2022-12-23 21:22:14 +0000 | <mauke> | faithful! |
| 2022-12-23 21:23:13 +0000 | <mauke> | I'm not sure why the '-' is there, though |
| 2022-12-23 21:23:20 +0000 | <mauke> | > 0/0 < 0 |
| 2022-12-23 21:23:22 +0000 | <lambdabot> | False |
| 2022-12-23 21:24:21 +0000 | <geekosaur> | becuase properFraction (which toRational uses) takes a shortcut that produces garbage for NaN |
| 2022-12-23 21:24:37 +0000 | iqubic | (~avi@2601:602:9502:c70:ddf2:fbad:a58:4a0b) (Ping timeout: 252 seconds) |
| 2022-12-23 21:24:42 +0000 | <geekosaur> | (also for Inf and -Inf, not that Rational has those) |
| 2022-12-23 21:24:50 +0000 | <mauke> | I'm not using properFraction for negative numbers |
| 2022-12-23 21:25:04 +0000 | <mauke> | ooh |
| 2022-12-23 21:25:10 +0000 | <mauke> | I get it |
| 2022-12-23 21:26:10 +0000 | <mauke> | I thought it was my '-', but it is show's '-' |
| 2022-12-23 21:37:43 +0000 | beefbambi | (~beefbambi@183.82.30.144) |
| 2022-12-23 21:38:53 +0000 | gmg | (~user@user/gehmehgeh) (Remote host closed the connection) |
| 2022-12-23 21:40:05 +0000 | morb | (~morb@pool-72-80-94-112.nycmny.fios.verizon.net) |
| 2022-12-23 21:41:48 +0000 | gmg | (~user@user/gehmehgeh) |
| 2022-12-23 21:42:32 +0000 | unit73e | (~emanuel@2001:818:e8dd:7c00:656:e5ff:fe72:9d36) |
| 2022-12-23 21:42:44 +0000 | <talismanick> | Is there a "write your own effect system" tutorial anywhere? |
| 2022-12-23 21:43:11 +0000 | <talismanick> | from free monad guts to something simple like lexi-lambda's effect system |
| 2022-12-23 21:43:43 +0000 | <talismanick> | https://github.com/lexi-lambda/freer-simple |
| 2022-12-23 21:43:51 +0000 | <talismanick> | Freer monads, I suppose I should say |
| 2022-12-23 21:49:20 +0000 | Inst | (~Inst@2601:6c4:4081:54f0:b86b:c7d7:3fe0:861c) |
| 2022-12-23 21:49:25 +0000 | <Inst> | int-e |
| 2022-12-23 21:49:33 +0000 | <Inst> | wait, did you just show me an optimized foldmap with foldb? |
| 2022-12-23 21:50:02 +0000 | <Inst> | that's actually pretty interesting, i'm wondering how to implement it imperatively |
| 2022-12-23 21:51:11 +0000 | pwug | (~pwug@user/pwug) |
| 2022-12-23 21:53:27 +0000 | <talismanick> | Oh, and speaking of effects, has anyone provided a correct implementation (or integration) of non-determinism since this was published? https://github.com/lexi-lambda/eff/blob/8c4df4bf54faf22456354be18095b14825be5e85/notes/semantics-z… |
| 2022-12-23 22:05:44 +0000 | coot | (~coot@213.134.171.3) (Quit: coot) |
| 2022-12-23 22:06:25 +0000 | coot | (~coot@2a02:a310:e241:1b00:ec1a:e9df:79ac:66ba) |
| 2022-12-23 22:06:32 +0000 | coot | (~coot@2a02:a310:e241:1b00:ec1a:e9df:79ac:66ba) (Remote host closed the connection) |
| 2022-12-23 22:26:56 +0000 | tromp | (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…) |
| 2022-12-23 22:29:24 +0000 | morb | (~morb@pool-72-80-94-112.nycmny.fios.verizon.net) (Remote host closed the connection) |
| 2022-12-23 22:36:08 +0000 | thegeekinside | (~thegeekin@189.128.148.159) (Ping timeout: 272 seconds) |
| 2022-12-23 22:36:16 +0000 | tromp | (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) |
| 2022-12-23 22:38:02 +0000 | troydm | (~troydm@host-176-37-124-197.b025.la.net.ua) |
| 2022-12-23 22:38:50 +0000 | morb | (~morb@pool-72-80-94-112.nycmny.fios.verizon.net) |
| 2022-12-23 22:40:34 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 272 seconds) |
| 2022-12-23 22:42:13 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 22:43:18 +0000 | morb | (~morb@pool-72-80-94-112.nycmny.fios.verizon.net) (Remote host closed the connection) |
| 2022-12-23 22:44:00 +0000 | cheater_ | (~Username@user/cheater) |
| 2022-12-23 22:44:42 +0000 | bgs | (~bgs@212-85-160-171.dynamic.telemach.net) (Remote host closed the connection) |
| 2022-12-23 22:47:32 +0000 | cheater | (~Username@user/cheater) (Ping timeout: 272 seconds) |
| 2022-12-23 22:47:35 +0000 | cheater_ | cheater |
| 2022-12-23 22:48:04 +0000 | tromp | (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…) |
| 2022-12-23 22:49:06 +0000 | __monty__ | (~toonn@user/toonn) (Quit: leaving) |
| 2022-12-23 22:49:33 +0000 | biberu | (~biberu@user/biberu) (Read error: Connection reset by peer) |
| 2022-12-23 22:51:29 +0000 | fizbin | (~fizbin@user/fizbin) (Ping timeout: 246 seconds) |
| 2022-12-23 22:52:02 +0000 | beefbambi | (~beefbambi@183.82.30.144) (Read error: Connection reset by peer) |
| 2022-12-23 22:52:36 +0000 | beefbambi | (~beefbambi@183.82.30.144) |
| 2022-12-23 22:53:38 +0000 | takuan | (~takuan@178-116-218-225.access.telenet.be) (Quit: Lost terminal) |
| 2022-12-23 22:55:34 +0000 | thegeekinside | (~thegeekin@189.128.148.159) |
| 2022-12-23 22:56:11 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 268 seconds) |
| 2022-12-23 22:57:09 +0000 | biberu | (~biberu@user/biberu) |
| 2022-12-23 22:57:40 +0000 | werneta | (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) |
| 2022-12-23 22:58:51 +0000 | freeside | (~mengwong@103.252.202.159) (Ping timeout: 248 seconds) |
| 2022-12-23 23:06:47 +0000 | <Inst> | sort of feels like a shame that the core Haskell team wandered off to industry / random projects |
| 2022-12-23 23:07:07 +0000 | <Inst> | the parallelization on Haskell could use improvement |
| 2022-12-23 23:07:50 +0000 | beefbambi | (~beefbambi@183.82.30.144) (Read error: Connection reset by peer) |
| 2022-12-23 23:08:50 +0000 | <Jadesheit[m]> | I feel like I want to help and contribute to haskell, but im unsure in what ways I could do anything that has a meaningful impact or purpose |
| 2022-12-23 23:09:24 +0000 | <Jadesheit[m]> | especially because, even though it has been getting better, my haskell is far from perfect and there are still a lot of things I need to learn |
| 2022-12-23 23:10:22 +0000 | thegeekinside | (~thegeekin@189.128.148.159) (Ping timeout: 268 seconds) |
| 2022-12-23 23:11:36 +0000 | <monochrom> | If you actually use Haskell, you're already contributing! Because one day people are going to ask "does anyone still use Haskell anymore?" and you're going to ask "I still do, haskell is not going away, not on my watch". |
| 2022-12-23 23:13:24 +0000 | azimut | (~azimut@gateway/tor-sasl/azimut) |
| 2022-12-23 23:13:44 +0000 | harveypwca | (~harveypwc@2601:246:c180:a570:3828:d8:e523:3f67) (Quit: Leaving) |
| 2022-12-23 23:16:04 +0000 | wroathe | (~wroathe@207-153-38-140.fttp.usinternet.com) |
| 2022-12-23 23:16:04 +0000 | wroathe | (~wroathe@207-153-38-140.fttp.usinternet.com) (Changing host) |
| 2022-12-23 23:16:04 +0000 | wroathe | (~wroathe@user/wroathe) |
| 2022-12-23 23:16:26 +0000 | freeside | (~mengwong@103.252.202.159) |
| 2022-12-23 23:18:56 +0000 | <Jadesheit[m]> | Something that meets the intersection of being useful and interesting/fun to me would be writing a library, though I'm unsure what for |
| 2022-12-23 23:20:14 +0000 | lagash_ | (lagash@lagash.shelltalk.net) (Quit: ZNC - https://znc.in) |
| 2022-12-23 23:20:42 +0000 | <geekosaur> | Inst, I think the core GHC team would be surprised to learn that they no longer exist |
| 2022-12-23 23:21:19 +0000 | <monochrom> | Ah but the core Haskell team (exact wording) would not be surprised >:) |
| 2022-12-23 23:22:00 +0000 | <geekosaur> | what does parallelization have to do with the language definition? |
| 2022-12-23 23:22:13 +0000 | <monochrom> | The core Haskell team writes Haskell code for those who don't write Haskell code for themselves >:D |
| 2022-12-23 23:22:36 +0000 | <monochrom> | Right, so this is why I'm pretty sure "core Haskell team" was wrong wording. |
| 2022-12-23 23:23:00 +0000 | freeside | (~mengwong@103.252.202.159) (Ping timeout: 272 seconds) |
| 2022-12-23 23:25:00 +0000 | <monochrom> | especially the word "core" |
| 2022-12-23 23:25:20 +0000 | lagash_ | (lagash@lagash.shelltalk.net) |
| 2022-12-23 23:25:51 +0000 | <monochrom> | parallel haskell has always been a kind of DLC rather than any kind of "core", at least for GHC. |
| 2022-12-23 23:27:33 +0000 | <Profpatsch> | Is there a way of interleaving a MonadError Foo m and some thing that needs an unlift like foo :: (a -> IO a) -> IO a |
| 2022-12-23 23:28:17 +0000 | <monochrom> | Perhaps m needs to support both in the first place. |
| 2022-12-23 23:28:44 +0000 | <Profpatsch> | monochrom: yeah, but my problem is that e.g. ExceptT and MonadUnliftIO don’t vibe |
| 2022-12-23 23:28:51 +0000 | <Profpatsch> | there can’t be any state if you want to unlift |
| 2022-12-23 23:29:02 +0000 | <monochrom> | Alternatively go all out and try one of those effect libraries... |
| 2022-12-23 23:30:34 +0000 | <Profpatsch> | More to the point, we use servant, which requires everything to have a a `MonadError ServantError m` restriction, but I’d like to lift stuff like https://hackage.haskell.org/package/postgresql-simple-0.6.5/docs/Database-PostgreSQL-Simple.html#v… into our m |
| 2022-12-23 23:31:03 +0000 | fizbin | (~fizbin@user/fizbin) |
| 2022-12-23 23:31:43 +0000 | beefbambi | (~beefbambi@183.82.30.144) |
| 2022-12-23 23:33:18 +0000 | <monochrom> | In this case, perhaps you can runExceptT somewhere and ExceptT-wrap somewhere else. Basically doing the conjugation yourself. |
| 2022-12-23 23:33:58 +0000 | <Profpatsch> | yeah I’m thinking about how to build a “degraded” stack that allows that |
| 2022-12-23 23:34:10 +0000 | <monochrom> | So basically set a = Either Foo a1 |
| 2022-12-23 23:34:21 +0000 | <Profpatsch> | hmmm |
| 2022-12-23 23:35:02 +0000 | <monochrom> | So I mean something like: ExceptT (fold_ ... (runExceptT ...)) |
| 2022-12-23 23:35:25 +0000 | <monochrom> | err, ExceptT (fold_ ... (\a r -> runExceptT ...)) |
| 2022-12-23 23:35:42 +0000 | <Profpatsch> | monochrom: Ah so you mean not over any (UnliftIO m), just over ExceptT |
| 2022-12-23 23:35:44 +0000 | <Profpatsch> | hmmm |
| 2022-12-23 23:35:46 +0000 | <Profpatsch> | maybe that works |
| 2022-12-23 23:35:48 +0000 | <Profpatsch> | I’ll try it out |
| 2022-12-23 23:35:53 +0000 | iqubic | (~avi@2601:602:9502:c70:4602:12a1:6697:a25f) |
| 2022-12-23 23:37:22 +0000 | <Inst> | Haskell is actually doing fairly well on Google Trends |
| 2022-12-23 23:37:44 +0000 | <Inst> | I think when the last HF foundation director was kind enough to speak to me, he was absolutely right that Haskell needs lots of improvement in tooling and ecosystem |
| 2022-12-23 23:38:01 +0000 | <dgpratt[m]> | @pl f x y = g (h x y) |
| 2022-12-23 23:38:02 +0000 | <lambdabot> | f = (g .) . h |
| 2022-12-23 23:38:29 +0000 | <Inst> | lol "pl" => "pointless" |
| 2022-12-23 23:39:51 +0000 | <Inst> | regarding the parallelism; I'm wondering if there's an intrinsic compatibility between laziness and parallelism |
| 2022-12-23 23:40:29 +0000 | <Inst> | Haskell survives because it's lazy-by-default; Haskell was designed to unify lazy languages in FP space, and it seems that no one else is going to do lazy-by-default |
| 2022-12-23 23:45:54 +0000 | <Jadesheit[m]> | <Inst> "I think when the last HF..." <- What parts of the ecosystem specifically? |
| 2022-12-23 23:46:13 +0000 | <monochrom> | libraries, as usual |
| 2022-12-23 23:47:03 +0000 | <monochrom> | there could be more, but libraries are the foundation |
| 2022-12-23 23:47:16 +0000 | <Inst> | have you tried python? It's worth it just to see what best-in-class library is |
| 2022-12-23 23:47:19 +0000 | `2jt | (~jtomas@84.red-88-17-186.dynamicip.rima-tde.net) (Ping timeout: 256 seconds) |
| 2022-12-23 23:47:20 +0000 | <Inst> | erm, ecosystem is |
| 2022-12-23 23:47:40 +0000 | <Inst> | the main drawbacks is that Haskell community tends to be more helpful, and on average, more skilled due to higher average experience |
| 2022-12-23 23:47:50 +0000 | <monochrom> | Unlike the 1970s (much simpler time), people choose languages by just looking at community libraries. |
| 2022-12-23 23:47:58 +0000 | <Inst> | in Py / JS, you'll find people who have difficulty writing a for-loop |
| 2022-12-23 23:48:05 +0000 | <Jadesheit[m]> | haha yeah |
| 2022-12-23 23:48:25 +0000 | <Jadesheit[m]> | Inst: i've worked with it yeah |
| 2022-12-23 23:48:49 +0000 | <Inst> | point of Haskell for me is essentially being able to hang out with Haskellers |
| 2022-12-23 23:49:16 +0000 | <Jadesheit[m]> | what, in your opinion, would be an important library or piece of tooling haskell needs? |
| 2022-12-23 23:50:21 +0000 | cheater_ | (~Username@user/cheater) |
| 2022-12-23 23:50:26 +0000 | <monochrom> | the latest fad, i.e., machine learning |
| 2022-12-23 23:50:34 +0000 | <Inst> | there are tensorflow bindings, no? |
| 2022-12-23 23:50:45 +0000 | <monochrom> | (thank god the other latest fad, blockchain, is already covered) |
| 2022-12-23 23:51:09 +0000 | <Inst> | ML isn't a fad; if you look at how far GPTChat has come |
| 2022-12-23 23:51:11 +0000 | <Jadesheit[m]> | monochrom: something like numpy (numhs?) or something more specific? |
| 2022-12-23 23:51:17 +0000 | <Inst> | numpy is a big hole, afaik |
| 2022-12-23 23:51:21 +0000 | <monochrom> | But more seriously, GUI is still in a very bad state. At least how I feel it. |
| 2022-12-23 23:51:21 +0000 | freeside | (~mengwong@103.252.202.159) |
| 2022-12-23 23:51:25 +0000 | <Inst> | Haskell can't compare to Julia when it comes to numerical computation |
| 2022-12-23 23:51:28 +0000 | <Inst> | yeah, I agree |
| 2022-12-23 23:51:45 +0000 | <Inst> | GUI makes it hard to learn / teach Haskell because people want the endorphin rush of having a GUI they coded |
| 2022-12-23 23:51:51 +0000 | <Jadesheit[m]> | monochrom: Everything is web-based nowadays |
| 2022-12-23 23:52:01 +0000 | <Inst> | I can't even get threepenny-gui to install on Windows |
| 2022-12-23 23:52:02 +0000 | <Inst> | :( |
| 2022-12-23 23:52:30 +0000 | <Jadesheit[m]> | I started hating GUIs, then I started hating CLI/TUI and now I don't write any applications anymore |
| 2022-12-23 23:52:46 +0000 | cheater | (~Username@user/cheater) (Ping timeout: 272 seconds) |
| 2022-12-23 23:52:46 +0000 | cheater_ | cheater |
| 2022-12-23 23:52:55 +0000 | <Jadesheit[m]> | (this isn't a joke, btw) |
| 2022-12-23 23:53:04 +0000 | <Inst> | so you just do scripts / webdesign? |
| 2022-12-23 23:53:09 +0000 | goober | (~goober@90-231-13-185-no3430.tbcn.telia.com) |
| 2022-12-23 23:53:21 +0000 | <monochrom> | When you finally hate computing altogether, that will be enlightenment. |
| 2022-12-23 23:53:46 +0000 | sagax | (~sagax_nb@user/sagax) |
| 2022-12-23 23:53:50 +0000 | <Inst> | Web honestly is probably the best chance Haskell has of growing its userbase |
| 2022-12-23 23:54:04 +0000 | <Jadesheit[m]> | Inst: I exclusively do language intrinsic things lmao |
| 2022-12-23 23:54:10 +0000 | <monochrom> | At least computing in practice. |
| 2022-12-23 23:54:20 +0000 | <Inst> | so, compilers? |
| 2022-12-23 23:54:32 +0000 | <Jadesheit[m]> | not even, no |
| 2022-12-23 23:54:35 +0000 | <Jadesheit[m]> | I just code for the sake of coding |
| 2022-12-23 23:54:51 +0000 | <monochrom> | Well, web is also a fad, just a much more long-running one. |
| 2022-12-23 23:54:51 +0000 | <Jadesheit[m]> | I write functions, doodle around |
| 2022-12-23 23:55:04 +0000 | <Jadesheit[m]> | I boot up ghci and try out stuff |
| 2022-12-23 23:55:15 +0000 | <monochrom> | Let's face it, popularity = fad. Virtually a tautology. |
| 2022-12-23 23:55:16 +0000 | <Jadesheit[m]> | and then I delete my entire projects folder again |
| 2022-12-23 23:55:19 +0000 | <Jadesheit[m]> | it's an endless cycle |
| 2022-12-23 23:55:44 +0000 | <monochrom> | Aww, you don't have to delete them :) |
| 2022-12-23 23:56:07 +0000 | freeside | (~mengwong@103.252.202.159) (Ping timeout: 260 seconds) |
| 2022-12-23 23:56:35 +0000 | <monochrom> | I have a "project" directory and a "study-notes" directory. Inside them are all sorts of subdirectories that are not really different from yours. But I don't delete them. |
| 2022-12-23 23:56:48 +0000 | <Jadesheit[m]> | haha I know, but they are usually "projects" with five or less functions because I lose interest so quickly |
| 2022-12-23 23:57:15 +0000 | <Jadesheit[m]> | I haven't had something I worked on for more than a day in maybe a year? |
| 2022-12-23 23:57:26 +0000 | <Jadesheit[m]> | It just sucks |
| 2022-12-23 23:57:34 +0000 | <Jadesheit[m]> | ¯\_(ツ)_/¯ |
| 2022-12-23 23:57:42 +0000 | <monochrom> | Once in a while, it pays off when I find that something I need today has some unfinished sketch I left 10 years ago. |
| 2022-12-23 23:58:20 +0000 | <Jadesheit[m]> | I talk a lot to people and discuss haskell |
| 2022-12-23 23:58:30 +0000 | zero | zzz |
| 2022-12-23 23:58:39 +0000 | acidjnk | (~acidjnk@p200300d6e7137a614441a736a9b750c4.dip0.t-ipconnect.de) (Ping timeout: 256 seconds) |
| 2022-12-23 23:58:43 +0000 | <Jadesheit[m]> | So I write more code on discord or matrix than in ghci/source files |
| 2022-12-23 23:58:52 +0000 | freeside | (~mengwong@103.252.202.159) |