2022/12/06

2022-12-06 00:00:38 +0100stiell(~stiell@gateway/tor-sasl/stiell) (Ping timeout: 255 seconds)
2022-12-06 00:00:40 +0100wootehfoot(~wootehfoo@user/wootehfoot) (Read error: Connection reset by peer)
2022-12-06 00:01:24 +0100stiell(~stiell@gateway/tor-sasl/stiell)
2022-12-06 00:03:35 +0100srk-(~sorki@user/srk)
2022-12-06 00:05:21 +0100 <moonsheep> mauke, seydar: this is how I parse my input https://paste.tomsmeding.com/8FJuu3eE
2022-12-06 00:05:32 +0100 <moonsheep> basically transpose and chunk
2022-12-06 00:05:42 +0100 <moonsheep> the find functions are just regex
2022-12-06 00:05:51 +0100srk(~sorki@user/srk) (Ping timeout: 252 seconds)
2022-12-06 00:05:53 +0100seydar(~seydar@154-27-113-252.starry-inc.net)
2022-12-06 00:06:14 +0100Lycurgus(~juan@user/Lycurgus) (Ping timeout: 256 seconds)
2022-12-06 00:06:18 +0100srk-srk
2022-12-06 00:06:29 +0100king_gs(~Thunderbi@187.201.204.122) (Ping timeout: 260 seconds)
2022-12-06 00:09:03 +0100bitdex(~bitdex@gateway/tor-sasl/bitdex) (Remote host closed the connection)
2022-12-06 00:09:39 +0100Feuermagier(~Feuermagi@user/feuermagier)
2022-12-06 00:09:40 +0100Tuplanolla(~Tuplanoll@91-159-68-152.elisa-laajakaista.fi) (Quit: Leaving.)
2022-12-06 00:10:09 +0100freeside(~mengwong@103.252.202.193)
2022-12-06 00:10:12 +0100seydar(~seydar@154-27-113-252.starry-inc.net) (Ping timeout: 256 seconds)
2022-12-06 00:10:12 +0100Erutuon(~Erutuon@user/erutuon) (Ping timeout: 256 seconds)
2022-12-06 00:12:41 +0100Feuermagier(~Feuermagi@user/feuermagier) (Client Quit)
2022-12-06 00:14:25 +0100freeside(~mengwong@103.252.202.193) (Ping timeout: 260 seconds)
2022-12-06 00:15:30 +0100bitdex(~bitdex@gateway/tor-sasl/bitdex)
2022-12-06 00:19:05 +0100stiell(~stiell@gateway/tor-sasl/stiell) (Ping timeout: 255 seconds)
2022-12-06 00:20:56 +0100ddellacosta(~ddellacos@89.45.224.153)
2022-12-06 00:21:00 +0100elevenkb(~elevenkb@105.184.125.168) (Quit: Client closed)
2022-12-06 00:21:07 +0100stiell(~stiell@gateway/tor-sasl/stiell)
2022-12-06 00:21:55 +0100zant(~zant@62.214.20.26) (Ping timeout: 256 seconds)
2022-12-06 00:24:01 +0100zant(~zant@62.214.20.26)
2022-12-06 00:25:03 +0100seydar(~seydar@154-27-113-252.starry-inc.net)
2022-12-06 00:27:26 +0100freeside(~mengwong@103.252.202.193)
2022-12-06 00:29:49 +0100zant(~zant@62.214.20.26) (Ping timeout: 260 seconds)
2022-12-06 00:30:13 +0100Unicorn_Princess(~Unicorn_P@user/Unicorn-Princess/x-3540542) (Remote host closed the connection)
2022-12-06 00:31:34 +0100ddellacosta(~ddellacos@89.45.224.153) (Ping timeout: 260 seconds)
2022-12-06 00:32:09 +0100freeside(~mengwong@103.252.202.193) (Ping timeout: 260 seconds)
2022-12-06 00:32:20 +0100srk-(~sorki@user/srk)
2022-12-06 00:34:50 +0100freeside(~mengwong@103.252.202.193)
2022-12-06 00:35:15 +0100merijn(~merijn@c-001-001-017.client.esciencecenter.eduvpn.nl)
2022-12-06 00:35:15 +0100zant(~zant@62.214.20.26)
2022-12-06 00:35:43 +0100freeside_(~mengwong@103.252.202.193)
2022-12-06 00:35:55 +0100srk(~sorki@user/srk) (Ping timeout: 268 seconds)
2022-12-06 00:35:55 +0100srk-srk
2022-12-06 00:37:23 +0100bobbingbob(~dfadsva@2604:3d09:207f:f650::7b3a) (Ping timeout: 252 seconds)
2022-12-06 00:37:28 +0100ddellacosta(~ddellacos@143.244.47.89)
2022-12-06 00:38:21 +0100heinz9(~trace@user/trace) (Remote host closed the connection)
2022-12-06 00:40:11 +0100merijn(~merijn@c-001-001-017.client.esciencecenter.eduvpn.nl) (Ping timeout: 260 seconds)
2022-12-06 00:40:21 +0100bobbingbob(~dfadsva@2604:3d09:207f:f650::7b3a)
2022-12-06 00:40:32 +0100money_(~money@user/polo)
2022-12-06 00:40:34 +0100Erutuon(~Erutuon@user/erutuon)
2022-12-06 00:42:44 +0100seydar(~seydar@154-27-113-252.starry-inc.net) (Ping timeout: 248 seconds)
2022-12-06 00:42:56 +0100fizbin(~fizbin@user/fizbin)
2022-12-06 00:45:26 +0100raym(~ray@user/raym)
2022-12-06 00:46:03 +0100mastarija(~mastarija@2a05:4f46:e03:6000:2a89:666a:1e9:351e) (Quit: WeeChat 3.7.1)
2022-12-06 00:47:39 +0100fizbin(~fizbin@user/fizbin) (Ping timeout: 260 seconds)
2022-12-06 00:48:15 +0100zant(~zant@62.214.20.26) (Ping timeout: 268 seconds)
2022-12-06 00:50:51 +0100zant(~zant@62.214.20.26)
2022-12-06 00:53:33 +0100use-value(~Thunderbi@2a00:23c6:8a03:2f01:6956:303f:1676:5fd5) (Remote host closed the connection)
2022-12-06 00:53:51 +0100use-value(~Thunderbi@2a00:23c6:8a03:2f01:6956:303f:1676:5fd5)
2022-12-06 00:56:28 +0100fizbin(~fizbin@user/fizbin)
2022-12-06 00:57:37 +0100seydar(~seydar@154-27-113-252.starry-inc.net)
2022-12-06 00:58:59 +0100natechan(~nate@98.45.169.16)
2022-12-06 01:10:59 +0100chomwitt(~chomwitt@2a02:587:7a0c:6a00:1ac0:4dff:fedb:a3f1) (Ping timeout: 264 seconds)
2022-12-06 01:12:51 +0100acidjnk(~acidjnk@p200300d6e7137a1979c4b3a1e8b4bdac.dip0.t-ipconnect.de) (Ping timeout: 260 seconds)
2022-12-06 01:13:35 +0100gmg(~user@user/gehmehgeh) (Quit: Leaving)
2022-12-06 01:15:14 +0100tcard(~tcard@2400:4051:5801:7500:cf17:befc:ff82:5303)
2022-12-06 01:17:08 +0100jpds(~jpds@gateway/tor-sasl/jpds) (Ping timeout: 255 seconds)
2022-12-06 01:19:33 +0100jpds(~jpds@gateway/tor-sasl/jpds)
2022-12-06 01:20:31 +0100 <gqplox[m]> hi guys, im back
2022-12-06 01:20:51 +0100 <gqplox[m]> didn't have too much time today but managed to solve, although not very cleanly
2022-12-06 01:20:57 +0100 <gqplox[m]> http://sprunge.us/x41xkb
2022-12-06 01:22:25 +0100CiaoSen(~Jura@p200300c95747e0002a3a4dfffe84dbd5.dip0.t-ipconnect.de) (Ping timeout: 252 seconds)
2022-12-06 01:23:23 +0100rburkholder(~blurb@96.45.2.121)
2022-12-06 01:26:12 +0100moonsheep(~user@user/moonsheep) (ERC 5.4 (IRC client for GNU Emacs 28.2))
2022-12-06 01:27:32 +0100gurkenglas(~gurkengla@p548ac72e.dip0.t-ipconnect.de) (Ping timeout: 248 seconds)
2022-12-06 01:28:03 +0100zeenk(~zeenk@2a02:2f04:a30d:4300::7fe) (Quit: Konversation terminated!)
2022-12-06 01:29:20 +0100 <Axman6> I don't know what the test is, but `filter (any isAlpha)` feels weird to me; why would you care if a string contained just a single alpha character?
2022-12-06 01:29:37 +0100sammelweis(~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10) (Quit: No Ping reply in 180 seconds.)
2022-12-06 01:32:29 +0100sammelweis(~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10)
2022-12-06 01:33:53 +0100king_gs(~Thunderbi@187.201.204.122)
2022-12-06 01:35:05 +0100 <gqplox[m]> i think after transposing all the remaining strings are [, ], whitespcace or lettesr
2022-12-06 01:35:28 +0100 <iqubic> They are.
2022-12-06 01:35:35 +0100 <gqplox[m]> i could have maybe not all elem "[] " perhaps
2022-12-06 01:35:39 +0100Lycurgus(~juan@user/Lycurgus)
2022-12-06 01:35:39 +0100 <gqplox[m]> would have been clearer
2022-12-06 01:36:21 +0100fizbin(~fizbin@user/fizbin) (Ping timeout: 268 seconds)
2022-12-06 01:37:55 +0100JonathanWatson[m(~jjwmatrix@2001:470:69fc:105::2:a544)
2022-12-06 01:46:49 +0100freeside(~mengwong@103.252.202.193) (Ping timeout: 260 seconds)
2022-12-06 01:46:50 +0100freeside_(~mengwong@103.252.202.193) (Ping timeout: 268 seconds)
2022-12-06 01:47:24 +0100king_gs(~Thunderbi@187.201.204.122) (Ping timeout: 260 seconds)
2022-12-06 01:49:30 +0100bobbingbob(~dfadsva@2604:3d09:207f:f650::7b3a) (Ping timeout: 252 seconds)
2022-12-06 01:50:35 +0100bobbingbob(~dfadsva@2604:3d09:207f:f650::7b3a)
2022-12-06 01:50:42 +0100 <EvanR> trying to write a proper validating parsing for AoC input?
2022-12-06 01:53:48 +0100king_gs(~Thunderbi@187.201.204.122)
2022-12-06 01:55:39 +0100perrierjouet(~perrier-j@modemcable048.127-56-74.mc.videotron.ca) (Quit: WeeChat 3.7.1)
2022-12-06 01:57:18 +0100thyriaen(~thyriaen@2a01:aea0:dd4:470d:6245:cbff:fe9f:48b1) (Ping timeout: 256 seconds)
2022-12-06 01:57:21 +0100merijn(~merijn@c-001-001-017.client.esciencecenter.eduvpn.nl)
2022-12-06 01:58:10 +0100xff0x(~xff0x@2405:6580:b080:900:3610:c321:ec1f:485b) (Ping timeout: 252 seconds)
2022-12-06 01:58:52 +0100freeside(~mengwong@103.252.202.193)
2022-12-06 02:02:16 +0100seydar(~seydar@154-27-113-252.starry-inc.net) (Ping timeout: 265 seconds)
2022-12-06 02:03:11 +0100Kaipei(~Kaiepi@108.175.84.104) (Ping timeout: 246 seconds)
2022-12-06 02:03:35 +0100 <dsal> The `iterate` and `!!` thing look pretty suspicious.
2022-12-06 02:05:02 +0100 <dsal> Oh, I see what you're doing. That's not terrible. But you don't need to do it.
2022-12-06 02:05:38 +0100 <dsal> This is a good case of "list isn't the right data structure" though it's not super bad here.
2022-12-06 02:06:27 +0100perrierjouet(~perrier-j@modemcable048.127-56-74.mc.videotron.ca)
2022-12-06 02:06:54 +0100mmhat(~mmh@p200300f1c73b51cbee086bfffe095315.dip0.t-ipconnect.de) (Quit: WeeChat 3.7.1)
2022-12-06 02:07:11 +0100freeside(~mengwong@103.252.202.193) (Ping timeout: 268 seconds)
2022-12-06 02:09:19 +0100 <dsal> gqplox[m]: If you're down with spoilers, megaparsec + IntMap: https://gist.github.com/dustin/637350c9179f8fadc663d5deaa266745
2022-12-06 02:10:15 +0100albet70(~xxx@2400:8902::f03c:92ff:fe60:98d8) (Remote host closed the connection)
2022-12-06 02:10:26 +0100 <dsal> There's a partial function in there just for fun.
2022-12-06 02:13:29 +0100wroathe(~wroathe@207-153-38-140.fttp.usinternet.com)
2022-12-06 02:13:29 +0100wroathe(~wroathe@207-153-38-140.fttp.usinternet.com) (Changing host)
2022-12-06 02:13:29 +0100wroathe(~wroathe@user/wroathe)
2022-12-06 02:13:57 +0100 <iqubic> I used an IntMap String as my state and folded over a list of moves to thread the state through.
2022-12-06 02:13:59 +0100 <dsal> gqplox[m]: Also note that your arguments are backwards here: `apply :: [Move] -> [Crate] -> [Crate]` It's mildly confusing because your state type is `[Crate]` but if you aliased it `type State = [Crate]` then you'd see that you're intending to iterate over a list which comes before the state. Flipping that around, you'd have `apply :: State -> [Move] -> State` whose implementation would be `apply state = foldl f`
2022-12-06 02:14:10 +0100 <iqubic> type Move = (Int, Int, Int)
2022-12-06 02:14:17 +0100 <dsal> At which point, introducing a new name for foldl is probably not helpful. :)
2022-12-06 02:15:12 +0100seydar(~seydar@154-27-113-252.starry-inc.net)
2022-12-06 02:16:16 +0100bobbingbob(~dfadsva@2604:3d09:207f:f650::7b3a) (Ping timeout: 252 seconds)
2022-12-06 02:16:19 +0100 <dsal> `solve f moves crates = map head (apply moves crates)` flipped is `solve f = fmap head . foldl f`
2022-12-06 02:16:22 +0100albet70(~xxx@2400:8902::f03c:92ff:fe60:98d8)
2022-12-06 02:16:39 +0100 <dsal> (something like that -- you might need to include the initial state)
2022-12-06 02:16:39 +0100razetime(~quassel@49.207.203.213)
2022-12-06 02:17:35 +0100 <iqubic> dsal: fold' better
2022-12-06 02:18:03 +0100 <dsal> Sure, foldl is "always wrong" but that's just an unfortunate wart.
2022-12-06 02:18:22 +0100freeside(~mengwong@103.252.202.193)
2022-12-06 02:18:33 +0100 <iqubic> foldl' is more strict and causes less thunks to be built up
2022-12-06 02:19:51 +0100pavonia(~user@user/siracusa) (Read error: Connection reset by peer)
2022-12-06 02:22:23 +0100bobbingbob(~dfadsva@2604:3d09:207f:f650::7b3a)
2022-12-06 02:23:24 +0100freeside_(~mengwong@103.252.202.193)
2022-12-06 02:23:35 +0100king_gs(~Thunderbi@187.201.204.122) (Read error: Connection reset by peer)
2022-12-06 02:24:42 +0100king_gs(~Thunderbi@2806:103e:29:94a4:81e0:429b:22ec:cf13)
2022-12-06 02:26:48 +0100bobbingbob(~dfadsva@2604:3d09:207f:f650::7b3a) (Ping timeout: 255 seconds)
2022-12-06 02:27:57 +0100pavonia(~user@user/siracusa)
2022-12-06 02:31:44 +0100merijn(~merijn@c-001-001-017.client.esciencecenter.eduvpn.nl) (Ping timeout: 260 seconds)
2022-12-06 02:34:20 +0100 <gqplox[m]> oh nice thanks for the feedback
2022-12-06 02:34:39 +0100 <gqplox[m]> yeah I don't know why i wrote the apply for foldl
2022-12-06 02:36:17 +0100segfaultfizzbuzz(~segfaultf@23-93-74-212.fiber.dynamic.sonic.net) (Remote host closed the connection)
2022-12-06 02:37:15 +0100waleee(~waleee@2001:9b0:213:7200:cc36:a556:b1e8:b340) (Ping timeout: 248 seconds)
2022-12-06 02:39:09 +0100waleee(~waleee@h-176-10-137-138.NA.cust.bahnhof.se)
2022-12-06 02:39:56 +0100xff0x(~xff0x@125x103x176x34.ap125.ftth.ucom.ne.jp)
2022-12-06 02:40:13 +0100eggplantade(~Eggplanta@2600:1700:38c5:d800:111a:339b:4372:c307)
2022-12-06 02:41:32 +0100Lycurgus(~juan@user/Lycurgus) (Quit: Exeunt https://tinyurl.com/4m8d4kd5)
2022-12-06 02:42:06 +0100Lycurgus(~juan@user/Lycurgus)
2022-12-06 02:44:54 +0100eggplantade(~Eggplanta@2600:1700:38c5:d800:111a:339b:4372:c307) (Ping timeout: 256 seconds)
2022-12-06 02:46:39 +0100juri_(~juri@84-19-175-179.pool.ovpn.com) (Ping timeout: 268 seconds)
2022-12-06 02:52:04 +0100phma(phma@2001:5b0:210b:fa28:7bf5:3e57:e59:39a9) (Read error: Connection reset by peer)
2022-12-06 02:52:32 +0100phma(phma@2001:5b0:210b:fa28:3019:703:1a42:7f84)
2022-12-06 02:53:26 +0100jpds(~jpds@gateway/tor-sasl/jpds) (Ping timeout: 255 seconds)
2022-12-06 02:55:07 +0100king_gs(~Thunderbi@2806:103e:29:94a4:81e0:429b:22ec:cf13) (Quit: king_gs)
2022-12-06 02:55:14 +0100razetime_(~quassel@49.207.203.213)
2022-12-06 02:55:22 +0100king_gs(~Thunderbi@187.201.204.122)
2022-12-06 02:56:14 +0100mncheckm(~mncheck@193.224.205.254) (Ping timeout: 260 seconds)
2022-12-06 02:56:28 +0100razetime_(~quassel@49.207.203.213) (Client Quit)
2022-12-06 02:56:43 +0100razetime(~quassel@49.207.203.213) (Quit: https://quassel-irc.org - Chat comfortably. Anywhere.)
2022-12-06 03:01:05 +0100jpds(~jpds@gateway/tor-sasl/jpds)
2022-12-06 03:02:17 +0100juri_(~juri@79.140.120.121)
2022-12-06 03:02:39 +0100troydm(~troydm@host-176-37-124-197.b025.la.net.ua)
2022-12-06 03:06:57 +0100 <EvanR> foldl is "always wrong" for list maybe
2022-12-06 03:10:05 +0100Erutuon(~Erutuon@user/erutuon) (Ping timeout: 268 seconds)
2022-12-06 03:10:42 +0100zant(~zant@62.214.20.26) (Ping timeout: 268 seconds)
2022-12-06 03:13:03 +0100ezzieyguywuf(~Unknown@user/ezzieyguywuf)
2022-12-06 03:13:08 +0100money_(~money@user/polo) (Quit: money_)
2022-12-06 03:13:44 +0100opticblast(~Thunderbi@secure-165.caltech.edu) (Ping timeout: 260 seconds)
2022-12-06 03:14:50 +0100king_gs(~Thunderbi@187.201.204.122) (Read error: Connection reset by peer)
2022-12-06 03:16:03 +0100king_gs(~Thunderbi@2806:103e:29:94a4:81e0:429b:22ec:cf13)
2022-12-06 03:23:04 +0100freeside_(~mengwong@103.252.202.193) (Ping timeout: 260 seconds)
2022-12-06 03:23:49 +0100opticblast(~Thunderbi@secure-165.caltech.edu)
2022-12-06 03:24:16 +0100freeside(~mengwong@103.252.202.193) (Ping timeout: 268 seconds)
2022-12-06 03:24:43 +0100FinnElija(~finn_elij@user/finn-elija/x-0085643) (Remote host closed the connection)
2022-12-06 03:26:18 +0100FinnElija(~finn_elij@user/finn-elija/x-0085643)
2022-12-06 03:28:40 +0100werneta(~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 260 seconds)
2022-12-06 03:30:15 +0100werneta(~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net)
2022-12-06 03:32:39 +0100sammelweis(~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10) (Ping timeout: 252 seconds)
2022-12-06 03:32:54 +0100sammelweis(~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10)
2022-12-06 03:35:12 +0100freeside(~mengwong@103.252.202.193)
2022-12-06 03:38:49 +0100machinedgod(~machinedg@d198-53-218-113.abhsia.telus.net) (Ping timeout: 252 seconds)
2022-12-06 03:39:16 +0100freeside(~mengwong@103.252.202.193) (Ping timeout: 248 seconds)
2022-12-06 03:39:55 +0100[itchyjunk](~itchyjunk@user/itchyjunk/x-7353470) (Ping timeout: 252 seconds)
2022-12-06 03:41:23 +0100sammelweis(~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10) (Ping timeout: 256 seconds)
2022-12-06 03:43:03 +0100sammelweis(~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10)
2022-12-06 03:43:38 +0100[itchyjunk](~itchyjunk@user/itchyjunk/x-7353470)
2022-12-06 03:45:19 +0100 <albet70> let's assume blist contain alist, is there a function can get the position of alist in blist?
2022-12-06 03:45:36 +0100merijn(~merijn@c-001-001-017.client.esciencecenter.eduvpn.nl)
2022-12-06 03:46:07 +0100 <albet70> f [3..6] [0..9] == 3
2022-12-06 03:49:01 +0100 <EvanR> indexOf [3..6] (tails [0..9])
2022-12-06 03:49:18 +0100 <EvanR> not super efficient
2022-12-06 03:49:31 +0100 <jackdk> elegant, though. I was gonna say go look up Boyer-Moore or something
2022-12-06 03:50:28 +0100merijn(~merijn@c-001-001-017.client.esciencecenter.eduvpn.nl) (Ping timeout: 248 seconds)
2022-12-06 03:50:46 +0100nattiestnate(~nate@202.138.250.37) (Quit: WeeChat 3.7.1)
2022-12-06 03:51:06 +0100aeroplane(~user@user/aeroplane)
2022-12-06 03:53:47 +0100 <albet70> where is indexOf from?
2022-12-06 03:54:42 +0100 <EvanR> I don't think it's anywhere, I've just seen it defined a lot
2022-12-06 03:54:59 +0100king_gs(~Thunderbi@2806:103e:29:94a4:81e0:429b:22ec:cf13) (Quit: king_gs)
2022-12-06 03:55:15 +0100 <albet70> @hoogle indexOf
2022-12-06 03:55:15 +0100 <lambdabot> Data.TCache.IndexQuery indexOf :: (Queriable reg a) => (reg -> a) -> STM [(a, [DBRef reg])]
2022-12-06 03:55:15 +0100 <lambdabot> Control.CanAquire indexOf :: HasIndex t i => t -> i
2022-12-06 03:55:15 +0100 <lambdabot> Numeric.LinearAlgebra type family IndexOf (c :: * -> *)
2022-12-06 03:55:35 +0100 <ephemient> they more likely mean https://hackage.haskell.org/package/base/docs/Data-List.html#v:elemIndex
2022-12-06 03:55:45 +0100 <EvanR> one of those "this list operation shell not be implemented because it's the wrong data structure" functions
2022-12-06 03:56:02 +0100 <EvanR> damn it exists
2022-12-06 03:56:13 +0100 <[Leary]> > (\xs ys -> findIndex (xs `isPrefixOf`) (tails ys)) [3..6] [0..9]
2022-12-06 03:56:15 +0100 <lambdabot> Just 3
2022-12-06 03:56:30 +0100 <[Leary]> The question is probably wrong though.
2022-12-06 03:56:39 +0100 <EvanR> lol
2022-12-06 03:57:21 +0100 <EvanR> @hoogle Eq a => a -> [a] -> Maybe Int
2022-12-06 03:57:21 +0100 <lambdabot> Data.List elemIndex :: Eq a => a -> [a] -> Maybe Int
2022-12-06 03:57:21 +0100 <lambdabot> GHC.OldList elemIndex :: Eq a => a -> [a] -> Maybe Int
2022-12-06 03:57:21 +0100 <lambdabot> Data.List.Utils elemRIndex :: Eq a => a -> [a] -> Maybe Int
2022-12-06 03:57:25 +0100 <ephemient> https://hackage.haskell.org/package/KMP looks like a pretty simple way to get faster subsequence matching
2022-12-06 03:58:26 +0100instantaphex(~jb@c-73-171-252-84.hsd1.fl.comcast.net)
2022-12-06 04:00:25 +0100freeside(~mengwong@103.252.202.193)
2022-12-06 04:00:26 +0100freeside_(~mengwong@103.252.202.193)
2022-12-06 04:00:31 +0100 <jackdk> `indexOf x xs = xs ^? traversed . ifiltered (const (== x)) . asIndex`, maybe
2022-12-06 04:01:26 +0100Lycurgus(~juan@user/Lycurgus) (Quit: Exeunt https://tinyurl.com/4m8d4kd5)
2022-12-06 04:01:52 +0100notzmv(~zmv@user/notzmv)
2022-12-06 04:02:20 +0100eggplantade(~Eggplanta@2600:1700:38c5:d800:111a:339b:4372:c307)
2022-12-06 04:02:53 +0100 <albet70> is hoogle down? I got 502 bad gateway
2022-12-06 04:03:14 +0100 <iqubic> Yes. Hoogle is down
2022-12-06 04:03:16 +0100 <albet70> @hoogle findIndex
2022-12-06 04:03:17 +0100 <lambdabot> Data.List findIndex :: (a -> Bool) -> [a] -> Maybe Int
2022-12-06 04:03:17 +0100 <lambdabot> GHC.OldList findIndex :: (a -> Bool) -> [a] -> Maybe Int
2022-12-06 04:03:17 +0100 <lambdabot> Data.ByteString findIndex :: (Word8 -> Bool) -> ByteString -> Maybe Int
2022-12-06 04:05:25 +0100freeside_(~mengwong@103.252.202.193) (Ping timeout: 260 seconds)
2022-12-06 04:05:25 +0100freeside(~mengwong@103.252.202.193) (Ping timeout: 260 seconds)
2022-12-06 04:09:14 +0100iqubic(~avi@2601:602:9502:c70:5424:6247:46f4:3180) (Remote host closed the connection)
2022-12-06 04:09:19 +0100 <EvanR> getDown :: Down Hoogle -> Hoogle
2022-12-06 04:09:40 +0100iqubic(~avi@2601:602:9502:c70:e046:e69e:de6e:24b2)
2022-12-06 04:10:06 +0100inkbottle[m](~inkbottle@2001:470:69fc:105::2ff5)
2022-12-06 04:18:05 +0100 <seydar> am I a bad person for using Debug.Trace?
2022-12-06 04:18:26 +0100 <monochrom> depends on using it for what
2022-12-06 04:18:30 +0100freeside(~mengwong@103.252.202.193)
2022-12-06 04:19:44 +0100 <EvanR> I usually want to be more bad, but the burden to go put an import Debug.Trace means I use it less
2022-12-06 04:19:47 +0100 <monochrom> I use money, eat meat, say the f word sometimes, and use Debug.Trace. Am I a bad person?
2022-12-06 04:19:48 +0100wroathe(~wroathe@user/wroathe) (Ping timeout: 248 seconds)
2022-12-06 04:20:07 +0100freeside_(~mengwong@103.252.202.193)
2022-12-06 04:20:13 +0100 <monochrom> I also invest in capitalistic companies.
2022-12-06 04:20:51 +0100 <EvanR> debugging haskell in general is so dicey I want every non-debugging technique there is to avoid it
2022-12-06 04:21:17 +0100 <seydar> I have started Debug.Trace, LLC. I will not disclose what I do with the proceeds. Donations can be made at the following...
2022-12-06 04:21:29 +0100 <monochrom> haha
2022-12-06 04:21:30 +0100 <seydar> I have an infinite loop that is only discovered at runtime
2022-12-06 04:21:49 +0100 <monochrom> That's normal.
2022-12-06 04:22:10 +0100 <seydar> i wish haskell debugging upon my enemies
2022-12-06 04:22:21 +0100 <seydar> i am struggling hard with AoC #5
2022-12-06 04:22:49 +0100 <EvanR> just like partial functions aren't partial if you never give bad inputs, trace is a pure function if you don't care about the stray outputs
2022-12-06 04:22:55 +0100 <monochrom> Perhaps s/debugging // >:)
2022-12-06 04:23:43 +0100 <albet70> > let d=[0..9]; c=[3..6] in filter (> 0) $ fmap (\x -> if (c isPrefixOf (snd x)) then (fst x) else -1) $ zip [0..(length d)] $ tails d [3]
2022-12-06 04:23:44 +0100 <lambdabot> error:
2022-12-06 04:23:44 +0100 <lambdabot> • Couldn't match expected type ‘([a0] -> [a0] -> Bool)
2022-12-06 04:23:44 +0100 <lambdabot> -> b0 -> Bool’
2022-12-06 04:23:47 +0100 <monochrom> I state the dual of that. Total functions aren't total until you get rid of bugs.
2022-12-06 04:24:38 +0100 <EvanR> all functions are correct, they just may have the wrong type signature xD
2022-12-06 04:24:47 +0100 <albet70> let d=[0..9]; c=[3..6] in filter (> 0) $ fmap (\x -> if (c isPrefixOf (snd x)) then (fst x) else -1) $ zip [0..(length d)] $ tails d [3]
2022-12-06 04:25:25 +0100 <EvanR> on Day 5 I am skeptically curious why you need the sublist index of something
2022-12-06 04:25:25 +0100 <monochrom> Be a cup-is-half-full person and rejoice that your function works for some input at all. >:)
2022-12-06 04:25:26 +0100razetime(~quassel@49.207.203.213)
2022-12-06 04:26:00 +0100 <EvanR> oh that's not the same person
2022-12-06 04:26:49 +0100 <monochrom> So basically yesterday's lesson is "use array, not list", and today's is "use list, not array"? :)
2022-12-06 04:27:48 +0100 <dolio> Seems like there's a meta lesson that a lot of people fail to get.
2022-12-06 04:28:17 +0100 <monochrom> Would that be "don't use yesterday's approach"? :)
2022-12-06 04:29:04 +0100 <dolio> Think about what is best for the particular situation, instead of assuming one thing is always the best.
2022-12-06 04:29:26 +0100 <seydar> my shame: https://paste.tomsmeding.com/brCoU4aG
2022-12-06 04:29:50 +0100 <monochrom> I see that failure all the time when I was a TA for a 1st-year calculus course.
2022-12-06 04:30:44 +0100 <ephemient> seydar, https://github.com/ephemient/aoc2019/commit/1fb90418c89d07463f1031233b205ed0884d074c I have a dumb hack to be able to turn trace output on and off :)
2022-12-06 04:31:33 +0100 <monochrom> It appears as though students differentiated the function in question, set it to 0, solve. Before even reading the rest of the question (that went on to ask anything except finding critical points).
2022-12-06 04:31:59 +0100wroathe(~wroathe@207-153-38-140.fttp.usinternet.com)
2022-12-06 04:31:59 +0100wroathe(~wroathe@207-153-38-140.fttp.usinternet.com) (Changing host)
2022-12-06 04:31:59 +0100wroathe(~wroathe@user/wroathe)
2022-12-06 04:33:41 +0100 <monochrom> Cynically, generally, humans just want to avoid thinking about what's best for the question, or even reading the question at all. Wishing that there is only one thing to learn and do.
2022-12-06 04:33:47 +0100Xeroine_(~Xeroine@user/xeroine) (Ping timeout: 264 seconds)
2022-12-06 04:33:55 +0100finn_elija(~finn_elij@user/finn-elija/x-0085643)
2022-12-06 04:33:55 +0100FinnElija(~finn_elij@user/finn-elija/x-0085643) (Killed (NickServ (Forcing logout FinnElija -> finn_elija)))
2022-12-06 04:33:55 +0100finn_elijaFinnElija
2022-12-06 04:34:00 +0100aeroplane(~user@user/aeroplane) (Ping timeout: 260 seconds)
2022-12-06 04:34:28 +0100 <dolio> Yeah.
2022-12-06 04:34:53 +0100 <seydar> ephemient: thank you thank you
2022-12-06 04:37:01 +0100Xeroine(~Xeroine@user/xeroine)
2022-12-06 04:38:13 +0100sammelweis(~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10) (Ping timeout: 252 seconds)
2022-12-06 04:38:26 +0100jero98772(~jero98772@2800:484:1d80:d8ce:efcc:cbb3:7f2a:6dff) (Remote host closed the connection)
2022-12-06 04:38:56 +0100sammelweis(~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10)
2022-12-06 04:39:12 +0100 <iqubic> For those who care, Hoogle is back online
2022-12-06 04:40:36 +0100 <EvanR> do the AoC puzzle first, read the question after
2022-12-06 04:40:45 +0100 <EvanR> faster that way
2022-12-06 04:42:30 +0100 <seydar> turns out I had a type error. I still have an infinite loop, but I no longer have my type errors
2022-12-06 04:44:35 +0100 <EvanR> I'd much rather have type errors than mysterious infinite loops
2022-12-06 04:46:10 +0100td_(~td@83.135.9.25) (Ping timeout: 256 seconds)
2022-12-06 04:46:35 +0100jao(~jao@cpc103048-sgyl39-2-0-cust502.18-2.cable.virginm.net) (Ping timeout: 246 seconds)
2022-12-06 04:48:00 +0100td_(~td@83.135.9.33)
2022-12-06 04:48:15 +0100 <seydar> i'll be honest
2022-12-06 04:48:18 +0100 <seydar> this whole lazy thing
2022-12-06 04:48:41 +0100 <ephemient> what's the law that says "if your inferred type is `a' you might have an infinite loop"
2022-12-06 04:48:46 +0100 <seydar> making it kinda hard to reason about why my code is littered with trace statements, yet I'm not getting any output
2022-12-06 04:49:04 +0100 <seydar> wondering if maybe i should've been a poet
2022-12-06 04:50:47 +0100wroathe(~wroathe@user/wroathe) (Ping timeout: 255 seconds)
2022-12-06 04:51:16 +0100[itchyjunk](~itchyjunk@user/itchyjunk/x-7353470) (Remote host closed the connection)
2022-12-06 04:52:58 +0100Guest40(~Guest40@50-247-81-49-static.hfc.comcastbusiness.net)
2022-12-06 04:56:36 +0100kritzefitz(~kritzefit@debian/kritzefitz) (Ping timeout: 248 seconds)
2022-12-06 05:00:47 +0100img(~img@user/img) (Quit: ZNC 1.8.2 - https://znc.in)
2022-12-06 05:01:06 +0100 <seydar> ah. it is entirely possible I forgot to set a base case in a recursive function that occurs on like line 5 of my code
2022-12-06 05:02:28 +0100Guest40(~Guest40@50-247-81-49-static.hfc.comcastbusiness.net) (Ping timeout: 260 seconds)
2022-12-06 05:07:20 +0100crazazy(~user@130.89.173.127) (Read error: Connection reset by peer)
2022-12-06 05:09:40 +0100tabaqui(~root@88.231.62.215)
2022-12-06 05:12:11 +0100L29Ah(~L29Ah@wikipedia/L29Ah) (Ping timeout: 264 seconds)
2022-12-06 05:15:28 +0100causal(~user@50.35.85.7)
2022-12-06 05:15:59 +0100merijn(~merijn@c-001-001-017.client.esciencecenter.eduvpn.nl)
2022-12-06 05:16:39 +0100L29Ah(~L29Ah@wikipedia/L29Ah)
2022-12-06 05:18:13 +0100img(~img@user/img)
2022-12-06 05:19:37 +0100L29Ah(~L29Ah@wikipedia/L29Ah) (Read error: Connection reset by peer)
2022-12-06 05:20:08 +0100L29Ah(~L29Ah@wikipedia/L29Ah)
2022-12-06 05:33:35 +0100seydar(~seydar@154-27-113-252.starry-inc.net) (Quit: leaving)
2022-12-06 05:39:26 +0100caryhartline(~caryhartl@2600:1700:2d0:8d30:b403:2f20:d663:1bea) (Quit: caryhartline)
2022-12-06 05:40:10 +0100fizbin(~fizbin@user/fizbin)
2022-12-06 05:46:19 +0100kritzefitz(~kritzefit@debian/kritzefitz)
2022-12-06 05:51:02 +0100merijn(~merijn@c-001-001-017.client.esciencecenter.eduvpn.nl) (Ping timeout: 268 seconds)
2022-12-06 05:51:02 +0100ddellacosta(~ddellacos@143.244.47.89) (Ping timeout: 268 seconds)
2022-12-06 05:53:32 +0100use-value(~Thunderbi@2a00:23c6:8a03:2f01:6956:303f:1676:5fd5) (Remote host closed the connection)
2022-12-06 05:53:52 +0100use-value(~Thunderbi@2a00:23c6:8a03:2f01:6956:303f:1676:5fd5)
2022-12-06 06:00:04 +0100waleee(~waleee@h-176-10-137-138.NA.cust.bahnhof.se) (Ping timeout: 265 seconds)
2022-12-06 06:05:40 +0100instantaphex(~jb@c-73-171-252-84.hsd1.fl.comcast.net) (Ping timeout: 252 seconds)
2022-12-06 06:08:54 +0100jargon(~jargon@184.101.177.18) (Remote host closed the connection)
2022-12-06 06:13:21 +0100sammelweis(~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10) (Quit: No Ping reply in 180 seconds.)
2022-12-06 06:15:37 +0100sammelweis(~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10)
2022-12-06 06:17:11 +0100instantaphex(~jb@c-73-171-252-84.hsd1.fl.comcast.net)
2022-12-06 06:21:41 +0100instantaphex(~jb@c-73-171-252-84.hsd1.fl.comcast.net) (Ping timeout: 255 seconds)
2022-12-06 06:24:02 +0100wroathe(~wroathe@207-153-38-140.fttp.usinternet.com)
2022-12-06 06:24:02 +0100wroathe(~wroathe@207-153-38-140.fttp.usinternet.com) (Changing host)
2022-12-06 06:24:02 +0100wroathe(~wroathe@user/wroathe)
2022-12-06 06:24:31 +0100 <iqubic> Was there someone in here who had a lensy way of doing firstIndex?
2022-12-06 06:26:31 +0100mimmy(~mimmy@159.203.19.37) (Quit: ZNC 1.9.x-git-187-32d4a4d5 - https://znc.in)
2022-12-06 06:26:47 +0100mimmy(~mimmy@2604:a880:cad:d0::3e:1001)
2022-12-06 06:27:11 +0100bitdex(~bitdex@gateway/tor-sasl/bitdex) (Ping timeout: 255 seconds)
2022-12-06 06:28:02 +0100fizbin(~fizbin@user/fizbin) (Ping timeout: 268 seconds)
2022-12-06 06:31:32 +0100 <iqubic> I can't seem to find that in the logs.
2022-12-06 06:32:13 +0100 <jackdk> 1:00 PM <jackdk> `indexOf x xs = xs ^? traversed . ifiltered (const (== x)) . asIndex`, maybe
2022-12-06 06:32:21 +0100 <iqubic> Yes. That. Thanks.
2022-12-06 06:32:30 +0100 <jackdk> I think you can use `folded` and `filtered` instead of `ifiltered`
2022-12-06 06:32:42 +0100 <jackdk> `folded` instead of `traversed`, that is
2022-12-06 06:32:46 +0100 <iqubic> I think so.
2022-12-06 06:33:03 +0100 <iqubic> Traversed is only needed if you want to set multiple things.
2022-12-06 06:33:41 +0100 <EvanR> another instance of getting the name wrong = powerless (at searching for it) xD
2022-12-06 06:33:47 +0100bitdex(~bitdex@gateway/tor-sasl/bitdex)
2022-12-06 06:36:12 +0100chomwitt(~chomwitt@2a02:587:7a0c:6a00:1ac0:4dff:fedb:a3f1)
2022-12-06 06:39:51 +0100mimmy(~mimmy@2604:a880:cad:d0::3e:1001) (Quit: ZNC 1.9.x-git-187-32d4a4d5 - https://znc.in)
2022-12-06 06:40:07 +0100mimmy(~mimmy@159.203.19.37)
2022-12-06 06:41:54 +0100 <iqubic> jackdk: You can also replace (^?) with (^..) to get the indicies of all matches as a [Int]
2022-12-06 06:42:11 +0100 <jackdk> iqubic: yes, that's a cool trick.
2022-12-06 06:42:26 +0100 <iqubic> And yes, it will return [] for no matches.
2022-12-06 06:42:30 +0100 <iqubic> indexOf :: (Foldable f) => (a -> Bool) -> f a -> [Int]
2022-12-06 06:42:34 +0100 <iqubic> indexOf p xs = xs ^.. folded . ifiltered (const p) . asIndex
2022-12-06 06:42:39 +0100hrberg(~quassel@171.79-160-161.customer.lyse.net) (Quit: https://quassel-irc.org - Chat comfortably. Anywhere.)
2022-12-06 06:42:59 +0100hrberg(~quassel@171.79-160-161.customer.lyse.net)
2022-12-06 06:44:41 +0100Erutuon(~Erutuon@user/erutuon)
2022-12-06 06:47:09 +0100wroathe(~wroathe@user/wroathe) (Ping timeout: 268 seconds)
2022-12-06 07:06:42 +0100razetime(~quassel@49.207.203.213) (Ping timeout: 256 seconds)
2022-12-06 07:08:25 +0100 <jackdk> iqubic: s/ifiltered (const p)/filtered p/
2022-12-06 07:08:39 +0100 <iqubic> Oh? Does that work?
2022-12-06 07:08:53 +0100Kaipei(~Kaiepi@108.175.84.104)
2022-12-06 07:09:35 +0100 <jackdk> Beware of bugs in the above suggestion; I have only typechecked it, not tried it.
2022-12-06 07:10:02 +0100 <iqubic> I'll try it now.
2022-12-06 07:10:55 +0100 <iqubic> That seems to work for me.
2022-12-06 07:11:34 +0100 <iqubic> My test for this was "I used that function in today's Advent of Code solution"
2022-12-06 07:12:59 +0100 <iqubic> Thnks jackdk
2022-12-06 07:16:13 +0100merijn(~merijn@c-001-001-017.client.esciencecenter.eduvpn.nl)
2022-12-06 07:18:15 +0100michalz(~michalz@185.246.204.72)
2022-12-06 07:21:10 +0100 <mauke> :t fmap (+ 4) . findIndex ((== 4) . length . nub . take 4) . tails
2022-12-06 07:21:11 +0100 <lambdabot> Eq a => [a] -> Maybe Int
2022-12-06 07:23:07 +0100 <dsal> Oh, heh, I was comparing it for some reason.
2022-12-06 07:27:14 +0100bgs(~bgs@212-85-160-171.dynamic.telemach.net)
2022-12-06 07:31:44 +0100biberu\(~biberu@user/biberu)
2022-12-06 07:34:03 +0100 <mauke> alternatively: /(.{4})(?(?{ !all_distinct $1 })(?!))/ and say $+[1];
2022-12-06 07:35:36 +0100biberu(~biberu@user/biberu) (Ping timeout: 256 seconds)
2022-12-06 07:35:36 +0100biberu\biberu
2022-12-06 07:35:36 +0100 <mauke> where sub all_distinct($chars) { my $set = ''; vec($set, $_, 1)++ and return 0 for unpack 'C*', $chars; 1 }
2022-12-06 07:38:26 +0100freeside_(~mengwong@103.252.202.193) (Ping timeout: 256 seconds)
2022-12-06 07:38:57 +0100freeside(~mengwong@103.252.202.193) (Ping timeout: 268 seconds)
2022-12-06 07:39:36 +0100takuan(~takuan@178-116-218-225.access.telenet.be)
2022-12-06 07:42:14 +0100 <iqubic> mauke: This is #haskell. I'm not sure if you are in the right channel
2022-12-06 07:43:26 +0100 <_________> iqubic: above you have haskell solution
2022-12-06 07:48:18 +0100 <mauke> I'm sure the code could be desugared to haskell
2022-12-06 07:50:23 +0100merijn(~merijn@c-001-001-017.client.esciencecenter.eduvpn.nl) (Ping timeout: 246 seconds)
2022-12-06 07:50:27 +0100king_gs(~Thunderbi@2806:103e:29:94a4:81e0:429b:22ec:cf13)
2022-12-06 07:52:03 +0100 <yushyin> iqubic: no this is #aoc-spoilers
2022-12-06 07:55:44 +0100 <mauke> besides, 'where' is totally haskell syntax, right?
2022-12-06 07:57:46 +0100aliosablack(~chomwitt@2a02:587:7a0c:6a00:1ac0:4dff:fedb:a3f1)
2022-12-06 07:58:07 +0100jakalx(~jakalx@base.jakalx.net) (Error from remote client)
2022-12-06 07:58:23 +0100chomwitt(~chomwitt@2a02:587:7a0c:6a00:1ac0:4dff:fedb:a3f1) (Ping timeout: 264 seconds)
2022-12-06 07:58:41 +0100 <albet70> this is my splitOn implement, https://paste.tomsmeding.com/jQ7AnlFx any suggestion?
2022-12-06 07:59:55 +0100 <dsal> albet70: lots of passes. You definitely don't need `[0..(length sourceList)]` Just `[0..]`
2022-12-06 08:00:18 +0100 <dsal> Type annotations are a good idea on every toplevel binding.
2022-12-06 08:01:15 +0100Chai-T-Rex(~ChaiTRex@user/chaitrex) (Remote host closed the connection)
2022-12-06 08:01:48 +0100Chai-T-Rex(~ChaiTRex@user/chaitrex)
2022-12-06 08:03:28 +0100 <mauke> > zip [0 ..] "hello"
2022-12-06 08:03:29 +0100 <lambdabot> [(0,'h'),(1,'e'),(2,'l'),(3,'l'),(4,'o')]
2022-12-06 08:03:54 +0100 <int-e> > let (xs, ys) = span (not . isPrefixOf "ba") (init (tails "abcbabcd")) in (map head xs, map head ys)
2022-12-06 08:03:55 +0100 <lambdabot> ("abc","babcd")
2022-12-06 08:04:20 +0100raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net)
2022-12-06 08:04:53 +0100 <glguy> I can't imagine it's news to anyone here, but if you're doing adventofcode.com in Haskell this year, we've got a Haskell-oriented leaderboard in the /topic you can join
2022-12-06 08:05:09 +0100 <albet70> dsal , ok, [0..] it is
2022-12-06 08:05:59 +0100 <int-e> the whole indexing feels nonidiomatic
2022-12-06 08:06:05 +0100 <dsal> You're doing a lot of passes through your lists overall, though. Seems like something you could do in a single pass.
2022-12-06 08:06:36 +0100 <sayola> i've done today's aoc just now. i'm scrolling up and find mauke having the exact same solution. lol
2022-12-06 08:06:44 +0100 <mauke> what's the point of leaderboards with aoc? isn't it just about who can wake up at 6:00 the fastest?
2022-12-06 08:07:04 +0100 <glguy> mauke: finding other people's solutions, seeing who's keeping up, etc
2022-12-06 08:07:05 +0100 <mauke> I knew regex was the obvious solution
2022-12-06 08:08:01 +0100 <sayola> i've done unga bungu parsing with lines/groupby etc for past challenges lol
2022-12-06 08:08:31 +0100 <sayola> parser combinators always break in my hands
2022-12-06 08:09:16 +0100 <dsal> Parser combinators are fun. Today's parser was `readFile` which was a little bit of a disappointment.
2022-12-06 08:09:38 +0100 <mauke> `interact` or bust
2022-12-06 08:09:47 +0100stiell(~stiell@gateway/tor-sasl/stiell) (Ping timeout: 255 seconds)
2022-12-06 08:10:12 +0100 <sayola> copy&paste into ghci or bust :>
2022-12-06 08:10:35 +0100 <shachaf> whoa, it's mauke
2022-12-06 08:10:45 +0100 <mauke> glguy: how do I see other people's solutions?
2022-12-06 08:11:08 +0100 <sayola> search github?
2022-12-06 08:11:11 +0100 <int-e> mauke: Well, you still have to parse the problem and turn it into code even if you're awake when it starts. And you can get really serious about automation if you're so inclined. And I rather suspect that for two days, the top scores for part 1 was by people who actually managed to mis-timestamp submitted solutions? Not sure, impossible to prove, but the times were not plausible at all,...
2022-12-06 08:11:17 +0100 <int-e> ...especially when taking part 2 into account as well.
2022-12-06 08:11:32 +0100 <mauke> shachaf: hi!
2022-12-06 08:12:12 +0100 <glguy> int-e: I'd heard that the 10-second time for the early problem was due to using one of the Ai program generators
2022-12-06 08:12:31 +0100 <sayola> ^
2022-12-06 08:12:40 +0100 <int-e> glguy: Hmm, but why would the same thing fail so miserably on part 2? But I guess you can get lucky.
2022-12-06 08:12:44 +0100 <sayola> new chatgpt is abused for this, so i heard
2022-12-06 08:13:03 +0100 <glguy> int-e: the stuff is amazing but not magic, so I think it got lucky in the generated program
2022-12-06 08:13:29 +0100 <glguy> but I really don't know
2022-12-06 08:13:50 +0100jakalx(~jakalx@base.jakalx.net)
2022-12-06 08:14:12 +0100 <albet70> > let (xs, ys) = span (not . isPrefixOf "/a/b") (init (tails "this is a test /ab/c/a/b /c /a/b absurd")) in (map head xs, map head ys)
2022-12-06 08:14:14 +0100 <lambdabot> ("this is a test /ab/c","/a/b /c /a/b absurd")
2022-12-06 08:15:10 +0100 <albet70> the second part isn't split
2022-12-06 08:15:58 +0100 <int-e> albet70: I know, but it's a viable start
2022-12-06 08:17:16 +0100 <glguy> My parabox is easier to use now that is has a level select menu, if anyone wants to play: https://asciinema.org/a/7h6ROJTAWtMzBoaYCsPMqfrpM https://glguy.net/gitea/glguy/parabox
2022-12-06 08:18:35 +0100 <int-e> oh, span . (not .) = break, I keep forgetting about `break`
2022-12-06 08:20:35 +0100 <sayola> sometimes i look at haskell code and wonder if we just code golf for fun here
2022-12-06 08:20:56 +0100troydm(~troydm@host-176-37-124-197.b025.la.net.ua) (Ping timeout: 256 seconds)
2022-12-06 08:21:04 +0100 <c_wraith> sometimes, yes
2022-12-06 08:21:20 +0100 <c_wraith> But that's more of an IRC thing than a Haskell thing, I think
2022-12-06 08:21:23 +0100 <mauke> sometimes we @. unpl . pl undo
2022-12-06 08:25:54 +0100merijn(~merijn@c-001-001-017.client.esciencecenter.eduvpn.nl)
2022-12-06 08:30:45 +0100merijn(~merijn@c-001-001-017.client.esciencecenter.eduvpn.nl) (Ping timeout: 268 seconds)
2022-12-06 08:32:01 +0100kenran(~user@user/kenran)
2022-12-06 08:32:08 +0100V(~v@ircpuzzles/2022/april/winner/V) (Remote host closed the connection)
2022-12-06 08:34:22 +0100kenran(~user@user/kenran) (Remote host closed the connection)
2022-12-06 08:35:30 +0100 <iqubic> glguy: What library are you using to create the graphics in your Parabox?
2022-12-06 08:38:21 +0100coot(~coot@2a02:a310:e241:1b00:ec1a:e9df:79ac:66ba)
2022-12-06 08:39:34 +0100bgs(~bgs@212-85-160-171.dynamic.telemach.net) (Remote host closed the connection)
2022-12-06 08:40:13 +0100Sgeo(~Sgeo@user/sgeo) (Read error: Connection reset by peer)
2022-12-06 08:40:52 +0100king_gs(~Thunderbi@2806:103e:29:94a4:81e0:429b:22ec:cf13) (Remote host closed the connection)
2022-12-06 08:41:10 +0100king_gs(~Thunderbi@2806:103e:29:94a4:81e0:429b:22ec:cf13)
2022-12-06 08:42:28 +0100jonathanx(~jonathan@h-178-174-176-109.A357.priv.bahnhof.se) (Ping timeout: 268 seconds)
2022-12-06 08:43:54 +0100 <int-e> iqubic: *checks .cabal file* vty
2022-12-06 08:44:24 +0100merijn(~merijn@c-001-001-017.client.esciencecenter.eduvpn.nl)
2022-12-06 08:45:05 +0100fserucas(~fserucas@212.157.222.3)
2022-12-06 08:45:56 +0100jonathanx(~jonathan@c-5eea67cc-74736162.cust.telenor.se)
2022-12-06 08:47:26 +0100fserucas_(~fserucas@212.157.222.2)
2022-12-06 08:47:35 +0100azimut(~azimut@gateway/tor-sasl/azimut) (Ping timeout: 255 seconds)
2022-12-06 08:49:25 +0100comerijn(~merijn@86-86-29-250.fixed.kpn.net)
2022-12-06 08:49:42 +0100merijn(~merijn@c-001-001-017.client.esciencecenter.eduvpn.nl) (Ping timeout: 252 seconds)
2022-12-06 08:50:53 +0100jonathanx(~jonathan@c-5eea67cc-74736162.cust.telenor.se) (Read error: No route to host)
2022-12-06 08:52:41 +0100fserucas(~fserucas@212.157.222.3) (Ping timeout: 256 seconds)
2022-12-06 08:52:41 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
2022-12-06 08:55:09 +0100trev(~trev@user/trev)
2022-12-06 08:55:11 +0100 <glguy> The version on steam is just better than my clone, but I like making console apps
2022-12-06 09:02:14 +0100shriekingnoise(~shrieking@186.137.167.202) (Quit: Quit)
2022-12-06 09:03:12 +0100Scraeling(~Scraeling@user/scraeling)
2022-12-06 09:11:03 +0100coot(~coot@2a02:a310:e241:1b00:ec1a:e9df:79ac:66ba) (Quit: coot)
2022-12-06 09:11:33 +0100mmhat(~mmh@p200300f1c73b51cbee086bfffe095315.dip0.t-ipconnect.de)
2022-12-06 09:11:58 +0100kenaryn(~aurele@cre71-h03-89-88-44-27.dsl.sta.abo.bbox.fr)
2022-12-06 09:19:28 +0100sympt(~sympt@user/sympt) (Ping timeout: 268 seconds)
2022-12-06 09:25:23 +0100king_gs(~Thunderbi@2806:103e:29:94a4:81e0:429b:22ec:cf13) (Ping timeout: 264 seconds)
2022-12-06 09:25:32 +0100acidjnk(~acidjnk@p200300d6e7137a1979c4b3a1e8b4bdac.dip0.t-ipconnect.de)
2022-12-06 09:26:27 +0100fserucas__(~fserucas@212.157.222.3)
2022-12-06 09:28:56 +0100fserucas_(~fserucas@212.157.222.2) (Ping timeout: 256 seconds)
2022-12-06 09:30:00 +0100coot(~coot@2a02:a310:e241:1b00:ec1a:e9df:79ac:66ba)
2022-12-06 09:32:34 +0100Tuplanolla(~Tuplanoll@91-159-68-152.elisa-laajakaista.fi)
2022-12-06 09:34:05 +0100zant(~zant@62.214.20.26)
2022-12-06 09:34:36 +0100son0p(~ff@2604:3d08:5b7f:5540::37af) (Ping timeout: 256 seconds)
2022-12-06 09:36:03 +0100lortabac(~lortabac@2a01:e0a:541:b8f0:3971:4229:3d13:9247)
2022-12-06 09:37:59 +0100freeside(~mengwong@103.252.202.193)
2022-12-06 09:39:45 +0100 <mauke> I've only watched the first three videos so far, but https://www.youtube.com/playlist?list=PLbgaMIhjbmEnaH_LTkxLI7FMa2HsnawM_ is really, really good
2022-12-06 09:40:01 +0100 <mauke> (Category Theory by Bartosz Milewski)
2022-12-06 09:41:14 +0100 <mauke> I have to crank the speed up to 1.4x because he talks slow, but I feel like I'm actually starting to understand the basics of category theory
2022-12-06 09:41:40 +0100kenaryn(~aurele@cre71-h03-89-88-44-27.dsl.sta.abo.bbox.fr) (Quit: leaving)
2022-12-06 09:43:01 +0100freeside_(~mengwong@103.252.202.193)
2022-12-06 09:43:34 +0100 <trev> funny, i watched about 8 episodes on 1.5 too
2022-12-06 09:45:31 +0100sympt(~sympt@user/sympt)
2022-12-06 09:45:37 +0100king_gs(~Thunderbi@187.201.204.122)
2022-12-06 09:50:58 +0100zeenk(~zeenk@2a02:2f04:a30d:4300::7fe)
2022-12-06 09:57:47 +0100Chai-T-Rex(~ChaiTRex@user/chaitrex) (Ping timeout: 255 seconds)
2022-12-06 09:58:05 +0100fockerize(~finn@roc37-h01-176-170-197-243.dsl.sta.abo.bbox.fr)
2022-12-06 09:58:59 +0100machinedgod(~machinedg@d198-53-218-113.abhsia.telus.net)
2022-12-06 09:59:19 +0100coot(~coot@2a02:a310:e241:1b00:ec1a:e9df:79ac:66ba) (Quit: coot)
2022-12-06 09:59:49 +0100Chai-T-Rex(~ChaiTRex@user/chaitrex)
2022-12-06 10:01:48 +0100lbseale(~quassel@user/ep1ctetus) (Ping timeout: 256 seconds)
2022-12-06 10:03:19 +0100fockerize(~finn@roc37-h01-176-170-197-243.dsl.sta.abo.bbox.fr) (Quit: WeeChat 3.5)
2022-12-06 10:04:39 +0100king_gs(~Thunderbi@187.201.204.122) (Read error: Connection reset by peer)
2022-12-06 10:05:40 +0100king_gs(~Thunderbi@2806:103e:29:94a4:81e0:429b:22ec:cf13)
2022-12-06 10:07:34 +0100Vajb(~Vajb@2001:999:504:3ad6:52a4:a3b5:32d8:e74d) (Read error: Connection reset by peer)
2022-12-06 10:08:02 +0100Vajb(~Vajb@hag-jnsbng11-58c3a5-27.dhcp.inet.fi)
2022-12-06 10:09:20 +0100kuribas(~user@ptr-17d51eo0qm84xeejuqw.18120a2.ip6.access.telenet.be)
2022-12-06 10:18:51 +0100king_gs(~Thunderbi@2806:103e:29:94a4:81e0:429b:22ec:cf13) (Ping timeout: 260 seconds)
2022-12-06 10:19:05 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2022-12-06 10:23:28 +0100lbseale(~quassel@user/ep1ctetus)
2022-12-06 10:26:41 +0100Unicorn_Princess(~Unicorn_P@user/Unicorn-Princess/x-3540542)
2022-12-06 10:31:51 +0100chele(~chele@user/chele)
2022-12-06 10:39:11 +0100L29Ah(~L29Ah@wikipedia/L29Ah) (Ping timeout: 264 seconds)
2022-12-06 10:43:45 +0100jonathanx(~jonathan@h-98-128-168-222.NA.cust.bahnhof.se)
2022-12-06 10:53:26 +0100MajorBiscuit(~MajorBisc@145.94.137.174)
2022-12-06 10:55:54 +0100eggplantade(~Eggplanta@2600:1700:38c5:d800:111a:339b:4372:c307) (Remote host closed the connection)
2022-12-06 10:56:43 +0100king_gs(~Thunderbi@187.201.204.122)
2022-12-06 10:57:11 +0100tzh(~tzh@c-24-21-73-154.hsd1.wa.comcast.net) (Quit: zzz)
2022-12-06 11:02:32 +0100CiaoSen(~Jura@p200300c95747e0002a3a4dfffe84dbd5.dip0.t-ipconnect.de)
2022-12-06 11:12:01 +0100gmg(~user@user/gehmehgeh)
2022-12-06 11:12:55 +0100Lord_of_Life_(~Lord@user/lord-of-life/x-2819915)
2022-12-06 11:13:29 +0100ubert1(~Thunderbi@2a02:8109:abc0:6434:6faa:61b1:766c:c219)
2022-12-06 11:14:10 +0100Lord_of_Life(~Lord@user/lord-of-life/x-2819915) (Ping timeout: 260 seconds)
2022-12-06 11:14:13 +0100Lord_of_Life_Lord_of_Life
2022-12-06 11:15:49 +0100gurkenglas(~gurkengla@p548ac72e.dip0.t-ipconnect.de)
2022-12-06 11:15:51 +0100king_gs(~Thunderbi@187.201.204.122) (Ping timeout: 256 seconds)
2022-12-06 11:16:09 +0100xff0x(~xff0x@125x103x176x34.ap125.ftth.ucom.ne.jp) (Quit: xff0x)
2022-12-06 11:23:50 +0100comerijn(~merijn@86-86-29-250.fixed.kpn.net) (Ping timeout: 246 seconds)
2022-12-06 11:24:32 +0100alexiscott(~user@4.red-83-36-45.dynamicip.rima-tde.net)
2022-12-06 11:25:16 +0100tessier(~treed@98.171.210.130) (Ping timeout: 268 seconds)
2022-12-06 11:27:31 +0100nattiestnate(~nate@202.138.250.13)
2022-12-06 11:29:06 +0100dextaa8(~DV@user/dextaa)
2022-12-06 11:31:02 +0100dextaa(~DV@user/dextaa) (Ping timeout: 252 seconds)
2022-12-06 11:31:02 +0100dextaa8dextaa
2022-12-06 11:31:08 +0100tessier(~treed@98.171.210.130)
2022-12-06 11:39:02 +0100gmg(~user@user/gehmehgeh) (Ping timeout: 255 seconds)
2022-12-06 11:40:00 +0100 <dminuoso> While it is a good introduction to category theory, I think the basic premise (CT for programmers) is a bit problematic, because CT doesnt pull much weight unless your business is trying to generalize mathematics problems
2022-12-06 11:40:22 +0100 <dminuoso> Which is something programmers are usually not concerned about.
2022-12-06 11:40:33 +0100gmg(~user@user/gehmehgeh)
2022-12-06 11:41:44 +0100 <dminuoso> Things like Yoneda are certainly interesting from category theory, but you dont need the slightest bit of mathematical knowledge to know why its useful for fmap fusion or recognize that its behaviorally correct.
2022-12-06 11:42:39 +0100 <tomsmeding> dminuoso: I think the "for programmers" isn't necessarily intended as "the things in CT that are useful for programmers", but "CT presented with examples from programming, so that programmers can understand it"
2022-12-06 11:42:55 +0100 <tomsmeding> the latter as opposed to the usual way, which is presenting examples from abstract math, which is unhelpful to a programmer
2022-12-06 11:43:27 +0100 <dminuoso> tomsmeding: Im not sure you gain much understanding unless you happen to have other fields or mathematics to apply this to.
2022-12-06 11:43:49 +0100 <dminuoso> It's kind of like explaining Monad but only ever picking IO as an example.
2022-12-06 11:43:57 +0100 <tomsmeding> true
2022-12-06 11:44:15 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
2022-12-06 11:45:34 +0100son0p(~ff@2604:3d08:5b7f:5540::a58f)
2022-12-06 11:49:50 +0100gmg(~user@user/gehmehgeh) (Ping timeout: 255 seconds)
2022-12-06 11:51:31 +0100troydm(~troydm@host-176-37-124-197.b025.la.net.ua)
2022-12-06 11:51:41 +0100merijn(~merijn@86-86-29-250.fixed.kpn.net)
2022-12-06 11:53:22 +0100gmg(~user@user/gehmehgeh)
2022-12-06 11:55:13 +0100thyriaen(~thyriaen@2a01:aea0:dd4:4bae:6245:cbff:fe9f:48b1)
2022-12-06 11:56:26 +0100eggplantade(~Eggplanta@2600:1700:38c5:d800:111a:339b:4372:c307)
2022-12-06 11:56:34 +0100 <kuribas> dminuoso: it only helps if you are Edward Kmett and implement advanced lenses :)
2022-12-06 12:00:33 +0100 <kuribas> Or if you write recursion schemes. But they don't seem to add that much value for the complexity.
2022-12-06 12:00:59 +0100eggplantade(~Eggplanta@2600:1700:38c5:d800:111a:339b:4372:c307) (Ping timeout: 255 seconds)
2022-12-06 12:01:31 +0100 <dminuoso> Every now and then I get a twitter post with some "*finally* a problem for which recursion schemes leads to better code"
2022-12-06 12:03:08 +0100 <kuribas> it can remove some boilerplate.
2022-12-06 12:03:41 +0100 <dminuoso> I recently read a really length article explaining the etymology of boilerplate code.
2022-12-06 12:03:47 +0100 <dminuoso> That was quite an interesting revelation
2022-12-06 12:03:57 +0100 <dminuoso> The connection is so incrediby distant
2022-12-06 12:04:27 +0100 <int-e> Hmmmmm category theory abstracts from boilerplate?
2022-12-06 12:05:21 +0100 <dminuoso> No, we just switched topics. Recursion schemes can save boilerplate.
2022-12-06 12:05:35 +0100Kaipei(~Kaiepi@108.175.84.104) (Ping timeout: 264 seconds)
2022-12-06 12:05:39 +0100 <dminuoso> At the expensive of legibility
2022-12-06 12:06:21 +0100 <kuribas> for those who don't understand recursion schemes.
2022-12-06 12:06:38 +0100 <dminuoso> Also at the expensive of performance, apparently.
2022-12-06 12:06:57 +0100 <kuribas> they aren't that difficult, it just takes a time to get to learn about the whole zoo.
2022-12-06 12:07:42 +0100 <dminuoso> I mean heck, we even need special tricks like (#.) in order for foldMap' performance to not degrade in many of its uses..
2022-12-06 12:09:07 +0100xff0x(~xff0x@2405:6580:b080:900:f990:42a1:d746:59a8)
2022-12-06 12:14:26 +0100 <kuribas> but the goal is safer and more elegant code, not better performance
2022-12-06 12:17:12 +0100 <int-e> dminuoso: I've seen some of that... at least those tricks are less scary than they used to be before Coercible.
2022-12-06 12:24:05 +0100merijn(~merijn@86-86-29-250.fixed.kpn.net) (Ping timeout: 246 seconds)
2022-12-06 12:24:47 +0100gurkenglas(~gurkengla@p548ac72e.dip0.t-ipconnect.de) (Quit: Lost terminal)
2022-12-06 12:25:07 +0100gurkenglas(~gurkengla@p548ac72e.dip0.t-ipconnect.de)
2022-12-06 12:26:40 +0100gmg(~user@user/gehmehgeh) (Remote host closed the connection)
2022-12-06 12:26:58 +0100coot(~coot@2a02:a310:e241:1b00:ec1a:e9df:79ac:66ba)
2022-12-06 12:30:38 +0100Erutuon(~Erutuon@user/erutuon) (Ping timeout: 268 seconds)
2022-12-06 12:57:14 +0100juri_(~juri@79.140.120.121) (Ping timeout: 255 seconds)
2022-12-06 12:58:59 +0100juri_(~juri@84-19-175-179.pool.ovpn.com)
2022-12-06 13:01:45 +0100merijn(~merijn@86-86-29-250.fixed.kpn.net)
2022-12-06 13:04:40 +0100Kaipei(~Kaiepi@108.175.84.104)
2022-12-06 13:05:13 +0100opticblast(~Thunderbi@secure-165.caltech.edu) (Ping timeout: 256 seconds)
2022-12-06 13:05:21 +0100jpds1(~jpds@gateway/tor-sasl/jpds)
2022-12-06 13:06:47 +0100jpds(~jpds@gateway/tor-sasl/jpds) (Ping timeout: 255 seconds)
2022-12-06 13:06:51 +0100merijn(~merijn@86-86-29-250.fixed.kpn.net) (Ping timeout: 260 seconds)
2022-12-06 13:07:08 +0100econo(uid147250@user/econo) (Quit: Connection closed for inactivity)
2022-12-06 13:20:39 +0100 <dminuoso> kuribas: There's very limited sets of problem where severe performance degradation is acceptable, especially since something like recursion schemes can easily sit inside libraries.
2022-12-06 13:21:59 +0100opticblast(~Thunderbi@secure-165.caltech.edu)
2022-12-06 13:22:13 +0100CiaoSen(~Jura@p200300c95747e0002a3a4dfffe84dbd5.dip0.t-ipconnect.de) (Ping timeout: 256 seconds)
2022-12-06 13:28:19 +0100acidjnk(~acidjnk@p200300d6e7137a1979c4b3a1e8b4bdac.dip0.t-ipconnect.de) (Ping timeout: 260 seconds)
2022-12-06 13:28:50 +0100acidjnk(~acidjnk@p200300d6e7137a1939f2f6580d858898.dip0.t-ipconnect.de)
2022-12-06 13:31:10 +0100Scraeling(~Scraeling@user/scraeling) (Quit: Scraeling)
2022-12-06 13:37:42 +0100opticblast(~Thunderbi@secure-165.caltech.edu) (Ping timeout: 256 seconds)
2022-12-06 13:39:16 +0100alexiscott(~user@4.red-83-36-45.dynamicip.rima-tde.net) (Ping timeout: 248 seconds)
2022-12-06 13:43:13 +0100stiell(~stiell@gateway/tor-sasl/stiell)
2022-12-06 13:43:48 +0100razetime(~quassel@49.207.203.213)
2022-12-06 13:44:27 +0100mzan(~quassel@mail.asterisell.com) (Quit: No Ping reply in 180 seconds.)
2022-12-06 13:45:51 +0100mzan(~quassel@mail.asterisell.com)
2022-12-06 13:46:21 +0100heinz9(~trace@user/trace)
2022-12-06 13:46:58 +0100 <heinz9> Is functional programming kinda using functions for every combination or for every what?
2022-12-06 13:48:00 +0100merijn(~merijn@86-86-29-250.fixed.kpn.net)
2022-12-06 13:48:03 +0100 <heinz9> and is procedural programming using procedures for every order / sequence ?
2022-12-06 13:49:36 +0100 <kmein> and logic programming uses logic for the programming
2022-12-06 13:49:44 +0100 <heinz9> prolog
2022-12-06 13:50:00 +0100 <heinz9> for old style AIs
2022-12-06 13:51:04 +0100 <heinz9> I am just looking for the equivalent of the programming paradigm in relations of paradigms
2022-12-06 13:54:30 +0100ezzieyguywuf(~Unknown@user/ezzieyguywuf) (Ping timeout: 268 seconds)
2022-12-06 13:55:19 +0100pavonia(~user@user/siracusa) (Quit: Bye!)
2022-12-06 13:59:59 +0100 <heinz9> or isnt functional programming not functions in functions?
2022-12-06 14:01:11 +0100chele(~chele@user/chele) (Remote host closed the connection)
2022-12-06 14:01:55 +0100 <int-e> Functional programming has functions as first-class values; you can pass functions as arguments to other functions.
2022-12-06 14:02:31 +0100 <int-e> > let plus1 x = 1 + x in map plus1 [1,2,3] -- like plus1 here
2022-12-06 14:02:32 +0100 <lambdabot> [2,3,4]
2022-12-06 14:03:09 +0100raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) (Quit: WeeChat 3.7.1)
2022-12-06 14:03:48 +0100 <heinz9> it is functions in functions
2022-12-06 14:04:01 +0100 <lortabac> other than what int-e said, I don't think there is a universally accepted definition of functional programming
2022-12-06 14:04:19 +0100ezzieyguywuf(~Unknown@user/ezzieyguywuf)
2022-12-06 14:04:33 +0100CiaoSen(~Jura@p200300c95747e0002a3a4dfffe84dbd5.dip0.t-ipconnect.de)
2022-12-06 14:05:00 +0100 <lortabac> Haskell, Clojure, Erlang, F#... are all considered functional languages but are quite different from each other
2022-12-06 14:05:48 +0100 <mrkun[m]> And OOP is all about objects; notice how none of these descriptions tell you anything if you don't already know what these paradigms are about
2022-12-06 14:08:49 +0100acidjnk_new(~acidjnk@p200300d6e7137a665d3a2af2e35b2922.dip0.t-ipconnect.de)
2022-12-06 14:09:26 +0100Alex_test(~al_test@178.34.151.8) (Ping timeout: 256 seconds)
2022-12-06 14:10:13 +0100acidjnk(~acidjnk@p200300d6e7137a1939f2f6580d858898.dip0.t-ipconnect.de) (Ping timeout: 252 seconds)
2022-12-06 14:13:55 +0100raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net)
2022-12-06 14:13:58 +0100noctux(~noctux@user/noctux) (Ping timeout: 256 seconds)
2022-12-06 14:16:25 +0100noctux(~noctux@user/noctux)
2022-12-06 14:16:26 +0100Alex_test(~al_test@178.34.151.8)
2022-12-06 14:19:04 +0100chele(~chele@user/chele)
2022-12-06 14:19:24 +0100 <dminuoso> heinz9: The term "functional programming" is not well defined.
2022-12-06 14:19:28 +0100 <dminuoso> It means different things to different people.
2022-12-06 14:19:48 +0100 <dminuoso> It is perhaps best to look at the different things that people may associate it with.
2022-12-06 14:20:15 +0100 <dminuoso> One notion is having higher order functions - that is functions act as first class objects and can be passed and/or returned to.
2022-12-06 14:20:18 +0100bitdex(~bitdex@gateway/tor-sasl/bitdex) (Quit: = "")
2022-12-06 14:21:00 +0100 <dminuoso> Another is having higher order functions *and* being very idiomatic to encode problems using higher order functions (say using folds rather than a `while` in structured programming languages)
2022-12-06 14:21:20 +0100merijn(~merijn@86-86-29-250.fixed.kpn.net) (Ping timeout: 256 seconds)
2022-12-06 14:21:44 +0100 <dminuoso> Another might think more about purity of functions since if you have pure functions, the usefulness of higher order functions raises quickly
2022-12-06 14:22:28 +0100kritzefitz(~kritzefit@debian/kritzefitz) (Ping timeout: 248 seconds)
2022-12-06 14:23:04 +0100 <dminuoso> So some might call C functional on the basis that you can pass function pointers around.
2022-12-06 14:24:09 +0100 <dminuoso> One further bit that extends on the third case (purity) is that in some compsci there is a distinction between `function` and `routine/procedure/action`, this holds true in Haskell in particular
2022-12-06 14:25:07 +0100 <dminuoso> What C calls functions in haskell we would rather refer to as `routines` and not functions. So perhaps `functional programming` might also refer to programming with functions in the mathematical sense.
2022-12-06 14:25:11 +0100 <heinz9> when can networks as things in your programming language not be derived, as classes could
2022-12-06 14:27:43 +0100 <Logio> functional as the antonym of dysfunctional is IMO also quite apt in the context of programming, more often than not
2022-12-06 14:28:42 +0100ezzieyguywuf(~Unknown@user/ezzieyguywuf) (Ping timeout: 256 seconds)
2022-12-06 14:29:15 +0100 <kuribas> dminuoso: GRIN uses recursion schemes, AFAIK there is no "severe" performance degrading.
2022-12-06 14:29:56 +0100sammelweis(~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10) (Ping timeout: 255 seconds)
2022-12-06 14:30:54 +0100sammelweis(~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10)
2022-12-06 14:33:48 +0100jmdaemon(~jmdaemon@user/jmdaemon) (Ping timeout: 256 seconds)
2022-12-06 14:39:44 +0100 <heinz9> what is a network more than a graph? I would say, it can have also states and information can go from state to state? is it this?
2022-12-06 14:41:47 +0100Chai-T-Rex(~ChaiTRex@user/chaitrex) (Remote host closed the connection)
2022-12-06 14:42:15 +0100Chai-T-Rex(~ChaiTRex@user/chaitrex)
2022-12-06 14:48:32 +0100causal(~user@50.35.85.7) (Ping timeout: 256 seconds)
2022-12-06 14:50:52 +0100gmg(~user@user/gehmehgeh)
2022-12-06 14:54:41 +0100kritzefitz(~kritzefit@debian/kritzefitz)
2022-12-06 14:56:34 +0100alexiscott(~user@4.red-83-36-45.dynamicip.rima-tde.net)
2022-12-06 14:58:01 +0100festive_kurbus(~festive_k@user/kurbus)
2022-12-06 14:58:33 +0100 <alexiscott> ls
2022-12-06 14:58:50 +0100 <dminuoso> #haskell: command not found: ls
2022-12-06 14:59:24 +0100 <festive_kurbus> you're looking for #linux
2022-12-06 14:59:49 +0100 <dminuoso> Actually #posix would be the right spot.
2022-12-06 15:00:03 +0100 <festive_kurbus> ls is under posix?
2022-12-06 15:00:07 +0100 <dminuoso> https://pubs.opengroup.org/onlinepubs/009696899/utilities/ls.html
2022-12-06 15:00:26 +0100jero98772(~jero98772@2800:484:1d80:d8ce:efcc:cbb3:7f2a:6dff)
2022-12-06 15:01:53 +0100xff0x(~xff0x@2405:6580:b080:900:f990:42a1:d746:59a8) (Ping timeout: 265 seconds)
2022-12-06 15:02:29 +0100causal(~user@50.35.85.7)
2022-12-06 15:05:48 +0100shriekingnoise(~shrieking@186.137.167.202)
2022-12-06 15:07:14 +0100irrgit_(~irrgit@176.113.74.74)
2022-12-06 15:08:40 +0100zant(~zant@62.214.20.26) (Ping timeout: 260 seconds)
2022-12-06 15:09:38 +0100cafce25(~cafce25@2001:a62:68e:bb01:a1bc:db0:b9af:a2f)
2022-12-06 15:10:38 +0100irrgit__(~irrgit@176.113.74.74) (Ping timeout: 256 seconds)
2022-12-06 15:13:18 +0100xff0x(~xff0x@2405:6580:b080:900:f990:42a1:d746:59a8)
2022-12-06 15:15:56 +0100ec_(~ec@gateway/tor-sasl/ec) (Ping timeout: 255 seconds)
2022-12-06 15:16:26 +0100kenaryn(~aurele@89-88-44-27.abo.bbox.fr)
2022-12-06 15:17:58 +0100 <gurkenglas> I asked the originator of a big list of *.hs files in a folder with no .cabal to print their ghc-pkg list output so I could make a .cabal file to reproduce their build. https://bpa.st/2TOA says rejecting: base-4.17.0.0/installed-4.17.0.0 (conflict: gwernnetstub =>
2022-12-06 15:18:21 +0100 <gurkenglas> base==4.15.0.0)
2022-12-06 15:18:58 +0100 <gurkenglas> How do I find out what causes the 4.17?
2022-12-06 15:19:02 +0100ec_(~ec@gateway/tor-sasl/ec)
2022-12-06 15:19:28 +0100 <dminuoso> gurkenglas: its what ghc comes with (the /installed part)
2022-12-06 15:20:05 +0100 <gurkenglas> dminuoso: so i need to tell cabal to use another ghc, right? how?
2022-12-06 15:20:11 +0100 <dminuoso> Not cabal
2022-12-06 15:20:18 +0100 <dminuoso> Your installation environment
2022-12-06 15:20:36 +0100 <dminuoso> cabal only invokes whatever `ghc` is on path (presumably you can also pass it some flags to point it at a given ghc installation, I do not know)
2022-12-06 15:20:37 +0100 <gurkenglas> .oO( aaaa what is an installation environment )
2022-12-06 15:20:43 +0100 <dminuoso> Well, ghcup, your package manager
2022-12-06 15:20:46 +0100 <dminuoso> however you installed ghc
2022-12-06 15:21:10 +0100L29Ah(~L29Ah@wikipedia/L29Ah)
2022-12-06 15:22:39 +0100 <gurkenglas> ooh, ghcup tui was what i needed to type.
2022-12-06 15:22:41 +0100merijn(~merijn@86-86-29-250.fixed.kpn.net)
2022-12-06 15:25:44 +0100troydm(~troydm@host-176-37-124-197.b025.la.net.ua) (Ping timeout: 246 seconds)
2022-12-06 15:29:15 +0100 <gurkenglas> His ghc-pkg list output was http://ix.io/4hJW - I tried to as straightforwardly as possible turn that into a package.yaml to run hpack on (possibly it would have made more sense to turn it directly into a .cabal?), but I get the feeling I need to know what it means that there are sections for "/opt/ghc/9.0.1/lib/ghc-9.0.1/package.conf.d" and "/home/gwern/.ghc/x86_64-linux-9.0.1/package.conf.d" in
2022-12-06 15:29:21 +0100 <gurkenglas> order to not jump into dependency hell
2022-12-06 15:29:32 +0100LemanR(~LemanR@pool-74-109-28-147.phlapa.fios.verizon.net)
2022-12-06 15:30:12 +0100opticblast(~Thunderbi@secure-165.caltech.edu)
2022-12-06 15:30:46 +0100irrgit__(~irrgit@176.113.74.138)
2022-12-06 15:30:46 +0100 <dminuoso> Are you trying to use cabal old-style?
2022-12-06 15:32:10 +0100acidjnk_new(~acidjnk@p200300d6e7137a665d3a2af2e35b2922.dip0.t-ipconnect.de) (Ping timeout: 256 seconds)
2022-12-06 15:32:57 +0100bontaq(~user@ool-45779fe5.dyn.optonline.net)
2022-12-06 15:34:14 +0100irrgit_(~irrgit@176.113.74.74) (Ping timeout: 260 seconds)
2022-12-06 15:34:28 +0100 <gurkenglas> dminuoso: I'm trying to make vscode/hls work with https://github.com/gwern/gwern.net/tree/master/build
2022-12-06 15:34:56 +0100 <dminuoso> What is this abomination? A polyglot with Haskell, python, R, bash and PHP?
2022-12-06 15:35:00 +0100 <dminuoso> o.o
2022-12-06 15:35:14 +0100 <gurkenglas> doesn't h ave to work with the non-Haskell parts
2022-12-06 15:35:49 +0100 <dminuoso> gurkenglas: anyway, dependency hell is a thing long in the past since v2-style builds (which for years have become the default)
2022-12-06 15:35:56 +0100 <dminuoso> no more ghc-pkg management, no dependency hell.
2022-12-06 15:36:01 +0100CiaoSen(~Jura@p200300c95747e0002a3a4dfffe84dbd5.dip0.t-ipconnect.de) (Ping timeout: 252 seconds)
2022-12-06 15:36:05 +0100 <dminuoso> So how are you trying to build this?
2022-12-06 15:36:22 +0100 <gurkenglas> as far as i understand, hls needs a .cabal file to even, so i asked gwern to do ghc-pkg list, *hoping* that it would work like pip freeze
2022-12-06 15:36:46 +0100 <dminuoso> What is gwern?
2022-12-06 15:36:55 +0100 <dminuoso> Oh thats a who, isnt it?
2022-12-06 15:37:25 +0100 <dminuoso> How does gwern even build this?
2022-12-06 15:38:01 +0100 <dminuoso> Oh man. That code looks like PHP but in Haskell syntax....
2022-12-06 15:38:16 +0100 <dminuoso> https://github.com/gwern/gwern.net/blob/master/build/LinkMetadata.hs#L1017-L1080
2022-12-06 15:38:17 +0100 <gurkenglas> yeah you may remember him from classics like "https://github.com/gwern/..." and ".../gwern.net/tree/master/build" :D
2022-12-06 15:38:33 +0100 <dminuoso> Im getting these weird itches when staring at that code..
2022-12-06 15:38:40 +0100 <gurkenglas> yeah i got those same itches
2022-12-06 15:38:47 +0100 <gurkenglas> how do you think i got into this mess
2022-12-06 15:38:54 +0100avicenzi(~avicenzi@2a00:ca8:a1f:b004::c32)
2022-12-06 15:39:07 +0100 <dminuoso> Ask your lawyer how to get out of it?
2022-12-06 15:39:10 +0100 <dminuoso> :)
2022-12-06 15:39:28 +0100 <gurkenglas> i'm not fundamentally opposed to being in this mess
2022-12-06 15:39:39 +0100 <gurkenglas> after all, if i were to get out of it, it would still be there
2022-12-06 15:39:49 +0100jonathanx(~jonathan@h-98-128-168-222.NA.cust.bahnhof.se) (Ping timeout: 260 seconds)
2022-12-06 15:39:58 +0100festive_kurbus(~festive_k@user/kurbus) (Quit: Client closed)
2022-12-06 15:40:25 +0100 <dminuoso> gurkenglas: anyway, is there any build script or makefile in this mess?
2022-12-06 15:40:28 +0100 <gurkenglas> bringing us back to: how do I properly turn ghc-pkg list output into a working hls
2022-12-06 15:40:46 +0100 <dminuoso> well you need to find a list of packages used in this mess
2022-12-06 15:41:04 +0100 <gurkenglas> http://ix.io/4hJW
2022-12-06 15:41:07 +0100 <dminuoso> use that list of packages to conjure up a build-depends section, include the ghc-pkg output to set appropriate bounds
2022-12-06 15:41:16 +0100 <dminuoso> Yeah but thats not necessarily the packages used here.
2022-12-06 15:41:22 +0100 <dminuoso> Hence my question: where is the build script?
2022-12-06 15:41:45 +0100 <gurkenglas> dminuoso: you mean, there may be packages installed but not used, or used but not installed?
2022-12-06 15:41:58 +0100 <dminuoso> well, first the ghc-pkg may have packages not used for that build process
2022-12-06 15:42:05 +0100 <dminuoso> second, this is also transient dependencies
2022-12-06 15:42:23 +0100 <dminuoso> (which is not necessairly an issue, but also very dishonest)
2022-12-06 15:42:43 +0100festive_kurbus(~festive_k@user/kurbus)
2022-12-06 15:42:43 +0100 <dminuoso> so where is the build script?
2022-12-06 15:42:45 +0100 <gurkenglas> *googles transient dependencies* dishonest on whose part?
2022-12-06 15:43:30 +0100 <dminuoso> Uhhh hold on...
2022-12-06 15:43:33 +0100 <dminuoso> #!/usr/bin/env runghc
2022-12-06 15:43:40 +0100 <dminuoso> I dont even...
2022-12-06 15:44:01 +0100 <dminuoso> Yeah this entire repository is PHP in Haskell.
2022-12-06 15:44:09 +0100 <dminuoso> Just wow.
2022-12-06 15:44:30 +0100 <dminuoso> I dont think there will be a simple answer how to uncovolute this mess.
2022-12-06 15:45:00 +0100 <gurkenglas> if im following along right we can make it run without unconvoluting it
2022-12-06 15:45:18 +0100 <dminuoso> You would have to write a cabal file (or multiple) with one component per file (or one component if multiple files), to make it at least buildable you can just include every package you have in that ghc-pkg in a build-depends section, and `import` that to each component
2022-12-06 15:45:42 +0100 <dminuoso> (that would allow HLS to pick it up)
2022-12-06 15:45:49 +0100 <gurkenglas> why not one component total?
2022-12-06 15:46:12 +0100 <dminuoso> guess that would probably work too
2022-12-06 15:46:18 +0100 <dminuoso> but you couldnt easily use `cabal run` then.
2022-12-06 15:46:40 +0100 <dminuoso> and it might introduce additional problems in case there's overlapping instances
2022-12-06 15:46:44 +0100 <dminuoso> not entirely sure
2022-12-06 15:46:56 +0100 <dminuoso> but making one component per file is not going to be much work
2022-12-06 15:47:10 +0100 <dminuoso> just feed `ls -1 *.hs` into some template
2022-12-06 15:47:33 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2022-12-06 15:47:57 +0100 <dminuoso> As for the build-depends, just make it a simple sed, turning say `mtl-2.2.2` into `, mtl == 2.2.2`
2022-12-06 15:47:57 +0100Sgeo(~Sgeo@user/sgeo)
2022-12-06 15:48:22 +0100 <dminuoso> use a `common` section, and `import` it in the template
2022-12-06 15:48:40 +0100nattiestnate(~nate@202.138.250.13) (Quit: WeeChat 3.7.1)
2022-12-06 15:48:49 +0100 <gurkenglas> so when I turned the ghc-pkg list output into a package.yaml and hpack'd it and ran cabal build I got rejecting: base-4.15.0.0/installed-4.15.0.0 (conflict: regex-compat-tdfa
2022-12-06 15:48:52 +0100 <gurkenglas> +/-newbase +/-splitbase => base<4.15)
2022-12-06 15:48:57 +0100 <dminuoso> and you'll have to resolve the duplicate packages there yourself
2022-12-06 15:49:06 +0100 <gurkenglas> which sounded to me like I failed to execute the strategy "reproduce what he has so it'll at least build *something*"
2022-12-06 15:49:17 +0100 <dminuoso> thats because you're using a too new ghc
2022-12-06 15:49:33 +0100 <dminuoso> this is one of those very unfortunate decisions to decouple base from ghc versions.
2022-12-06 15:49:37 +0100 <gurkenglas> i thought i fixed that when i set the ghc to 9.0.1
2022-12-06 15:49:54 +0100 <gurkenglas> in ghcup tui
2022-12-06 15:50:03 +0100 <dminuoso> you must then ensure that each dependency has an exact version bound
2022-12-06 15:50:13 +0100seydar(~seydar@154-27-113-252.starry-inc.net)
2022-12-06 15:50:29 +0100 <gurkenglas> yeah here's the generated .cabal https://bpa.st/IUOA
2022-12-06 15:50:30 +0100 <dminuoso> dont go through hpack (its a bit silly for what you are doing), just write out the cabal yourself
2022-12-06 15:50:41 +0100 <dminuoso> mmm that looks fine in principle
2022-12-06 15:50:43 +0100zer0bitz_(~zer0bitz@196.244.192.57)
2022-12-06 15:51:25 +0100urdh(~urdh@user/urdh) (Ping timeout: 252 seconds)
2022-12-06 15:51:26 +0100 <dminuoso> whats the full error you are getting now?
2022-12-06 15:51:46 +0100 <seydar> here's my day 6 solution, i'd love to get some feedback on it: https://paste.tomsmeding.com/YXQ3z0ow
2022-12-06 15:51:54 +0100 <gurkenglas> dminuoso: https://bpa.st/6QGA
2022-12-06 15:51:56 +0100merijn(~merijn@86-86-29-250.fixed.kpn.net) (Ping timeout: 246 seconds)
2022-12-06 15:52:03 +0100zant(~zant@dynamic-089-014-024-192.89.14.pool.telefonica.de)
2022-12-06 15:52:26 +0100jonathanx(~jonathan@h-178-174-176-109.A357.priv.bahnhof.se)
2022-12-06 15:52:39 +0100bgamari_(~bgamari@64.223.170.234) (Ping timeout: 260 seconds)
2022-12-06 15:52:51 +0100 <dminuoso> seydar: Im just going to name things in no particular order. In your nubOrd, the element should be strict.
2022-12-06 15:52:53 +0100leeb(~leeb@tk2-243-31079.vs.sakura.ne.jp) (Quit: ZNC 1.7.2+deb3 - https://znc.in)
2022-12-06 15:53:07 +0100urdh(~urdh@user/urdh)
2022-12-06 15:53:11 +0100 <dminuoso> or mmm
2022-12-06 15:53:30 +0100 <gurkenglas> seydar: print $ (case args of "one":_ -> partOne; _ -> partTwo) inp
2022-12-06 15:54:16 +0100zer0bitz(~zer0bitz@196.244.192.57) (Ping timeout: 256 seconds)
2022-12-06 15:54:43 +0100bgamari(~bgamari@64.223.169.135)
2022-12-06 15:55:20 +0100 <dminuoso> seydar: your use of (!!) and == is better dealt with pattern matching `case args of "one":_ -> ... _ -> ...
2022-12-06 15:55:31 +0100 <gurkenglas> ninja'd
2022-12-06 15:55:47 +0100 <dminuoso> Ah.
2022-12-06 15:56:31 +0100 <c_wraith> dminuoso: what's that about nubOrd? It looks the correct amount of strict to me
2022-12-06 15:56:32 +0100 <gurkenglas> interact $ map (case args of "one":_ -> packetStart; _ -> messageStart) . lines
2022-12-06 15:57:13 +0100jludwig(~justin@li657-110.members.linode.com) (Changing host)
2022-12-06 15:57:13 +0100jludwig(~justin@user/jludwig)
2022-12-06 15:57:50 +0100 <dminuoso> c_wraith: Im thinking this should have `go (s (!x):xs) = ...`
2022-12-06 15:59:06 +0100 <gurkenglas> seydar: in general, "foo1 x = foo x 1; foo2 x = foo x 2" indicates that the argument order for foo should be flipped
2022-12-06 15:59:22 +0100 <c_wraith> dminuoso: I don't think that matters for anything.
2022-12-06 15:59:26 +0100 <dminuoso> Mmm.
2022-12-06 15:59:29 +0100 <dminuoso> Fair.
2022-12-06 15:59:53 +0100 <gurkenglas> so uniqueSubstring :: Int -> String -> Int; uniqueSubstring duration = helper 0
2022-12-06 15:59:55 +0100eggplantade(~Eggplanta@2600:1700:38c5:d800:111a:339b:4372:c307)
2022-12-06 16:00:13 +0100 <c_wraith> dminuoso: set insert will already force enough evaluation of x to figure out where it goes in the set. and the set insertion itself is forced by branching on the guards
2022-12-06 16:00:34 +0100 <gurkenglas> interact $ map (uniqueSubstring (case args of "one":_ -> 4; _ -> 14)) . lines
2022-12-06 16:01:21 +0100 <gurkenglas> uniq = (==duration) . length . nubOrd . take duration
2022-12-06 16:01:22 +0100kraftwerk28(~kraftwerk@178.62.210.83) (Quit: ZNC 1.8.2 - https://znc.in)
2022-12-06 16:01:36 +0100 <dminuoso> c_wraith: Yeah I think Im arriving at the same conclusion. Sometimes I hate non-strict semantics because its not entirely obvious at first glance.
2022-12-06 16:02:39 +0100ix(~ix@2a02:8010:674f:0:d65d:64ff:fe52:5efe)
2022-12-06 16:02:42 +0100kraftwerk28(~kraftwerk@178.62.210.83)
2022-12-06 16:02:57 +0100akegalj(~akegalj@180-243.dsl.iskon.hr)
2022-12-06 16:03:59 +0100zant(~zant@dynamic-089-014-024-192.89.14.pool.telefonica.de) (Quit: WeeChat 3.5)
2022-12-06 16:04:22 +0100wroathe(~wroathe@207-153-38-140.fttp.usinternet.com)
2022-12-06 16:04:22 +0100wroathe(~wroathe@207-153-38-140.fttp.usinternet.com) (Changing host)
2022-12-06 16:04:22 +0100wroathe(~wroathe@user/wroathe)
2022-12-06 16:04:26 +0100eggplantade(~Eggplanta@2600:1700:38c5:d800:111a:339b:4372:c307) (Ping timeout: 255 seconds)
2022-12-06 16:04:28 +0100zant(~zant@dynamic-089-014-024-192.89.14.pool.telefonica.de)
2022-12-06 16:05:41 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
2022-12-06 16:05:47 +0100 <gurkenglas> seydar, "uniqueSubstring duration = helper2 . zip [0..] . tails" will get rid of your explicit recursion in helper, and then you can soon remove helper2 completely I think
2022-12-06 16:06:18 +0100LemanR(~LemanR@pool-74-109-28-147.phlapa.fios.verizon.net) (Ping timeout: 260 seconds)
2022-12-06 16:08:17 +0100LemanR(~LemanR@pool-74-109-28-147.phlapa.fios.verizon.net)
2022-12-06 16:08:29 +0100 <gurkenglas> do we have a one-word shortcut for "snd (mapAccumL f xs)" yet?
2022-12-06 16:11:11 +0100 <gurkenglas> also, is there some language extension that enables a monomorphism restriction which makes "traversable" and "foldable" default to []=
2022-12-06 16:11:14 +0100 <gurkenglas> *[]?
2022-12-06 16:11:20 +0100sammelweis(~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10) (Quit: No Ping reply in 180 seconds.)
2022-12-06 16:11:46 +0100 <gurkenglas> (plus perhaps more, as a tutorial mode for more readable errors)
2022-12-06 16:12:33 +0100sammelweis(~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10)
2022-12-06 16:13:14 +0100 <[exa]> gurkenglas: that mapAccumL looks kinda like you could do execState/evaState + traverse but all expressions I'm finding are strictly longer
2022-12-06 16:13:32 +0100festive_kurbus(~festive_k@user/kurbus) (Quit: Client closed)
2022-12-06 16:15:14 +0100dsrt^(~dsrt@76.145.185.103) (Ping timeout: 256 seconds)
2022-12-06 16:17:05 +0100festive_kurbus(~festive_k@user/kurbus)
2022-12-06 16:17:14 +0100 <[exa]> :t \f xs init -> evalState (traverse (fmap state f) xs) init
2022-12-06 16:17:15 +0100 <lambdabot> Traversable t => (a -> s -> (b, s)) -> t a -> s -> t b
2022-12-06 16:17:29 +0100 <[exa]> gurkenglas: probably not better^
2022-12-06 16:18:05 +0100 <dminuoso> gurkenglas: the topic of monormophized version comes up every now and then
2022-12-06 16:18:28 +0100cafce25(~cafce25@2001:a62:68e:bb01:a1bc:db0:b9af:a2f) (Quit: Client closed)
2022-12-06 16:18:29 +0100 <dminuoso> I've suggested this as a haddock hook rather, where haddock could display a beginner version with polymorphic types monomorphized to some author preferred types.
2022-12-06 16:19:10 +0100 <dminuoso> A language extension that will give you diagnostic that are very different from whatever haddock tells you is not a good idea I think
2022-12-06 16:19:18 +0100LemanR(~LemanR@pool-74-109-28-147.phlapa.fios.verizon.net) (Quit: Client closed)
2022-12-06 16:20:53 +0100thyriaen(~thyriaen@2a01:aea0:dd4:4bae:6245:cbff:fe9f:48b1) (Remote host closed the connection)
2022-12-06 16:22:25 +0100 <dminuoso> Consider how special ($) is treated both in terms of levity polymorphism (which the GHC diagnostics hide, but haddock does not), and in terms of impredicativity (GHC selectively turns on QuickLook for it)
2022-12-06 16:22:30 +0100raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) (Ping timeout: 268 seconds)
2022-12-06 16:23:50 +0100In0perable(~PLAYER_1@fancydata.science) (Excess Flood)
2022-12-06 16:24:19 +0100raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net)
2022-12-06 16:24:33 +0100acidjnk_new(~acidjnk@p200300d6e7137a665d3a2af2e35b2922.dip0.t-ipconnect.de)
2022-12-06 16:25:39 +0100Inoperable(~PLAYER_1@fancydata.science)
2022-12-06 16:27:03 +0100use-value(~Thunderbi@2a00:23c6:8a03:2f01:6956:303f:1676:5fd5) (Remote host closed the connection)
2022-12-06 16:27:21 +0100use-value(~Thunderbi@2a00:23c6:8a03:2f01:6956:303f:1676:5fd5)
2022-12-06 16:28:16 +0100wroathe(~wroathe@user/wroathe) (Ping timeout: 256 seconds)
2022-12-06 16:30:15 +0100 <gurkenglas> [exa]: yeah usually i use evalState in that situation but it seemed silly when the usecase is that common
2022-12-06 16:30:55 +0100notzmv(~zmv@user/notzmv) (Ping timeout: 260 seconds)
2022-12-06 16:31:30 +0100opticblast(~Thunderbi@secure-165.caltech.edu) (Ping timeout: 260 seconds)
2022-12-06 16:31:53 +0100fserucas__(~fserucas@212.157.222.3) (Ping timeout: 246 seconds)
2022-12-06 16:32:21 +0100 <[exa]> gurkenglas: you can do it with `fold` if your stuff is monoid :D
2022-12-06 16:32:46 +0100ezzieyguywuf(~Unknown@user/ezzieyguywuf)
2022-12-06 16:33:47 +0100opticblast(~Thunderbi@secure-165.caltech.edu)
2022-12-06 16:34:21 +0100 <gurkenglas> :t auf (iso evalState state) traverse -- [exa]
2022-12-06 16:34:22 +0100 <lambdabot> Traversable t => (a -> s -> (b, s)) -> t a -> s -> t b
2022-12-06 16:35:54 +0100tabemann_(~tabemann@2600:1700:7990:24e0:ca39:3d1d:9852:a6c9) (Remote host closed the connection)
2022-12-06 16:36:04 +0100MajorBiscuit(~MajorBisc@145.94.137.174) (Ping timeout: 268 seconds)
2022-12-06 16:36:07 +0100tabemann_(~tabemann@2600:1700:7990:24e0:61f0:ea0e:b3a2:c286)
2022-12-06 16:36:49 +0100 <gurkenglas> dminuoso: the full error you wanted is https://bpa.st/6QGA
2022-12-06 16:38:09 +0100opticblast(~Thunderbi@secure-165.caltech.edu) (Ping timeout: 260 seconds)
2022-12-06 16:38:58 +0100 <gurkenglas> which seems like it would be the first out of dozens or hundreds of errors, which is why I think I failed to execute the strategy "just reproduce gwern's exact environment state and it should build"
2022-12-06 16:39:05 +0100 <[exa]> gurkenglas: lovable auf.
2022-12-06 16:40:30 +0100sammelweis(~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10) (Quit: No Ping reply in 180 seconds.)
2022-12-06 16:41:37 +0100sammelweis(~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10)
2022-12-06 16:45:00 +0100azimut(~azimut@gateway/tor-sasl/azimut)
2022-12-06 16:46:48 +0100 <gurkenglas> [exa]: I was on second thought disturbed that evalState, which I have cached as "has wrong argument order", should fit well into this. in fact:
2022-12-06 16:47:02 +0100 <gurkenglas> :t auf (iso (flip evalState ?s) state) traverse
2022-12-06 16:47:03 +0100 <lambdabot> (?s::s, Traversable t) => (a -> s -> (b, s)) -> t a -> t b
2022-12-06 16:48:21 +0100jao(~jao@cpc103048-sgyl39-2-0-cust502.18-2.cable.virginm.net)
2022-12-06 16:52:07 +0100 <c_wraith> gurkenglas: well, it's the wrong argument order because it's the same argument order as runState. and runState has that argument order because it used to be the getter for a newtype, which is what makes that iso work nicely
2022-12-06 16:52:34 +0100zant(~zant@dynamic-089-014-024-192.89.14.pool.telefonica.de) (Ping timeout: 265 seconds)
2022-12-06 16:53:33 +0100 <c_wraith> At least conceptually. nevermind that Identity hiding in there, it doesn't really exist!
2022-12-06 16:53:46 +0100 <gurkenglas> On third thought, fine. I now see that both of those argument orders have a place. The one evalState has is for drawing a correspondence between "s -> (large, s)" and "s -> (small, s)". The one I've long thought is the right one is for drawing a correspondence between "large" and "s -> (small, s)"
2022-12-06 16:57:17 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2022-12-06 16:58:11 +0100 <gurkenglas> The former composes better, the latter fits into applications. It's like composing lenses vs calling view on a lens
2022-12-06 16:59:48 +0100 <gurkenglas> Which still leaves me at: flip evalState ought to have a name! Perhaps an operator
2022-12-06 17:00:00 +0100dsrt^(~dsrt@76.145.185.103)
2022-12-06 17:00:34 +0100 <gurkenglas> https://hackage.haskell.org/package/lens-5.2/docs/Control-Lens-Lens.html#v:-38--126- yes that, thank you memory
2022-12-06 17:00:51 +0100 <gurkenglas> (where's the StateT one?)
2022-12-06 17:05:34 +0100 <gurkenglas> ...oh no, I just remembered that after all these years, IxState didn't take off :(
2022-12-06 17:05:48 +0100zant(~zant@dynamic-089-014-024-192.89.14.pool.telefonica.de)
2022-12-06 17:06:32 +0100 <gurkenglas> Has anyone played around with having ChatGPT explain their compiler errors?
2022-12-06 17:06:48 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
2022-12-06 17:08:03 +0100opticblast(~Thunderbi@secure-165.caltech.edu)
2022-12-06 17:08:24 +0100eggplantade(~Eggplanta@2600:1700:38c5:d800:111a:339b:4372:c307)
2022-12-06 17:10:59 +0100 <c_wraith> If it's truly trained on feedback from the internet, it'll mostly say "put a type signature on that and try again"
2022-12-06 17:11:36 +0100 <akegalj> gurkenglas: I think that would be interesting experiment. I played with using chatgpt to give a review on assignments (like teacher assistant would) and results are interesting
2022-12-06 17:13:53 +0100festive_kurbus(~festive_k@user/kurbus) (Quit: Client closed)
2022-12-06 17:16:15 +0100festive_kurbus(~festive_k@user/kurbus)
2022-12-06 17:17:34 +0100bobbingbob(~dfadsva@2604:3d09:207f:f650::7b3a)
2022-12-06 17:20:38 +0100 <sm> or for tech support in channel or on reddit
2022-12-06 17:21:01 +0100lortabac(~lortabac@2a01:e0a:541:b8f0:3971:4229:3d13:9247) (Quit: WeeChat 2.8)
2022-12-06 17:21:12 +0100 <sm> "what's a good book to learn haskell ?" "why this cabal/stack error ?" "why isn't hls working ?"
2022-12-06 17:21:24 +0100 <festive_kurbus> welcome to tech support
2022-12-06 17:22:41 +0100 <gurkenglas> I appear to have gotten myself into a pickle. I have a directory "cabaltest" containing only cabaltest.cabal with contents: https://bpa.st/QFLQ
2022-12-06 17:23:15 +0100 <gurkenglas> running cabal build gets me: https://bpa.st/4GJA
2022-12-06 17:24:29 +0100festive_kurbus(~festive_k@user/kurbus) (Quit: Client closed)
2022-12-06 17:25:58 +0100 <geekosaur> a cabal file without a cabal-version field is assumed to be cabal v1
2022-12-06 17:26:37 +0100 <geekosaur> (cabal library that is)
2022-12-06 17:26:58 +0100 <gurkenglas> ah. how silly of me to think that starting from an empty slate would get comprehensible errors :P
2022-12-06 17:27:31 +0100 <geekosaur> empty slate is `cabal init`
2022-12-06 17:28:21 +0100 <geekosaur> problem is there are still a lot of cabal v1 files floating around that don't declare themselves as such, so cabal-install has to assume any cabal file that doesn't say otherwise is one of the
2022-12-06 17:28:24 +0100 <geekosaur> m
2022-12-06 17:29:00 +0100 <geekosaur> because cabal v2+ are very different from cabal v1
2022-12-06 17:29:38 +0100 <gurkenglas> geekosaur: shouldn't it be able to notice from looking at "rejecting: test:setup.Cabal-3.4.0.0/installed-3.4.0.0 (conflict: test => test:setup.Cabal>=1.0 && <1.25)" that this is not what's happening, though?
2022-12-06 17:30:10 +0100 <geekosaur> `test:setup.Cabal>=1.0 && <1.25` is precisely that happening
2022-12-06 17:30:59 +0100 <geekosaur> it inserts that dpeendency because it sees what it thinks is a cabal v1 file
2022-12-06 17:31:19 +0100 <gurkenglas> misunderstanding? i mean: shouldn't it notice from the conflict with 3.4 that the file is probably not intended as v1?
2022-12-06 17:31:33 +0100festive_kurbus(~festive_k@user/kurbus)
2022-12-06 17:31:46 +0100 <geekosaur> no, because people quite often try to build cabal v1 packages with later cabal versions
2022-12-06 17:34:07 +0100 <gurkenglas> ah so that error line expects the user to read it as: "i am rejecting this because you're apparently trying to use Cabal 3.4 to build a Cabal 1.0 project. No can do. Downgrade your cabal installation or change the cabal-version in *.cabal"?
2022-12-06 17:34:40 +0100 <geekosaur> yes
2022-12-06 17:35:05 +0100 <geekosaur> it'd be nice if cabal reported this better, admittedly
2022-12-06 17:35:24 +0100 <geekosaur> it's almost as bad reporting "this package requires a different version of ghc"
2022-12-06 17:36:19 +0100 <Hecate> hello
2022-12-06 17:36:29 +0100 <Hecate> are we talking about ergonomics in haskell tooling?
2022-12-06 17:36:34 +0100 <geekosaur> yep
2022-12-06 17:36:50 +0100 <geekosaur> cabal error messages have long been frustrating
2022-12-06 17:36:55 +0100 <Hecate> indeed they have
2022-12-06 17:37:01 +0100 <Hecate> we can fix this
2022-12-06 17:37:40 +0100 <Hecate> geekosaur: would you mind creating a ticket for this ergonomics problem?
2022-12-06 17:41:39 +0100 <geekosaur> creating
2022-12-06 17:48:59 +0100merijn(~merijn@86-86-29-250.fixed.kpn.net)
2022-12-06 17:50:02 +0100eggplantade(~Eggplanta@2600:1700:38c5:d800:111a:339b:4372:c307) (Remote host closed the connection)
2022-12-06 17:50:03 +0100 <glguy> We could probably benefit both from a warning when building a cabal package missing a cabal-version declaration, and a reason attached to the 1.x version bound in the error about unsolvable deps
2022-12-06 17:51:36 +0100 <sclv> glguy: i agree on the version stuff. when we first added the req it was a soft cutover, but enough time had passed. what does “cabal check” say btw
2022-12-06 17:52:59 +0100opticblast(~Thunderbi@secure-165.caltech.edu) (Ping timeout: 248 seconds)
2022-12-06 17:57:20 +0100 <geekosaur> https://github.com/haskell/cabal/issues/8626
2022-12-06 17:57:30 +0100eggplantade(~Eggplanta@2600:1700:38c5:d800:111a:339b:4372:c307)
2022-12-06 18:03:07 +0100zant(~zant@dynamic-089-014-024-192.89.14.pool.telefonica.de) (Ping timeout: 248 seconds)
2022-12-06 18:03:10 +0100sammelweis(~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10) (Quit: No Ping reply in 180 seconds.)
2022-12-06 18:04:54 +0100sammelweis(~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10)
2022-12-06 18:07:00 +0100 <gurkenglas> sclv: http://ix.io/4hUk
2022-12-06 18:08:00 +0100Topsi(~Topsi@dyndsl-095-033-034-215.ewe-ip-backbone.de)
2022-12-06 18:08:20 +0100 <sclv> that's not a bad set of warnings, lmao. i wonder if any should be upgraded to errors, or to "more vocal" warnings (ones that get displayed even w/o cabal check).
2022-12-06 18:08:43 +0100 <gurkenglas> I wasn't complaining about that set of warnings ^^! in fact I wasn't aware of it
2022-12-06 18:08:44 +0100 <sclv> or maybe if there's enough warnings we can just print "uh... you probably want to run cabal check"
2022-12-06 18:08:50 +0100festive_kurbus(~festive_k@user/kurbus) (Quit: Client closed)
2022-12-06 18:09:03 +0100 <sclv> right -- the ergonomics is mainly that cabal notices all the problems but doesn't direct you to them
2022-12-06 18:09:04 +0100festive_kurbus(~festive_k@user/kurbus)
2022-12-06 18:09:31 +0100 <sclv> because users who Know What They Are Doing would tend to get mad at most of these warnings being on by default
2022-12-06 18:11:10 +0100zant(~zant@62.214.20.26)
2022-12-06 18:12:11 +0100alexiscott(~user@4.red-83-36-45.dynamicip.rima-tde.net) (Ping timeout: 264 seconds)
2022-12-06 18:12:58 +0100alexiscott(~user@4.red-83-36-45.dynamicip.rima-tde.net)
2022-12-06 18:13:00 +0100Xeroine(~Xeroine@user/xeroine) (Ping timeout: 260 seconds)
2022-12-06 18:13:29 +0100werneta(~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 256 seconds)
2022-12-06 18:13:31 +0100Xeroine(~Xeroine@user/xeroine)
2022-12-06 18:14:07 +0100seydar(~seydar@154-27-113-252.starry-inc.net) (Ping timeout: 252 seconds)
2022-12-06 18:16:37 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2022-12-06 18:17:31 +0100EvanR(~EvanR@user/evanr) (Remote host closed the connection)
2022-12-06 18:17:49 +0100EvanR(~EvanR@user/evanr)
2022-12-06 18:19:00 +0100alexiscott(~user@4.red-83-36-45.dynamicip.rima-tde.net) (Ping timeout: 255 seconds)
2022-12-06 18:20:24 +0100ec(~ec@gateway/tor-sasl/ec)
2022-12-06 18:21:20 +0100ec_(~ec@gateway/tor-sasl/ec) (Ping timeout: 255 seconds)
2022-12-06 18:21:29 +0100sammelweis_(~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10)
2022-12-06 18:21:36 +0100sammelweis(~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10) (Ping timeout: 256 seconds)
2022-12-06 18:21:58 +0100opticblast(~Thunderbi@secure-165.caltech.edu)
2022-12-06 18:22:22 +0100wootehfoot(~wootehfoo@user/wootehfoot)
2022-12-06 18:22:44 +0100raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) (Ping timeout: 256 seconds)
2022-12-06 18:23:16 +0100 <gurkenglas> dminuoso: ha, ~all i needed to do for cabal build to work was slap an --allow-newer on it. Now for hls...
2022-12-06 18:23:32 +0100merijn(~merijn@86-86-29-250.fixed.kpn.net) (Ping timeout: 252 seconds)
2022-12-06 18:24:41 +0100eggplantade(~Eggplanta@2600:1700:38c5:d800:111a:339b:4372:c307) (Remote host closed the connection)
2022-12-06 18:25:44 +0100raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net)
2022-12-06 18:26:27 +0100opticblast(~Thunderbi@secure-165.caltech.edu) (Ping timeout: 268 seconds)
2022-12-06 18:27:41 +0100eggplantade(~Eggplanta@104-55-37-220.lightspeed.sntcca.sbcglobal.net)
2022-12-06 18:28:50 +0100opticblast(~Thunderbi@secure-165.caltech.edu)
2022-12-06 18:31:13 +0100chele(~chele@user/chele) (Quit: Leaving)
2022-12-06 18:31:39 +0100LemanR(~LemanR@pool-74-109-28-147.phlapa.fios.verizon.net)
2022-12-06 18:31:42 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
2022-12-06 18:32:22 +0100seydar(~seydar@154-27-113-252.starry-inc.net)
2022-12-06 18:33:14 +0100opticblast(~Thunderbi@secure-165.caltech.edu) (Ping timeout: 268 seconds)
2022-12-06 18:35:57 +0100festive_kurbus(~festive_k@user/kurbus) (Quit: Client closed)
2022-12-06 18:37:48 +0100bgs(~bgs@212-85-160-171.dynamic.telemach.net)
2022-12-06 18:38:07 +0100eggplantade(~Eggplanta@104-55-37-220.lightspeed.sntcca.sbcglobal.net) (Remote host closed the connection)
2022-12-06 18:39:11 +0100Xeroine(~Xeroine@user/xeroine) (Ping timeout: 264 seconds)
2022-12-06 18:39:32 +0100opticblast(~Thunderbi@secure-165.caltech.edu)
2022-12-06 18:39:44 +0100avicenzi(~avicenzi@2a00:ca8:a1f:b004::c32) (Ping timeout: 256 seconds)
2022-12-06 18:39:46 +0100Xeroine(~Xeroine@user/xeroine)
2022-12-06 18:41:23 +0100 <mrkun[m]> Are users who know what they are doing really the target audience of the default config
2022-12-06 18:41:48 +0100 <geekosaur> that was the point I tried to make in my ticket
2022-12-06 18:42:24 +0100 <geekosaur> newcomers have no idea they need to work around the history of cabal-install, no idea they should use v2-build and friends, etc.
2022-12-06 18:42:39 +0100 <geekosaur> it's time to let cabal v1 die a natural death, I think
2022-12-06 18:43:13 +0100 <gurkenglas> Ah, probably I need to also tell hls to use --allow-newer.
2022-12-06 18:43:18 +0100 <sclv> geekosaur: btw note this isn't about v1 vs v2 build
2022-12-06 18:43:27 +0100 <sclv> this is about cabal file format versions
2022-12-06 18:43:42 +0100 <sclv> like literally the Cabal 1.0 library and file format
2022-12-06 18:44:11 +0100 <mrkun[m]> Cabal v1 still alive?! Gosh. I'd say some unnaturality would also be appropriate.
2022-12-06 18:44:30 +0100 <geekosaur> no, but I did note that while filing the ticket because of the comment that "you should use v2-build" in the example
2022-12-06 18:44:35 +0100ubert1(~Thunderbi@2a02:8109:abc0:6434:6faa:61b1:766c:c219) (Remote host closed the connection)
2022-12-06 18:44:44 +0100 <geekosaur> that might be the first time a newcomer discovers that's an issue
2022-12-06 18:45:12 +0100 <geekosaur> there's a lot of baggage hanging around
2022-12-06 18:45:19 +0100use-value1(~Thunderbi@2a00:23c6:8a03:2f01:2d36:9da8:a662:60e2)
2022-12-06 18:45:40 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2022-12-06 18:46:27 +0100Erutuon(~Erutuon@user/erutuon)
2022-12-06 18:47:35 +0100use-value(~Thunderbi@2a00:23c6:8a03:2f01:6956:303f:1676:5fd5) (Ping timeout: 264 seconds)
2022-12-06 18:47:35 +0100use-value1use-value
2022-12-06 18:50:03 +0100tomokojun(~tomokojun@static-198-54-130-102.cust.tzulo.com)
2022-12-06 18:56:11 +0100 <gurkenglas> Looking at haskell-language-server-9.0.1~1.6.1.0 --help to figure out how to get an hie.yaml file to add an --allow-newer flag to, --probe-tools Show haskell-language-server version and other tools
2022-12-06 18:56:29 +0100 <gurkenglas> welp, sometimes your clipboard contents are wrong and contain a newline.
2022-12-06 18:58:15 +0100 <gurkenglas> ...to add an --allow-newer flag to, haskell-language-server-9.0.1\~1.6.1.0 generate-default-config 2>hie.yaml turned out to be not it at all :D
2022-12-06 18:59:20 +0100 <gurkenglas> Can i put the --allow-newer in the *.cabal, since it looks like haskell-language-server wants to not need hie.yaml?
2022-12-06 18:59:23 +0100festive_kurbus(~festive_k@user/kurbus)
2022-12-06 18:59:46 +0100 <sclv> allow-newer goes in cabal.project
2022-12-06 19:00:05 +0100eggplantade(~Eggplanta@104-55-37-220.lightspeed.sntcca.sbcglobal.net)
2022-12-06 19:00:13 +0100 <gurkenglas> allow me to be dismayed at yet another new kind of file
2022-12-06 19:00:17 +0100 <seydar> gurkenglas, dminuoso: sorry, i got pulled away to a meeting. Thank you both for your feedback! I'm going over it now
2022-12-06 19:00:42 +0100LemanR(~LemanR@pool-74-109-28-147.phlapa.fios.verizon.net) (Quit: Client closed)
2022-12-06 19:03:26 +0100son0p(~ff@2604:3d08:5b7f:5540::a58f) (Ping timeout: 246 seconds)
2022-12-06 19:03:41 +0100irrgit_(~irrgit@89.47.234.26)
2022-12-06 19:04:06 +0100sammelweis_(~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10) (Quit: No Ping reply in 180 seconds.)
2022-12-06 19:05:22 +0100sammelweis(~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10)
2022-12-06 19:05:29 +0100irrgit__(~irrgit@176.113.74.138) (Ping timeout: 246 seconds)
2022-12-06 19:05:59 +0100razetime(~quassel@49.207.203.213) (Quit: https://quassel-irc.org - Chat comfortably. Anywhere.)
2022-12-06 19:06:24 +0100tzh(~tzh@c-24-21-73-154.hsd1.wa.comcast.net)
2022-12-06 19:06:47 +0100 <gurkenglas> "packages: ./*.cabal\nallow-newer:*" in a cabal.project file made cabal build act like cabal build --allow-newer, thanks
2022-12-06 19:06:56 +0100terrorjack(~terrorjac@2a01:4f8:1c1e:509a::1) (Ping timeout: 256 seconds)
2022-12-06 19:08:31 +0100terrorjack(~terrorjac@2a01:4f8:1c1e:509a::1)
2022-12-06 19:10:05 +0100 <gurkenglas> https://bpa.st/344Q "Please report this as a GHC bug" :o
2022-12-06 19:11:05 +0100Vajb(~Vajb@hag-jnsbng11-58c3a5-27.dhcp.inet.fi) (Read error: Connection reset by peer)
2022-12-06 19:11:51 +0100 <gurkenglas> strange that the cabal.project needed the packages: ./*.cabal line, https://cabal.readthedocs.io/en/3.4/cabal-project.html#specifying-the-local-packages says this is the default
2022-12-06 19:12:09 +0100jakalx(~jakalx@base.jakalx.net) (Error from remote client)
2022-12-06 19:14:22 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
2022-12-06 19:14:36 +0100Vajb(~Vajb@2001:999:504:3ad6:52a4:a3b5:32d8:e74d)
2022-12-06 19:15:07 +0100jakalx(~jakalx@base.jakalx.net)
2022-12-06 19:15:27 +0100irrgit__(~irrgit@86.106.90.226)
2022-12-06 19:18:46 +0100irrgit_(~irrgit@89.47.234.26) (Ping timeout: 252 seconds)
2022-12-06 19:19:17 +0100zeenk(~zeenk@2a02:2f04:a30d:4300::7fe) (Quit: Konversation terminated!)
2022-12-06 19:25:25 +0100werneta(~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net)
2022-12-06 19:37:08 +0100econo(uid147250@user/econo)
2022-12-06 19:37:15 +0100son0p(~ff@2604:3d08:5b7f:5540::a58f)
2022-12-06 19:41:59 +0100stevenxl(uid133530@id-133530.uxbridge.irccloud.com) (Quit: Connection closed for inactivity)
2022-12-06 19:44:17 +0100 <gurkenglas> In one of EK's libraries iirc there's a file defining one arcane category-theory newtype, and among its exports is one function whose type signature does not mention the newtype, and its purpose is to reparanthesize a degenerate nested composition into the more efficient order. What was it?
2022-12-06 19:44:24 +0100merijn(~merijn@86-86-29-250.fixed.kpn.net)
2022-12-06 19:45:20 +0100coot(~coot@2a02:a310:e241:1b00:ec1a:e9df:79ac:66ba) (Quit: coot)
2022-12-06 19:45:56 +0100Chai-T-Rex(~ChaiTRex@user/chaitrex) (Ping timeout: 255 seconds)
2022-12-06 19:49:14 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2022-12-06 19:49:59 +0100merijn(~merijn@86-86-29-250.fixed.kpn.net) (Ping timeout: 264 seconds)
2022-12-06 19:50:57 +0100Chai-T-Rex(~ChaiTRex@user/chaitrex)
2022-12-06 19:52:14 +0100ec(~ec@gateway/tor-sasl/ec) (Ping timeout: 255 seconds)
2022-12-06 19:53:39 +0100ec(~ec@gateway/tor-sasl/ec)
2022-12-06 19:53:44 +0100 <mauke> https://hackage.haskell.org/package/category-extras-0.52.1/docs/Control-Functor-Yoneda.html says it makes stuff more efficient and it looks inscrutable
2022-12-06 19:53:53 +0100LemanR(~LemanR@pool-74-109-28-147.phlapa.fios.verizon.net)
2022-12-06 19:55:56 +0100Lycurgus(~juan@user/Lycurgus)
2022-12-06 20:04:03 +0100samt___(uid578768@id-578768.ilkley.irccloud.com) (Quit: Connection closed for inactivity)
2022-12-06 20:04:09 +0100eggplantade(~Eggplanta@104-55-37-220.lightspeed.sntcca.sbcglobal.net) (Remote host closed the connection)
2022-12-06 20:05:19 +0100bjourne2(~bjorn@94.191.136.157.mobile.tre.se)
2022-12-06 20:11:20 +0100wootehfoot(~wootehfoo@user/wootehfoot) (Read error: Connection reset by peer)
2022-12-06 20:14:24 +0100mestre(~mestre@191.177.185.178)
2022-12-06 20:14:47 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
2022-12-06 20:15:34 +0100seydar(~seydar@154-27-113-252.starry-inc.net) (Quit: leaving)
2022-12-06 20:16:13 +0100opticblast(~Thunderbi@secure-165.caltech.edu) (Ping timeout: 252 seconds)
2022-12-06 20:17:28 +0100bjourne2(~bjorn@94.191.136.157.mobile.tre.se) (Read error: Connection reset by peer)
2022-12-06 20:18:39 +0100V(~v@ircpuzzles/2022/april/winner/V)
2022-12-06 20:20:17 +0100 <gurkenglas> mauke: thanks, that was it! Yoneda was the first thing I looked at, but https://hackage.haskell.org/package/kan-extensions-5.2.5/docs/Data-Functor-Contravariant-Coyoneda.… doesn't give the goods :(
2022-12-06 20:20:42 +0100 <gurkenglas> uh, https://hackage.haskell.org/package/kan-extensions-5.2.5/docs/Data-Functor-Contravariant-Yoneda.html , I mean.
2022-12-06 20:21:47 +0100 <gurkenglas> um. I should have checked your link before affirming
2022-12-06 20:22:41 +0100 <gurkenglas> I still think there was one file defining a newtype and an export that only internally uses it
2022-12-06 20:23:12 +0100 <gurkenglas> (though what you gave slightly decreases my certainty that it exists)
2022-12-06 20:23:24 +0100Lycurgus(~juan@user/Lycurgus) (Quit: Exeunt https://tinyurl.com/4m8d4kd5)
2022-12-06 20:25:04 +0100Erutuon(~Erutuon@user/erutuon) (Ping timeout: 260 seconds)
2022-12-06 20:27:43 +0100festive_kurbus(~festive_k@user/kurbus) (Quit: Client closed)
2022-12-06 20:28:04 +0100sammelweis(~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10) (Ping timeout: 252 seconds)
2022-12-06 20:28:11 +0100sammelweis(~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10)
2022-12-06 20:30:26 +0100money_(~money@user/polo)
2022-12-06 20:30:49 +0100eggplantade(~Eggplanta@2600:1700:38c5:d800:111a:339b:4372:c307)
2022-12-06 20:31:52 +0100coot(~coot@2a02:a310:e241:1b00:ec1a:e9df:79ac:66ba)
2022-12-06 20:33:26 +0100troydm(~troydm@host-176-37-124-197.b025.la.net.ua)
2022-12-06 20:35:41 +0100festive_kurbus(~festive_k@user/kurbus)
2022-12-06 20:36:51 +0100opticblast(~Thunderbi@secure-165.caltech.edu)
2022-12-06 20:46:43 +0100merijn(~merijn@86-86-29-250.fixed.kpn.net)
2022-12-06 20:46:56 +0100bjourne2(~bjorn@94.191.136.201.mobile.tre.se)
2022-12-06 20:48:13 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2022-12-06 20:48:48 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
2022-12-06 20:54:07 +0100sammelweis(~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10) (Quit: No Ping reply in 180 seconds.)
2022-12-06 20:54:14 +0100sammelweis(~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10)
2022-12-06 20:56:04 +0100ericjmorey[m](~ericjmore@2001:470:69fc:105::7afc)
2022-12-06 21:00:18 +0100wroathe(~wroathe@207-153-38-140.fttp.usinternet.com)
2022-12-06 21:00:18 +0100wroathe(~wroathe@207-153-38-140.fttp.usinternet.com) (Changing host)
2022-12-06 21:00:18 +0100wroathe(~wroathe@user/wroathe)
2022-12-06 21:01:00 +0100tcard(~tcard@2400:4051:5801:7500:cf17:befc:ff82:5303) (Ping timeout: 260 seconds)
2022-12-06 21:01:20 +0100fserucas__(~fserucas@laubervilliers-657-1-66-228.w90-63.abo.wanadoo.fr)
2022-12-06 21:01:55 +0100tcard(~tcard@2400:4051:5801:7500:cf17:befc:ff82:5303)
2022-12-06 21:04:44 +0100kenran(~user@user/kenran)
2022-12-06 21:04:56 +0100kenran(~user@user/kenran) (Remote host closed the connection)
2022-12-06 21:06:05 +0100eggplantade(~Eggplanta@2600:1700:38c5:d800:111a:339b:4372:c307) (Remote host closed the connection)
2022-12-06 21:06:28 +0100 <gqplox[m]> hello
2022-12-06 21:06:43 +0100shriekingnoise(~shrieking@186.137.167.202) (Ping timeout: 260 seconds)
2022-12-06 21:06:47 +0100shriekingnoise_(~shrieking@186.137.167.202)
2022-12-06 21:06:50 +0100 <gqplox[m]> http://sprunge.us/QNATWu
2022-12-06 21:07:27 +0100 <gqplox[m]> today's aoc seemed pretty simple, how did you guys solve?
2022-12-06 21:08:03 +0100 <darkling> It was easier overall than yesterday, but that's because yesterday's was a bit more complex to parse the input.
2022-12-06 21:09:06 +0100 <mauke> :t fmap (+ 4) . findIndex ((== 4) . length . nub . take 4) . tails
2022-12-06 21:09:07 +0100 <lambdabot> Eq a => [a] -> Maybe Int
2022-12-06 21:09:15 +0100wroathe(~wroathe@user/wroathe) (Ping timeout: 268 seconds)
2022-12-06 21:11:17 +0100 <dsal> gqplox[m]: ha. basically that.
2022-12-06 21:11:32 +0100 <dsal> But I did come up with a thing I liked for doing duplicate checking in a single pass.
2022-12-06 21:11:40 +0100 <darkling> I was a bit more complex: https://github.com/darkling/AoC2022/blob/main/day06/Main.hs
2022-12-06 21:12:19 +0100 <dsal> gqplox[m]: Note that you *usually* don't need explicit recursion because so many concepts already exist.
2022-12-06 21:12:57 +0100 <darkling> It's just finding them that's the hard part. :)
2022-12-06 21:13:35 +0100 <dsal> gqplox[m]: e.g., if you didn't have `findIndex` you could make it by doing something like `fmap head . listToMaybe . filter (\(_,x) -> f x) . zip [0..]`
2022-12-06 21:13:50 +0100dsalimagines an extra `)` in there
2022-12-06 21:14:56 +0100Guest|94(~Guest|94@43.224.111.221)
2022-12-06 21:15:10 +0100 <dsal> > tails "gqplox"
2022-12-06 21:15:12 +0100 <lambdabot> ["gqplox","qplox","plox","lox","ox","x",""]
2022-12-06 21:15:15 +0100 <gqplox[m]> oh nice
2022-12-06 21:15:50 +0100 <dsal> I found a nice way to avoid nub: `allUnique = isJust . foldM (flip $ Set.alterF (bool (Just True) Nothing)) mempty`
2022-12-06 21:16:17 +0100 <dsal> My actual code is `allUnique = isJust . foldM (flip $ BitSet.alterF @Word32 (bool (Just True) Nothing)) (BitSet.bitSet ('a', 'z'))` because I have a BitSet type Ixes a range over a thing that has bits
2022-12-06 21:16:24 +0100 <gqplox[m]> tails is cool i didn't know aaabout that
2022-12-06 21:16:46 +0100 <gqplox[m]> nice
2022-12-06 21:16:53 +0100 <mauke> alternatively: /(.{4})(?(?{ !all_distinct $1 })(?!))/ and say $+[1];
2022-12-06 21:16:55 +0100 <Guest|94> Hi, I'm having trouble installing ghcup in windows 11. Tried several times w/ and w/o admin. Restarted pc. The bin folder is always empty after installation and "ghc" command is not recognized by powershell (restarted powershell after installation as well)
2022-12-06 21:17:09 +0100 <mauke> is there a haskell regex library that lets you embed arbitrary code in the matching process?
2022-12-06 21:17:13 +0100 <mauke> or is it all just string based?
2022-12-06 21:17:19 +0100 <EvanR> yes haskell can solve these in ones liners like, fmap (+size) . findIndex unique . map (take size) . tails, where unique xs = nub xs == xs, but that's no fun. We need to deploy heavy machinery just because xD
2022-12-06 21:17:20 +0100 <dsal> gqplox[m]: There's a bunch of junk in Data.List and Data.Foldable that are neat.
2022-12-06 21:17:33 +0100 <gqplox[m]> also how i have for examepl, how I have solve input 14 0 I can change it as you can see in this paste
2022-12-06 21:17:35 +0100 <gqplox[m]> http://sprunge.us/yMEq27
2022-12-06 21:17:54 +0100 <dsal> Your args are out of order, though. input should be last.
2022-12-06 21:18:10 +0100 <gqplox[m]> how can i do this whilst keeping args order the same?
2022-12-06 21:18:13 +0100 <mauke> I mean, that also applies to http://sprunge.us/cuIj3E
2022-12-06 21:18:23 +0100 <mauke> part 2 is literally a one character change
2022-12-06 21:19:08 +0100 <dsal> gqplox[m]: There's often a natural ordering of arguments. You started discovering this when you moved the accumulator (which you'd generally not want to be exposed in your api)
2022-12-06 21:19:16 +0100 <gurkenglas> mauke: https://hackage.haskell.org/package/lens-regex-0.1.3/docs/Text-Regex-Lens.html will let you turn a regex into an optic and then you can compose them with arbitrary optics you have lying around, like filtered
2022-12-06 21:19:19 +0100merijn(~merijn@86-86-29-250.fixed.kpn.net) (Ping timeout: 260 seconds)
2022-12-06 21:20:40 +0100 <gqplox[m]> so I guess the best way to do it is to expose the solve taking input and length and then have a where inside solve which calls solve' input length 0
2022-12-06 21:20:50 +0100 <mauke> gurkenglas: that's just doing stuff with the results of a regex :-/
2022-12-06 21:20:59 +0100 <dsal> gqplox[m]: Yeah, that's common. Often called something like `go` or `loop`
2022-12-06 21:21:44 +0100 <dsal> e.g. solve l = go 0 where go _ (x:xs) ...
2022-12-06 21:22:08 +0100 <dsal> The next step is "does something like this already exist?" :)
2022-12-06 21:22:33 +0100 <dsal> This is sort of a hylomorphism, but I don't think we have a handy hylomorphism in base do we?
2022-12-06 21:23:07 +0100 <EvanR> there's a natural order of arguments, and then foldl wants them in the other order xD
2022-12-06 21:23:12 +0100ddellacosta(~ddellacos@static-198-44-136-91.cust.tzulo.com)
2022-12-06 21:23:13 +0100 <dsal> I don't think doing it as a hylomorphism is better than just chaining a bunch of stuff together and let it fuse.
2022-12-06 21:23:37 +0100 <dsal> EvanR: yeah. :( I'm using foldM above which is a left fold. I didn't like that part.
2022-12-06 21:24:09 +0100 <mauke> gurkenglas: I'm looking for something that lets me do more interesting stuff in the [r|...|] part
2022-12-06 21:24:30 +0100crazazy(~user@mobiela8a1593778d7.roaming.utwente.nl)
2022-12-06 21:24:57 +0100pablito(~pablito@93.51.40.51)
2022-12-06 21:25:03 +0100pablito(~pablito@93.51.40.51) ()
2022-12-06 21:26:16 +0100otis90(~otis@93.51.40.51)
2022-12-06 21:27:24 +0100 <otis90> Hello, is there some documentation on the syntax adopted in order to use functions on type literals? e.g. https://hackage.haskell.org/package/base-4.17.0.0/docs/GHC-TypeNats.html#t:-60--61-
2022-12-06 21:31:25 +0100 <gqplox[m]> Evan cool solution :)
2022-12-06 21:31:50 +0100 <gqplox[m]> it's nice i was just reading about fmap yesterday too
2022-12-06 21:31:53 +0100 <gurkenglas> mauke: soo you'd like regex-like bindings for a parser combinator library?
2022-12-06 21:32:25 +0100fserucas__(~fserucas@laubervilliers-657-1-66-228.w90-63.abo.wanadoo.fr) (Ping timeout: 252 seconds)
2022-12-06 21:33:22 +0100christiansen(~christian@83-95-137-75-dynamic.dk.customer.tdc.net)
2022-12-06 21:33:28 +0100 <mauke> gurkenglas: good point
2022-12-06 21:33:37 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2022-12-06 21:33:40 +0100 <mauke> yes, I suppose
2022-12-06 21:34:03 +0100 <mauke> or at least more compact notation for parser combinators
2022-12-06 21:34:14 +0100pavonia(~user@user/siracusa)
2022-12-06 21:34:54 +0100trev(~trev@user/trev) (Remote host closed the connection)
2022-12-06 21:36:38 +0100festive_kurbus(~festive_k@user/kurbus) (Quit: Client closed)
2022-12-06 21:41:57 +0100phma(phma@2001:5b0:210b:fa28:3019:703:1a42:7f84) (Read error: Connection reset by peer)
2022-12-06 21:42:05 +0100 <EvanR> take the most common 10000 haskell combinators and assign a chinese character to each one
2022-12-06 21:42:17 +0100 <sm> ha.. what are regexps after all but a (fixed) set of parser combinators with compact notation
2022-12-06 21:42:47 +0100 <geekosaur> otis90, what about the syntax?
2022-12-06 21:42:50 +0100phma(~phma@2001:5b0:2144:44d8:212c:2869:b063:882b)
2022-12-06 21:42:51 +0100 <zzz> is `LeErrMsg` what they call error messages in French?
2022-12-06 21:42:54 +0100 <EvanR> sm, that usually return () xD
2022-12-06 21:43:17 +0100 <EvanR> or always, if you don't have captures
2022-12-06 21:44:23 +0100Guest|94(~Guest|94@43.224.111.221) (Quit: Connection closed)
2022-12-06 21:46:52 +0100opticblast(~Thunderbi@secure-165.caltech.edu) (Ping timeout: 268 seconds)
2022-12-06 21:47:42 +0100ec_(~ec@gateway/tor-sasl/ec)
2022-12-06 21:49:14 +0100`2jt(~jtomas@129.red-88-17-230.dynamicip.rima-tde.net)
2022-12-06 21:50:35 +0100ec(~ec@gateway/tor-sasl/ec) (Ping timeout: 255 seconds)
2022-12-06 21:51:01 +0100waleee(~waleee@2001:9b0:213:7200:cc36:a556:b1e8:b340)
2022-12-06 21:58:43 +0100oldsk00l(~znc@ec2-18-194-66-165.eu-central-1.compute.amazonaws.com)
2022-12-06 21:59:33 +0100jmdaemon(~jmdaemon@user/jmdaemon)
2022-12-06 22:01:56 +0100waleee(~waleee@2001:9b0:213:7200:cc36:a556:b1e8:b340) (Ping timeout: 246 seconds)
2022-12-06 22:03:48 +0100heinz9(~trace@user/trace) (Remote host closed the connection)
2022-12-06 22:05:53 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
2022-12-06 22:06:00 +0100raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) (Ping timeout: 256 seconds)
2022-12-06 22:06:02 +0100otis90(~otis@93.51.40.51) (Quit: Client closed)
2022-12-06 22:06:35 +0100eggplantade(~Eggplanta@2600:1700:38c5:d800:111a:339b:4372:c307)
2022-12-06 22:11:11 +0100eggplantade(~Eggplanta@2600:1700:38c5:d800:111a:339b:4372:c307) (Ping timeout: 255 seconds)
2022-12-06 22:12:20 +0100`2jt(~jtomas@129.red-88-17-230.dynamicip.rima-tde.net) (Ping timeout: 248 seconds)
2022-12-06 22:12:41 +0100LemanR(~LemanR@pool-74-109-28-147.phlapa.fios.verizon.net) (Quit: Client closed)
2022-12-06 22:16:00 +0100gmg(~user@user/gehmehgeh) (Remote host closed the connection)
2022-12-06 22:16:40 +0100merijn(~merijn@86-86-29-250.fixed.kpn.net)
2022-12-06 22:19:36 +0100gmg(~user@user/gehmehgeh)
2022-12-06 22:21:11 +0100Patternmaster(~georg@user/Patternmaster) (Ping timeout: 264 seconds)
2022-12-06 22:21:24 +0100Patternmaster(~georg@user/Patternmaster)
2022-12-06 22:22:55 +0100mvk(~mvk@2607:fea8:5ce3:8500::efb)
2022-12-06 22:22:56 +0100mvk(~mvk@2607:fea8:5ce3:8500::efb) (Client Quit)
2022-12-06 22:26:45 +0100jao(~jao@cpc103048-sgyl39-2-0-cust502.18-2.cable.virginm.net) (Ping timeout: 260 seconds)
2022-12-06 22:28:53 +0100mmhat(~mmh@p200300f1c73b51cbee086bfffe095315.dip0.t-ipconnect.de) (Ping timeout: 246 seconds)
2022-12-06 22:29:15 +0100mmhat(~mmh@p200300f1c73b5136ee086bfffe095315.dip0.t-ipconnect.de)
2022-12-06 22:32:52 +0100kenaryn(~aurele@89-88-44-27.abo.bbox.fr) (Quit: Lost terminal)
2022-12-06 22:35:12 +0100waleee(~waleee@2001:9b0:213:7200:cc36:a556:b1e8:b340)
2022-12-06 22:35:49 +0100 <shapr> is there some way to use FFI from inside ghci?
2022-12-06 22:35:54 +0100 <shapr> I mean, it seems unlikely
2022-12-06 22:37:59 +0100 <geekosaur> use FFI should just work. declare it, probably not, it doesn't support the syntax from the prompt yet
2022-12-06 22:38:14 +0100 <tomsmeding> mauke: https://paste.tomsmeding.com/iPIXa20t
2022-12-06 22:39:43 +0100 <tomsmeding> as we say in dutch, "warranty till your front door", i.e. I tested it on 1 input lol
2022-12-06 22:40:54 +0100 <geekosaur> actually it works at the prompt: https://paste.tomsmeding.com/lAFdhG53
2022-12-06 22:41:38 +0100 <tomsmeding> mauke: for example, `render (Optional)` should probably return some empty groups if it doesn't match :p
2022-12-06 22:42:26 +0100kenaryn(~aurele@cre71-h03-89-88-44-27.dsl.sta.abo.bbox.fr)
2022-12-06 22:45:47 +0100 <geekosaur> shapr, if you need an external library you probably have to exit and restart ghci with the library specified on the command line; last I heard there wasn't a way to attach one after startup
2022-12-06 22:46:05 +0100 <shapr> geekosaur: oh is there an example of that?
2022-12-06 22:46:05 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2022-12-06 22:46:43 +0100 <geekosaur> example of what? it's just "ghci [foo.hs] -lsomelib" (or "someobj.o" or whatever)
2022-12-06 22:46:57 +0100 <shapr> oh ok, thanks
2022-12-06 22:49:13 +0100 <shapr> we've cross-compiled a shared object via rustc onto android, next to see if it works in ghci
2022-12-06 22:49:26 +0100 <shapr> I was surprised to discover that ghci works fine in termux on my phone
2022-12-06 22:50:03 +0100gmg(~user@user/gehmehgeh) (Quit: Leaving)
2022-12-06 22:50:04 +0100 <tomsmeding> Note the use of parsec to parse a parsec parser
2022-12-06 22:50:06 +0100merijn(~merijn@86-86-29-250.fixed.kpn.net) (Ping timeout: 252 seconds)
2022-12-06 22:51:18 +0100 <shapr> wow
2022-12-06 22:51:24 +0100 <mauke> TIL about unsafeCodeCoerce
2022-12-06 22:52:24 +0100 <dsal> tomsmeding: I heard you liked parsers
2022-12-06 22:53:19 +0100 <shapr> :-D
2022-12-06 22:53:24 +0100 <tomsmeding> mauke: it's not quite as unsafe as unsafeCoerce though, the resulting haskell expression is still run through the typechecker as usual
2022-12-06 22:54:02 +0100 <EvanR> fix parsec
2022-12-06 22:55:10 +0100shailangsa(~shailangs@host217-39-45-196.range217-39.btcentralplus.com) (Remote host closed the connection)
2022-12-06 22:56:30 +0100`2jt(~jtomas@129.red-88-17-230.dynamicip.rima-tde.net)
2022-12-06 22:57:44 +0100Kaiepi(~Kaiepi@108.175.84.104)
2022-12-06 22:58:23 +0100`2jt(~jtomas@129.red-88-17-230.dynamicip.rima-tde.net) (Client Quit)
2022-12-06 23:00:11 +0100Kaipei(~Kaiepi@108.175.84.104) (Ping timeout: 264 seconds)
2022-12-06 23:02:01 +0100 <tomsmeding> % :t \s -> fix (\p -> let Right p' = Text.Parsec.parse p "" s in p')
2022-12-06 23:02:01 +0100 <yahb2> <interactive>:1:7: error: ; Variable not in scope: ; fix :: (Text.Parsec.Prim.Parsec s () a0 -> a0) -> t
2022-12-06 23:02:12 +0100 <tomsmeding> % import Data.Function
2022-12-06 23:02:12 +0100 <yahb2> <no output>
2022-12-06 23:02:23 +0100 <tomsmeding> % :t \s -> fix (\p -> let Right p' = Text.Parsec.parse p "" s in p')
2022-12-06 23:02:23 +0100 <yahb2> <interactive>:1:61: error: ; • Couldn't match expected type ‘Text.Parsec.Prim.Parsec s () a’ ; with actual type ‘a’ ; ‘a’ is a rigid type variable bound by ; the...
2022-12-06 23:02:27 +0100michalz(~michalz@185.246.204.72) (Remote host closed the connection)
2022-12-06 23:02:39 +0100 <tomsmeding> Ah right
2022-12-06 23:09:48 +0100coot(~coot@2a02:a310:e241:1b00:ec1a:e9df:79ac:66ba) (Quit: coot)
2022-12-06 23:23:38 +0100jargon(~jargon@184.101.177.18)
2022-12-06 23:24:47 +0100christiansen(~christian@83-95-137-75-dynamic.dk.customer.tdc.net) (Ping timeout: 264 seconds)
2022-12-06 23:27:59 +0100jao(~jao@cpc103048-sgyl39-2-0-cust502.18-2.cable.virginm.net)
2022-12-06 23:28:20 +0100phma(~phma@2001:5b0:2144:44d8:212c:2869:b063:882b) (Read error: Connection reset by peer)
2022-12-06 23:28:44 +0100phma(phma@2001:5b0:2144:44d8:212c:2869:b063:882b)
2022-12-06 23:30:04 +0100takuan(~takuan@178-116-218-225.access.telenet.be) (Remote host closed the connection)
2022-12-06 23:34:23 +0100waleee(~waleee@2001:9b0:213:7200:cc36:a556:b1e8:b340) (Ping timeout: 264 seconds)
2022-12-06 23:35:47 +0100raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net)
2022-12-06 23:36:16 +0100Kaiepi(~Kaiepi@108.175.84.104) (Remote host closed the connection)
2022-12-06 23:36:40 +0100bontaq(~user@ool-45779fe5.dyn.optonline.net) (Ping timeout: 256 seconds)
2022-12-06 23:37:14 +0100shailangsa(~shailangs@host217-39-45-196.range217-39.btcentralplus.com)
2022-12-06 23:37:17 +0100Kaiepi(~Kaiepi@108.175.84.104)
2022-12-06 23:39:13 +0100zant(~zant@62.214.20.26) (Quit: WeeChat 3.5)
2022-12-06 23:39:28 +0100zant(~zant@62.214.20.26)
2022-12-06 23:41:52 +0100waleee(~waleee@h-176-10-137-138.NA.cust.bahnhof.se)
2022-12-06 23:46:19 +0100raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) (Ping timeout: 260 seconds)
2022-12-06 23:46:59 +0100akegalj(~akegalj@180-243.dsl.iskon.hr) (Quit: leaving)
2022-12-06 23:49:04 +0100merijn(~merijn@86-86-29-250.fixed.kpn.net)
2022-12-06 23:49:37 +0100oldsk00l(~znc@ec2-18-194-66-165.eu-central-1.compute.amazonaws.com) (Remote host closed the connection)
2022-12-06 23:50:00 +0100 <money> Hey
2022-12-06 23:55:56 +0100gurkenglas(~gurkengla@p548ac72e.dip0.t-ipconnect.de) (Ping timeout: 256 seconds)
2022-12-06 23:59:53 +0100christiansen(~christian@83-95-137-75-dynamic.dk.customer.tdc.net)