2024/06/26

2024-06-26 00:00:47 +0000 <EvanR> there might be some more you could try https://stackoverflow.com/questions/6115459/small-haskell-program-compiled-with-ghc-into-huge-bina…
2024-06-26 00:04:54 +0000 <joeyadams> Thanks. Maybe I should just create a single record and derive FromJSON, and look at the assembly. I'm mainly curious why it takes so much code to do (what should be) so little.
2024-06-26 00:08:11 +0000joeyadams(~joeyadams@2607:fb91:1617:1400:929b:26f0:654:cc5a) (Quit: Leaving)
2024-06-26 00:08:21 +0000gmg(~user@user/gehmehgeh) (Quit: Leaving)
2024-06-26 00:18:55 +0000Tuplanolla(~Tuplanoll@91-159-69-59.elisa-laajakaista.fi) (Quit: Leaving.)
2024-06-26 00:19:29 +0000euleritian(~euleritia@dynamic-176-000-205-223.176.0.pool.telefonica.de) (Ping timeout: 252 seconds)
2024-06-26 00:22:05 +0000 <jackdk> @tell joeyadams https://well-typed.com/blog/2021/08/large-records/ might be relevant here
2024-06-26 00:22:05 +0000 <lambdabot> Consider it noted.
2024-06-26 00:22:18 +0000 <Axman6> yeah that came to mind for me too
2024-06-26 00:22:38 +0000 <Axman6> also ping EvanR since you were looking into it too
2024-06-26 00:27:09 +0000philopsos1(~caecilius@user/philopsos)
2024-06-26 00:33:31 +0000 <safinaskar> @tell joeyadams also try self-unpacking binaries :)
2024-06-26 00:33:32 +0000 <lambdabot> Consider it noted.
2024-06-26 00:35:10 +0000henry40408(~henry4040@175.182.111.183) (Quit: Ping timeout (120 seconds))
2024-06-26 00:35:17 +0000joeyadams(~joeyadams@2603:6010:5100:2ed:c9:f4bd:32a:187d)
2024-06-26 00:35:36 +0000henry40408(~henry4040@175.182.111.183)
2024-06-26 00:37:14 +0000 <joeyadams> Thanks, jackdk, looking at it now.
2024-06-26 00:42:36 +0000 <safinaskar> bye
2024-06-26 00:42:39 +0000safinaskar(~quassel@212.73.77.104) ()
2024-06-26 00:44:27 +0000szkl(uid110435@id-110435.uxbridge.irccloud.com) (Quit: Connection closed for inactivity)
2024-06-26 00:48:39 +0000safinaskar(~quassel@212.73.77.104)
2024-06-26 00:48:50 +0000safinaskar(~quassel@212.73.77.104) ()
2024-06-26 00:51:18 +0000sudden(~cat@user/sudden) (Ping timeout: 255 seconds)
2024-06-26 00:52:31 +0000machinedgod(~machinedg@d173-183-246-216.abhsia.telus.net) (Ping timeout: 246 seconds)
2024-06-26 00:55:39 +0000edrx(~Eduardo@170-233-51-85.static.sumicity.net.br)
2024-06-26 00:57:01 +0000 <edrx> hi all! gmorning!
2024-06-26 00:57:44 +0000 <edrx> I wrote a program to help me typeset type inferences using underbrace diagrams - it generates figures like this: https://i.ibb.co/8mZ2VVp/sshot.png
2024-06-26 00:58:18 +0000 <edrx> but the "=>" looks ugly - i.e., the \textsf{=>} looks ugly.
2024-06-26 00:58:28 +0000 <edrx> what would you use instead? suggestions?
2024-06-26 01:01:20 +0000puke(~puke@user/puke) (Remote host closed the connection)
2024-06-26 01:01:57 +0000emmanuelux(~emmanuelu@user/emmanuelux) (Quit: au revoir)
2024-06-26 01:02:58 +0000puke(~puke@user/puke)
2024-06-26 01:03:36 +0000sudden(~cat@user/sudden)
2024-06-26 01:03:51 +0000pointlessslippe1(~pointless@212.82.82.3) (Ping timeout: 264 seconds)
2024-06-26 01:15:35 +0000kaskal(~kaskal@213-147-165-88.nat.highway.webapn.at) (Ping timeout: 252 seconds)
2024-06-26 01:19:16 +0000 <pavonia> edrx: \Rightarrow or \Longrightarrow
2024-06-26 01:52:06 +0000CiaoSen(~Jura@2a05:5800:2d8:3a00:e6b9:7aff:fe80:3d03)
2024-06-26 01:58:53 +0000masterbuilder(~quassel@user/masterbuilder) (Ping timeout: 240 seconds)
2024-06-26 01:59:29 +0000masterbuilder(~quassel@user/masterbuilder)
2024-06-26 01:59:54 +0000glguy(g@libera/staff/glguy) (Remote host closed the connection)
2024-06-26 02:07:30 +0000dcoutts_(~duncan@2a00:23c6:1c8d:901:b94:4566:9d63:4848)
2024-06-26 02:08:29 +0000dcoutts(~duncan@2a00:23c6:1c8d:901:b94:4566:9d63:4848) (Ping timeout: 256 seconds)
2024-06-26 02:19:51 +0000rosco(~rosco@175.136.155.137)
2024-06-26 02:22:11 +0000xff0x(~xff0x@ai068022.d.east.v6connect.net) (Ping timeout: 264 seconds)
2024-06-26 02:26:17 +0000madhavanmiui(~madhavanm@2409:40f4:305f:dd79:8000::)
2024-06-26 02:26:41 +0000madhavanmiui(~madhavanm@2409:40f4:305f:dd79:8000::) (Client Quit)
2024-06-26 02:27:09 +0000waleee(~waleee@h-176-10-144-38.NA.cust.bahnhof.se) (Ping timeout: 255 seconds)
2024-06-26 02:41:56 +0000zmt00(~zmt00@user/zmt00)
2024-06-26 02:49:05 +0000td_(~td@i53870933.versanet.de) (Ping timeout: 252 seconds)
2024-06-26 02:51:08 +0000td_(~td@i53870920.versanet.de)
2024-06-26 02:54:15 +0000glguy(g@libera/staff/glguy)
2024-06-26 03:11:11 +0000xff0x(~xff0x@125x103x176x34.ap125.ftth.ucom.ne.jp)
2024-06-26 03:15:08 +0000CrunchyFlakes(~CrunchyFl@ip92348280.dynamic.kabel-deutschland.de) (Read error: Connection reset by peer)
2024-06-26 03:17:39 +0000CrunchyFlakes(~CrunchyFl@ip92348280.dynamic.kabel-deutschland.de)
2024-06-26 03:18:45 +0000euleritian(~euleritia@dynamic-176-001-135-109.176.1.pool.telefonica.de)
2024-06-26 03:23:17 +0000euleritian(~euleritia@dynamic-176-001-135-109.176.1.pool.telefonica.de) (Ping timeout: 256 seconds)
2024-06-26 03:24:15 +0000euleritian(~euleritia@dynamic-176-007-155-229.176.7.pool.telefonica.de)
2024-06-26 03:37:30 +0000bitdex(~bitdex@gateway/tor-sasl/bitdex)
2024-06-26 03:38:11 +0000aforemny_(~aforemny@2001:9e8:6cc2:bc00:8b6d:59f0:33e:e82a)
2024-06-26 03:38:50 +0000MelMalikReinhilde
2024-06-26 03:39:07 +0000aforemny(~aforemny@2001:9e8:6cdd:b100:c11c:c2a2:7e21:6fd9) (Ping timeout: 246 seconds)
2024-06-26 03:43:27 +0000CiaoSen(~Jura@2a05:5800:2d8:3a00:e6b9:7aff:fe80:3d03) (Ping timeout: 264 seconds)
2024-06-26 03:46:40 +0000euleritian(~euleritia@dynamic-176-007-155-229.176.7.pool.telefonica.de) (Read error: Connection reset by peer)
2024-06-26 03:47:57 +0000euleritian(~euleritia@ip4d16fc38.dynamic.kabel-deutschland.de)
2024-06-26 03:57:22 +0000 <edrx> pavonia: thanks =)
2024-06-26 03:57:49 +0000edrx(~Eduardo@170-233-51-85.static.sumicity.net.br) (Killed buffer)
2024-06-26 04:07:08 +0000wbooze(~wbooze@2a02:908:1244:9a20:3ca9:9685:6335:ca5e) (Remote host closed the connection)
2024-06-26 04:09:48 +0000zzz(~yin@user/zero) (Ping timeout: 268 seconds)
2024-06-26 04:11:41 +0000zzz(~yin@user/zero)
2024-06-26 04:19:06 +0000rosco(~rosco@175.136.155.137) (Quit: Lost terminal)
2024-06-26 04:22:02 +0000vizimajac(vizimajac@shell.xshellz.com) (Remote host closed the connection)
2024-06-26 04:27:18 +0000zzz(~yin@user/zero) (Ping timeout: 255 seconds)
2024-06-26 04:29:55 +0000joeyadams(~joeyadams@2603:6010:5100:2ed:c9:f4bd:32a:187d) (Quit: Leaving)
2024-06-26 04:32:56 +0000takuan(~takuan@178-116-218-225.access.telenet.be)
2024-06-26 04:34:01 +0000zzz(~yin@user/zero)
2024-06-26 04:43:58 +0000ss4(~wootehfoo@user/wootehfoot) (Read error: Connection reset by peer)
2024-06-26 04:53:35 +0000 <monochrom> I have been using ASCII art to show the equiv of that kind of underbrace diagrams.
2024-06-26 04:54:34 +0000 <monochrom> For example when explaining "map (map f)" and "pure f <*> x <*> y <*> z <*> ..."
2024-06-26 04:58:20 +0000philopsos1(~caecilius@user/philopsos) (Ping timeout: 252 seconds)
2024-06-26 04:58:23 +0000 <haskellbridge> <iqubic (she/her)> Isn't that second one just "lift2A" but expanded to many more args?
2024-06-26 04:59:22 +0000 <monochrom> Yes.
2024-06-26 04:59:23 +0000aaronv(~aaronv@user/aaronv)
2024-06-26 04:59:35 +0000talismanick(~user@2601:644:937c:ed10::ae5)
2024-06-26 04:59:42 +0000 <monochrom> Well, yes if s/just//
2024-06-26 05:00:12 +0000 <haskellbridge> <iqubic (she/her)> "pure f <_> x <_> y <_> z <_>..." is of type "Applicative f => a (a -> b -> c -> ...) -> f a -> f b -> f c -> ..."
2024-06-26 05:00:37 +0000 <haskellbridge> <iqubic (she/her)> Erm... "Applicative f => (a -> b -> c -> ...) -> f a -> f b -> f c -> ..."
2024-06-26 05:08:10 +0000philopsos1(~caecilius@user/philopsos)
2024-06-26 05:23:11 +0000zzz(~yin@user/zero) (Ping timeout: 268 seconds)
2024-06-26 05:30:02 +0000 <EvanR> oof at all that quadraticness of large records
2024-06-26 05:30:10 +0000Sgeo(~Sgeo@user/sgeo) (Read error: Connection reset by peer)
2024-06-26 05:33:23 +0000 <haskellbridge> <iqubic (she/her)> Where does that come from?
2024-06-26 05:45:21 +0000acidjnk_new3(~acidjnk@p200300d6e714dc96bd88011075acd305.dip0.t-ipconnect.de)
2024-06-26 05:45:28 +0000notzmv(~daniel@user/notzmv) (Ping timeout: 246 seconds)
2024-06-26 05:48:15 +0000ft(~ft@p4fc2ab80.dip0.t-ipconnect.de) (Quit: leaving)
2024-06-26 05:54:28 +0000aaronv(~aaronv@user/aaronv) (Remote host closed the connection)
2024-06-26 05:54:52 +0000aaronv(~aaronv@user/aaronv)
2024-06-26 06:05:42 +0000generalbigm(~generalbi@2001:250:3c0f:2000::e751)
2024-06-26 06:08:51 +0000tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
2024-06-26 06:13:45 +0000wbooze(~wbooze@2a02:908:1244:9a20:c630:9087:3a08:eaac)
2024-06-26 06:18:38 +0000tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2024-06-26 06:20:34 +0000raym(~ray@user/raym) (Quit: rebooting...)
2024-06-26 06:26:21 +0000killy(~killy@staticline-31-183-185-9.toya.net.pl)
2024-06-26 06:27:29 +0000michalz(~michalz@185.246.207.205)
2024-06-26 06:28:23 +0000tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
2024-06-26 06:40:05 +0000rosco(~rosco@175.136.155.137)
2024-06-26 06:42:32 +0000lortabac(~lortabac@2a01:e0a:541:b8f0:55ab:e185:7f81:54a4)
2024-06-26 07:03:05 +0000euleritian(~euleritia@ip4d16fc38.dynamic.kabel-deutschland.de) (Ping timeout: 268 seconds)
2024-06-26 07:03:17 +0000tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2024-06-26 07:03:19 +0000euleritian(~euleritia@dynamic-176-007-144-132.176.7.pool.telefonica.de)
2024-06-26 07:08:02 +0000sord937(~sord937@gateway/tor-sasl/sord937)
2024-06-26 07:09:01 +0000generalbigm1(~generalbi@2001:250:3c0f:2000::e751)
2024-06-26 07:09:15 +0000generalbigm(~generalbi@2001:250:3c0f:2000::e751) (Ping timeout: 264 seconds)
2024-06-26 07:09:39 +0000pointlessslippe1(~pointless@212.82.82.3)
2024-06-26 07:11:19 +0000pavonia(~user@user/siracusa) (Quit: Bye!)
2024-06-26 07:11:34 +0000johnny54(~johnny@2401:e180:8d50:3483:9060:7f14:5c50:80ae)
2024-06-26 07:23:38 +0000euleritian(~euleritia@dynamic-176-007-144-132.176.7.pool.telefonica.de) (Read error: Connection reset by peer)
2024-06-26 07:23:56 +0000euleritian(~euleritia@77.22.252.56)
2024-06-26 07:25:51 +0000tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
2024-06-26 07:33:07 +0000johnny54(~johnny@2401:e180:8d50:3483:9060:7f14:5c50:80ae) (Quit: Client closed)
2024-06-26 07:36:07 +0000poscat0x04(~poscat@user/poscat) (Quit: Bye)
2024-06-26 07:38:25 +0000poscat(~poscat@user/poscat)
2024-06-26 07:40:43 +0000tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Read error: Connection reset by peer)
2024-06-26 07:43:53 +0000euleritian(~euleritia@77.22.252.56) (Ping timeout: 252 seconds)
2024-06-26 07:44:40 +0000euleritian(~euleritia@dynamic-176-007-144-132.176.7.pool.telefonica.de)
2024-06-26 07:55:30 +0000philopsos1(~caecilius@user/philopsos) (Ping timeout: 268 seconds)
2024-06-26 07:56:58 +0000notzmv(~daniel@user/notzmv)
2024-06-26 07:57:20 +0000rosco(~rosco@175.136.155.137) (Quit: Lost terminal)
2024-06-26 07:58:07 +0000machinedgod(~machinedg@d173-183-246-216.abhsia.telus.net)
2024-06-26 08:02:38 +0000vizimajac(~Rodney@97e7368c.skybroadband.com)
2024-06-26 08:05:41 +0000generalbigm1(~generalbi@2001:250:3c0f:2000::e751) (Ping timeout: 268 seconds)
2024-06-26 08:13:51 +0000talismanick(~user@2601:644:937c:ed10::ae5) (Remote host closed the connection)
2024-06-26 08:16:58 +0000RiXSon(~rixson@77-234-86-141.pool.digikabel.hu)
2024-06-26 08:21:32 +0000lxsameer(~lxsameer@Serene/lxsameer)
2024-06-26 08:23:22 +0000generalbigm(~generalbi@2001:250:3c0f:2000::e751)
2024-06-26 08:25:47 +0000chele(~chele@user/chele)
2024-06-26 08:26:57 +0000aaronv(~aaronv@user/aaronv) (Ping timeout: 268 seconds)
2024-06-26 08:27:41 +0000danse-nr3(~danse-nr3@151.43.199.86)
2024-06-26 08:29:45 +0000aaronv(~aaronv@user/aaronv)
2024-06-26 08:35:53 +0000cfricke(~cfricke@user/cfricke)
2024-06-26 08:39:47 +0000rosco(~rosco@175.136.155.137)
2024-06-26 08:46:32 +0000YoungFrog(~youngfrog@2a02:a03f:c9db:fc00:51d9:348e:70e7:cc59)
2024-06-26 08:52:16 +0000poscat(~poscat@user/poscat) (Quit: Bye)
2024-06-26 08:52:27 +0000__monty__(~toonn@user/toonn)
2024-06-26 08:53:01 +0000Unicorn_Princess(~Unicorn_P@user/Unicorn-Princess/x-3540542)
2024-06-26 08:56:06 +0000euleritian(~euleritia@dynamic-176-007-144-132.176.7.pool.telefonica.de) (Read error: Connection reset by peer)
2024-06-26 08:56:37 +0000euleritian(~euleritia@ip4d16fc38.dynamic.kabel-deutschland.de)
2024-06-26 08:57:23 +0000causal(~eric@50.35.88.207)
2024-06-26 09:16:10 +0000gehmehgeh(~user@user/gehmehgeh)
2024-06-26 09:19:36 +0000ubert(~Thunderbi@2a02:8109:ab8a:5a00:1824:df35:e28:ab6b)
2024-06-26 09:20:26 +0000gehmehgehgmg
2024-06-26 09:22:49 +0000poscat(~poscat@user/poscat)
2024-06-26 09:24:10 +0000ubert(~Thunderbi@2a02:8109:ab8a:5a00:1824:df35:e28:ab6b) (Remote host closed the connection)
2024-06-26 09:24:22 +0000ubert(~Thunderbi@2a02:8109:ab8a:5a00:f376:2bd9:f376:d9df)
2024-06-26 09:27:20 +0000talismanick(~user@2601:644:937c:ed10::ae5)
2024-06-26 09:30:26 +0000Miroboru(~myrvoll@178-164-114.82.3p.ntebredband.no)
2024-06-26 09:33:53 +0000poscat(~poscat@user/poscat) (Quit: Bye)
2024-06-26 09:34:08 +0000poscat(~poscat@user/poscat)
2024-06-26 09:39:15 +0000 <lxsameer> hey folks, is there any ready to use functionality to collect a list of computations run them and pass the result of each of them after an automatic error handling to the next one? it should be thread safe
2024-06-26 09:39:45 +0000econo_(uid147250@id-147250.tinside.irccloud.com) (Quit: Connection closed for inactivity)
2024-06-26 09:40:41 +0000poscat(~poscat@user/poscat) (Quit: Bye)
2024-06-26 09:41:49 +0000 <ncf> traverse
2024-06-26 09:43:19 +0000 <ncf> oh, pass the result. then foldr (>=>) pure i guess?
2024-06-26 09:43:24 +0000tzh(~tzh@c-76-115-131-146.hsd1.or.comcast.net) (Quit: zzz)
2024-06-26 09:44:04 +0000poscat(~poscat@user/poscat)
2024-06-26 09:44:44 +0000 <lxsameer> ncf: what about the error handling part
2024-06-26 09:45:01 +0000 <ncf> ExceptT
2024-06-26 09:45:50 +0000aaronv(~aaronv@user/aaronv) (Remote host closed the connection)
2024-06-26 09:45:57 +0000 <lxsameer> thank you
2024-06-26 09:46:14 +0000aaronv(~aaronv@user/aaronv)
2024-06-26 09:46:53 +0000 <hc> What exactly do you mean by "thread safe" in this context?
2024-06-26 09:50:39 +0000 <lxsameer> hc: I want to have a few threads all running a list of computation. on error, i want to know which thread and which computation raised that error. so some sort of coordination between threads is needed
2024-06-26 09:54:37 +0000 <__monty__> But if each thread needs the results of the previous computation why are there threads and what would not be thread safe?
2024-06-26 09:57:46 +0000aforemny_(~aforemny@2001:9e8:6cc2:bc00:8b6d:59f0:33e:e82a) (Quit: ZNC 1.8.2 - https://znc.in)
2024-06-26 09:57:54 +0000 <lxsameer> __monty__: let's say I need to create 4 list of jobs, each list runs in a thread, I need a 5th thread to act as a coordinator. receive certain errors from the threads and decide what to do with it. (local errors that are trivial can be handled in the theard)
2024-06-26 09:58:08 +0000aforemny(~aforemny@i59F516D5.versanet.de)
2024-06-26 10:11:17 +0000xff0x(~xff0x@125x103x176x34.ap125.ftth.ucom.ne.jp) (Ping timeout: 252 seconds)
2024-06-26 10:14:04 +0000lortabac(~lortabac@2a01:e0a:541:b8f0:55ab:e185:7f81:54a4) (Quit: WeeChat 4.2.2)
2024-06-26 10:18:03 +0000aaronv(~aaronv@user/aaronv) (Ping timeout: 260 seconds)
2024-06-26 10:24:44 +0000vizimajac(~Rodney@97e7368c.skybroadband.com) (Ping timeout: 268 seconds)
2024-06-26 10:28:26 +0000cfricke(~cfricke@user/cfricke) (Quit: WeeChat 4.2.2)
2024-06-26 10:42:55 +0000nickiminjaj(~nickiminj@user/laxhh)
2024-06-26 10:43:06 +0000sawilagar(~sawilagar@user/sawilagar)
2024-06-26 11:05:02 +0000nickiminjaj(~nickiminj@user/laxhh) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2024-06-26 11:14:33 +0000nickiminjaj(~nickiminj@user/laxhh)
2024-06-26 11:14:49 +0000danse-nr3(~danse-nr3@151.43.199.86) (Ping timeout: 246 seconds)
2024-06-26 11:14:58 +0000nickiminjaj(~nickiminj@user/laxhh) (Client Quit)
2024-06-26 11:15:47 +0000lortabac(~lortabac@2a01:e0a:541:b8f0:55ab:e185:7f81:54a4)
2024-06-26 11:16:41 +0000xff0x(~xff0x@2405:6580:b080:900:374:70e:871e:8e7b)
2024-06-26 11:21:28 +0000talismanick(~user@2601:644:937c:ed10::ae5) (Ping timeout: 268 seconds)
2024-06-26 11:27:09 +0000raym(~ray@user/raym)
2024-06-26 11:27:48 +0000kuribas(~user@ip-188-118-57-242.reverse.destiny.be)
2024-06-26 11:37:59 +0000spaded(~spaded@2a01:cb11:8072:832f:4262:16e4:2abb:aec0)
2024-06-26 11:38:29 +0000Wstfgl0(~me-me@kc.randomserver.name)
2024-06-26 11:38:33 +0000Me-me(~me-me@user/me-me) (Read error: Connection reset by peer)
2024-06-26 11:38:38 +0000Wstfgl0Me-me
2024-06-26 11:38:43 +0000Pixi`(~Pixi@user/pixi)
2024-06-26 11:41:49 +0000Pixi(~Pixi@user/pixi) (Ping timeout: 256 seconds)
2024-06-26 11:46:12 +0000tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
2024-06-26 12:02:39 +0000destituion(~destituio@2a02:2121:6cb:fbc3:21bb:ad80:8df2:7677) (Ping timeout: 264 seconds)
2024-06-26 12:03:40 +0000destituion(~destituio@85.221.111.174)
2024-06-26 12:06:39 +0000tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2024-06-26 12:12:11 +0000danse-nr3(~danse-nr3@151.43.199.50)
2024-06-26 12:16:46 +0000wbooze(~wbooze@2a02:908:1244:9a20:c630:9087:3a08:eaac) (Remote host closed the connection)
2024-06-26 12:17:03 +0000tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
2024-06-26 12:17:14 +0000wbooze(~wbooze@2a02:908:1244:9a20:e9e0:ebc4:94b1:46e6)
2024-06-26 12:25:36 +0000danse-nr3(~danse-nr3@151.43.199.50) (Ping timeout: 268 seconds)
2024-06-26 12:25:53 +0000danse-nr3(~danse-nr3@151.46.210.141)
2024-06-26 12:42:20 +0000sawilagar(~sawilagar@user/sawilagar) (Remote host closed the connection)
2024-06-26 12:42:34 +0000sawilagar(~sawilagar@user/sawilagar)
2024-06-26 12:45:54 +0000machinedgod(~machinedg@d173-183-246-216.abhsia.telus.net) (Ping timeout: 256 seconds)
2024-06-26 13:01:22 +0000TactfulCitrus(al@gateway/vpn/protonvpn/tactfulcitrus) (Ping timeout: 268 seconds)
2024-06-26 13:13:05 +0000killy(~killy@staticline-31-183-185-9.toya.net.pl) (Ping timeout: 268 seconds)
2024-06-26 13:13:24 +0000mechap(~mechap@user/mechap)
2024-06-26 13:19:33 +0000zzz(~yin@user/zero)
2024-06-26 13:21:25 +0000spaded(~spaded@2a01:cb11:8072:832f:4262:16e4:2abb:aec0) (Quit: Leaving)
2024-06-26 13:32:11 +0000lortabac(~lortabac@2a01:e0a:541:b8f0:55ab:e185:7f81:54a4) (Quit: WeeChat 4.2.2)
2024-06-26 13:34:09 +0000euleritian(~euleritia@ip4d16fc38.dynamic.kabel-deutschland.de) (Ping timeout: 256 seconds)
2024-06-26 13:35:34 +0000bitdex(~bitdex@gateway/tor-sasl/bitdex) (Ping timeout: 260 seconds)
2024-06-26 13:37:06 +0000euleritian(~euleritia@dynamic-176-007-173-172.176.7.pool.telefonica.de)
2024-06-26 13:37:13 +0000bitdex(~bitdex@gateway/tor-sasl/bitdex)
2024-06-26 13:37:41 +0000gorignak(~gorignak@user/gorignak)
2024-06-26 13:37:48 +0000tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2024-06-26 13:41:06 +0000RedFlamingos(~RedFlamin@user/RedFlamingos) (Read error: Connection reset by peer)
2024-06-26 13:43:11 +0000wbooze(~wbooze@2a02:908:1244:9a20:e9e0:ebc4:94b1:46e6) (Quit: Konversation terminated!)
2024-06-26 13:44:32 +0000wbooze(~wbooze@2a02:908:1244:9a20:e9e0:ebc4:94b1:46e6)
2024-06-26 13:46:18 +0000wbooze(~wbooze@2a02:908:1244:9a20:e9e0:ebc4:94b1:46e6) (Remote host closed the connection)
2024-06-26 13:46:50 +0000wbooze(~wbooze@2a02:908:1244:9a20:e9e0:ebc4:94b1:46e6)
2024-06-26 13:47:37 +0000danse-nr3(~danse-nr3@151.46.210.141) (Ping timeout: 256 seconds)
2024-06-26 13:48:35 +0000wbooze(~wbooze@2a02:908:1244:9a20:e9e0:ebc4:94b1:46e6) (Remote host closed the connection)
2024-06-26 13:49:12 +0000ystael(~ystael@user/ystael)
2024-06-26 13:49:58 +0000wbooze(~wbooze@2a02:908:1244:9a20:e9e0:ebc4:94b1:46e6)
2024-06-26 13:51:44 +0000wbooze(~wbooze@2a02:908:1244:9a20:e9e0:ebc4:94b1:46e6) (Remote host closed the connection)
2024-06-26 13:52:42 +0000wbooze(~wbooze@2a02:908:1244:9a20:e9e0:ebc4:94b1:46e6)
2024-06-26 13:53:47 +0000jespada(~jespada@cpc121308-nmal25-2-0-cust15.19-2.cable.virginm.net) (Ping timeout: 268 seconds)
2024-06-26 13:55:43 +0000jespada(~jespada@148.252.129.210)
2024-06-26 13:56:59 +0000zzz(~yin@user/zero) (Ping timeout: 264 seconds)
2024-06-26 14:03:16 +0000zzz(~yin@user/zero)
2024-06-26 14:05:54 +0000jespada(~jespada@148.252.129.210) (Read error: Connection reset by peer)
2024-06-26 14:06:34 +0000RedFlamingos(~RedFlamin@user/RedFlamingos)
2024-06-26 14:08:01 +0000jespada(~jespada@cpc121308-nmal25-2-0-cust15.19-2.cable.virginm.net)
2024-06-26 14:18:14 +0000soverysour(~soverysou@81.196.150.219)
2024-06-26 14:18:14 +0000soverysour(~soverysou@81.196.150.219) (Changing host)
2024-06-26 14:18:14 +0000soverysour(~soverysou@user/soverysour)
2024-06-26 14:20:59 +0000zzz(~yin@user/zero) (Ping timeout: 252 seconds)
2024-06-26 14:27:38 +0000zzz(~yin@user/zero)
2024-06-26 14:28:05 +0000soverysour(~soverysou@user/soverysour) (Ping timeout: 240 seconds)
2024-06-26 14:36:56 +0000zzz(~yin@user/zero) (Ping timeout: 252 seconds)
2024-06-26 14:37:16 +0000madhavanmiui(~madhavanm@2409:40f4:2047:95da:8000::)
2024-06-26 14:38:25 +0000madhavanmiui(~madhavanm@2409:40f4:2047:95da:8000::) (Remote host closed the connection)
2024-06-26 14:43:41 +0000tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
2024-06-26 14:49:53 +0000jespada_(~jespada@cpc121308-nmal25-2-0-cust15.19-2.cable.virginm.net)
2024-06-26 14:51:17 +0000jespada(~jespada@cpc121308-nmal25-2-0-cust15.19-2.cable.virginm.net) (Ping timeout: 240 seconds)
2024-06-26 14:56:04 +0000euleritian(~euleritia@dynamic-176-007-173-172.176.7.pool.telefonica.de) (Ping timeout: 268 seconds)
2024-06-26 14:57:08 +0000Domitar(~Domitar@193.198.16.218)
2024-06-26 14:58:12 +0000waleee(~waleee@h-176-10-144-38.NA.cust.bahnhof.se)
2024-06-26 15:00:15 +0000destituion(~destituio@85.221.111.174) (Ping timeout: 264 seconds)
2024-06-26 15:00:38 +0000Domitar(~Domitar@193.198.16.218) (Remote host closed the connection)
2024-06-26 15:04:11 +0000euleritian(~euleritia@176.2.68.45)
2024-06-26 15:07:02 +0000EvanR(~EvanR@user/evanr) (Quit: Leaving)
2024-06-26 15:07:09 +0000generalbigm(~generalbi@2001:250:3c0f:2000::e751) (Quit: Leaving.)
2024-06-26 15:11:52 +0000destituion(~destituio@2a02:2121:6cb:fbc3:3c0f:94ae:6844:a1fa)
2024-06-26 15:11:54 +0000euleritian(~euleritia@176.2.68.45) (Read error: Connection reset by peer)
2024-06-26 15:13:14 +0000EvanR(~EvanR@user/evanr)
2024-06-26 15:13:35 +0000euleritian(~euleritia@77.22.252.56)
2024-06-26 15:14:55 +0000EvanR(~EvanR@user/evanr) (Client Quit)
2024-06-26 15:18:59 +0000waleee(~waleee@h-176-10-144-38.NA.cust.bahnhof.se) (Ping timeout: 256 seconds)
2024-06-26 15:21:34 +0000EvanR(~EvanR@user/evanr)
2024-06-26 15:22:38 +0000zzz(~yin@user/zero)
2024-06-26 15:27:49 +0000MrFox(~MrFox___@95-178-186-21.dsl.optinet.hr)
2024-06-26 15:31:25 +0000tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2024-06-26 15:33:54 +0000pavonia(~user@user/siracusa)
2024-06-26 15:37:28 +0000soverysour(~soverysou@81.196.150.219)
2024-06-26 15:37:28 +0000soverysour(~soverysou@81.196.150.219) (Changing host)
2024-06-26 15:37:28 +0000soverysour(~soverysou@user/soverysour)
2024-06-26 15:38:00 +0000euleritian(~euleritia@77.22.252.56) (Ping timeout: 268 seconds)
2024-06-26 15:38:36 +0000euleritian(~euleritia@176.2.68.45)
2024-06-26 15:38:43 +0000tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
2024-06-26 15:51:23 +0000soverysour(~soverysou@user/soverysour) (Ping timeout: 272 seconds)
2024-06-26 15:56:26 +0000MrFox(~MrFox___@95-178-186-21.dsl.optinet.hr) (Quit: Leaving)
2024-06-26 15:56:39 +0000soverysour(~soverysou@user/soverysour)
2024-06-26 15:57:31 +0000rosco(~rosco@175.136.155.137) (Quit: Lost terminal)
2024-06-26 15:58:25 +0000chele(~chele@user/chele) (Remote host closed the connection)
2024-06-26 16:01:26 +0000soverysour(~soverysou@user/soverysour) (Remote host closed the connection)
2024-06-26 16:01:49 +0000soverysour(~soverysou@user/soverysour)
2024-06-26 16:02:35 +0000jespada(~jespada@cpc121308-nmal25-2-0-cust15.19-2.cable.virginm.net)
2024-06-26 16:05:15 +0000jespada_(~jespada@cpc121308-nmal25-2-0-cust15.19-2.cable.virginm.net) (Ping timeout: 255 seconds)
2024-06-26 16:06:59 +0000soverysour(~soverysou@user/soverysour) (Ping timeout: 268 seconds)
2024-06-26 16:08:42 +0000kuribas(~user@ip-188-118-57-242.reverse.destiny.be) (Remote host closed the connection)
2024-06-26 16:19:23 +0000soverysour(~soverysou@user/soverysour)
2024-06-26 16:28:32 +0000Tuplanolla(~Tuplanoll@91-159-69-59.elisa-laajakaista.fi)
2024-06-26 16:32:00 +0000ft(~ft@p4fc2ab80.dip0.t-ipconnect.de)
2024-06-26 16:35:24 +0000econo_(uid147250@id-147250.tinside.irccloud.com)
2024-06-26 16:49:19 +0000waleee(~waleee@h-176-10-144-38.NA.cust.bahnhof.se)
2024-06-26 16:51:37 +0000 <Franciman> hi, does haskell have first class support for knowledge graphs?
2024-06-26 16:53:16 +0000 <haskellbridge> <sm> hi Franciman , what would that look like ?
2024-06-26 16:53:27 +0000machinedgod(~machinedg@d173-183-246-216.abhsia.telus.net)
2024-06-26 16:54:32 +0000 <Franciman> hi @sm, base level would be supporting rdf as a format
2024-06-26 16:54:34 +0000 <Franciman> and i see
2024-06-26 16:54:37 +0000 <Franciman> @package rdf
2024-06-26 16:54:37 +0000 <lambdabot> https://hackage.haskell.org/package/rdf
2024-06-26 16:54:58 +0000 <haskellbridge> <sm> ah.. yes
2024-06-26 16:55:01 +0000 <Franciman> but is there libraries for supporting reasoning?
2024-06-26 16:55:04 +0000 <Franciman> with ontologies
2024-06-26 16:55:34 +0000 <Franciman> or queries
2024-06-26 16:55:38 +0000 <Franciman> for example conjunctive queries
2024-06-26 16:55:46 +0000 <duncan> there is a minikanren
2024-06-26 16:56:56 +0000 <haskellbridge> <sm> I don't know if https://flora.pm/packages/@hackage/hsparql is relevant
2024-06-26 16:57:06 +0000ubert(~Thunderbi@2a02:8109:ab8a:5a00:f376:2bd9:f376:d9df) (Remote host closed the connection)
2024-06-26 16:57:13 +0000 <haskellbridge> <sm> or https://flora.pm/packages/@hackage/XSaiga
2024-06-26 16:57:58 +0000 <Franciman> thanks a lot @sm
2024-06-26 16:58:01 +0000 <haskellbridge> <sm> which use http://robstewart57.github.io/rdf4h/
2024-06-26 16:58:24 +0000 <Franciman> what is this flora.pm?
2024-06-26 16:58:30 +0000 <Franciman> is it a mirror for hackage?
2024-06-26 16:58:41 +0000tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2024-06-26 16:58:48 +0000 <haskellbridge> <sm> an alternate UI/mirror, yes
2024-06-26 16:59:58 +0000 <haskellbridge> <sm> I switched to it just now to get a more stable page layout
2024-06-26 17:00:13 +0000 <Franciman> kewl
2024-06-26 17:19:56 +0000tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
2024-06-26 17:21:59 +0000danse-nr3(~danse-nr3@151.46.175.239)
2024-06-26 17:24:06 +0000killy(~killy@staticline-31-183-139-249.toya.net.pl)
2024-06-26 17:29:00 +0000machinedgod(~machinedg@d173-183-246-216.abhsia.telus.net) (Ping timeout: 268 seconds)
2024-06-26 17:46:41 +0000wlhn(~wlhn@dl46fx8ym7lwsvqknt7by-3.rev.dnainternet.fi) (Quit: Leaving)
2024-06-26 17:47:35 +0000CrunchyFlakes(~CrunchyFl@ip92348280.dynamic.kabel-deutschland.de) (Read error: Connection reset by peer)
2024-06-26 17:47:43 +0000danse-nr3(~danse-nr3@151.46.175.239) (Remote host closed the connection)
2024-06-26 17:48:06 +0000danse-nr3(~danse-nr3@151.46.175.239)
2024-06-26 17:50:03 +0000CrunchyFlakes(~CrunchyFl@ip92348280.dynamic.kabel-deutschland.de)
2024-06-26 17:53:52 +0000target_i(~target_i@user/target-i/x-6023099)
2024-06-26 18:00:53 +0000tzh(~tzh@c-76-115-131-146.hsd1.or.comcast.net)
2024-06-26 18:02:15 +0000killy(~killy@staticline-31-183-139-249.toya.net.pl) (Ping timeout: 255 seconds)
2024-06-26 18:02:23 +0000andrewboltachev(~andrey@178.141.121.180) (Ping timeout: 264 seconds)
2024-06-26 18:08:38 +0000dsrt^(~cd@c-98-242-74-66.hsd1.ga.comcast.net)
2024-06-26 18:12:15 +0000Lord_of_Life_(~Lord@user/lord-of-life/x-2819915)
2024-06-26 18:13:30 +0000Lord_of_Life(~Lord@user/lord-of-life/x-2819915) (Ping timeout: 255 seconds)
2024-06-26 18:13:35 +0000Lord_of_Life_Lord_of_Life
2024-06-26 18:17:41 +0000euleritian(~euleritia@176.2.68.45) (Ping timeout: 272 seconds)
2024-06-26 18:18:40 +0000euleritian(~euleritia@dynamic-176-001-226-189.176.1.pool.telefonica.de)
2024-06-26 18:49:14 +0000wootehfoot(~wootehfoo@user/wootehfoot)
2024-06-26 18:57:16 +0000euleritian(~euleritia@dynamic-176-001-226-189.176.1.pool.telefonica.de) (Read error: Connection reset by peer)
2024-06-26 18:57:39 +0000euleritian(~euleritia@77.22.252.56)
2024-06-26 19:10:41 +0000machinedgod(~machinedg@d173-183-246-216.abhsia.telus.net)
2024-06-26 19:12:46 +0000visilii_(~visilii@213.24.125.202)
2024-06-26 19:13:02 +0000visilii(~visilii@188.254.110.246) (Ping timeout: 252 seconds)
2024-06-26 19:13:23 +0000philopsos1(~caecilius@user/philopsos)
2024-06-26 19:17:09 +0000tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2024-06-26 19:19:35 +0000CiaoSen(~Jura@2a05:5800:2d8:3a00:e6b9:7aff:fe80:3d03)
2024-06-26 19:23:24 +0000kqr(~kqr@static.143.81.108.65.clients.your-server.de)
2024-06-26 19:26:21 +0000sord937(~sord937@gateway/tor-sasl/sord937) (Quit: sord937)
2024-06-26 19:26:50 +0000 <kqr> Hello all! I am making some experiments in Haskell after about a 7 year hiatus from it, and I have one confusion I don't remember having before. I'm intending to use the `assign` function from Control.Lens, so I wanted to check what sort of state type to use. I clicked the MonadState constraint in the Haddocks and ended up in the adjunctions package which defines a State type. So far, so good.
2024-06-26 19:26:53 +0000 <kqr> however, when I want to evalState this State type, it expects me to pass a `Rep g` as the initial input, and I just don't understand what this Representable thing is! Am I going about something backwards?
2024-06-26 19:27:30 +0000noumenon(~noumenon@113.51-175-156.customer.lyse.net) (Quit: Leaving)
2024-06-26 19:29:00 +0000 <haskellbridge> <iqubic (she/her)> You want this, from MTL: https://hackage.haskell.org/package/mtl-2.3.1/docs/Control-Monad-State-Class.html#t:MonadState
2024-06-26 19:29:24 +0000 <ncf> it seems like lens uses its own MonadState from adjunctions, but you can (and should probably) use it with the StateT from transformers/mtl
2024-06-26 19:29:47 +0000 <energizer> defining a function `cartesianProduct xs ys` is there a convention about defining it in terms of recursion on the left or right argument? ie `cartesianProduct _ [] = []` or `cartesianProduct [] _ = []` which is preferred, or does it depend on something?
2024-06-26 19:30:44 +0000 <kqr> ncf, That sounds more like what I remember! Thanks! How can all these State implementations/interfaces be compatible?
2024-06-26 19:31:18 +0000 <haskellbridge> <sm> energizer: I think the rule of thumb is something like, most changeable arguments to the right, to make partial application more convenient
2024-06-26 19:31:26 +0000 <ncf> there is simply a adjunctions.MonadState instance for transformers.StateT
2024-06-26 19:31:50 +0000 <energizer> sm in this case the arguments are symmetric, the only difference is left/right
2024-06-26 19:31:55 +0000 <ncf> energizer: it doesn't really matter as long as you document it, but i would expect that to behave as liftA2 (,)
2024-06-26 19:31:58 +0000 <jackdk> kqr: adjunctions re-exports `MonadState` from mtl, so it's the one you know and remember. It's providing its own monad with an instance.
2024-06-26 19:32:06 +0000 <ncf> > liftA2 (,) [1,2] [3,4]
2024-06-26 19:32:08 +0000 <lambdabot> [(1,3),(1,4),(2,3),(2,4)]
2024-06-26 19:32:10 +0000 <kqr> ncf, Oh, yes, of course. It was a few years ago, as I said. Thank you again!
2024-06-26 19:32:26 +0000 <mauke> energizer: I'd expect recursion on the first argument
2024-06-26 19:38:40 +0000 <energizer> mauke: can you say why?
2024-06-26 19:40:21 +0000philopsos1(~caecilius@user/philopsos) (Ping timeout: 255 seconds)
2024-06-26 19:40:21 +0000 <mauke> https://hackage.haskell.org/package/ghc-internal-9.1001.0/docs/src/GHC.Internal.List.html#zip
2024-06-26 19:42:10 +0000 <energizer> that recurses on both arguments because it has to
2024-06-26 19:44:59 +0000 <mauke> yes, but it starts by checking the first argument first
2024-06-26 19:48:09 +0000tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
2024-06-26 19:50:26 +0000danse-nr3(~danse-nr3@151.46.175.239) (Ping timeout: 252 seconds)
2024-06-26 19:53:09 +0000 <haskellbridge> <iqubic (she/her)> I guess for reasons of like, "it's so easy to do partial application in Haskell", you might want to check the first argument first, and short-circuit if needed. That prevents you from needing to write "flip f" in cases where that's equivalent, just for the extra performance boost.
2024-06-26 20:14:56 +0000philopsos1(~caecilius@user/philopsos)
2024-06-26 20:25:54 +0000wbooze(~wbooze@2a02:908:1244:9a20:e9e0:ebc4:94b1:46e6) (Remote host closed the connection)
2024-06-26 20:29:51 +0000wootehfoot(~wootehfoo@user/wootehfoot) (Read error: Connection reset by peer)
2024-06-26 20:31:45 +0000 <energizer> Supposing it's defined in terms of `cartesianProduct f [] ys = []; cartesianProduct f (x:xs) ys =`, what is `cartesianProduct f xs (y:ys)` equal to? It's not just `cartesianProduct (flip f) (y:ys) xs` because that puts the result in the wrong order. Is there a nice way to express the result?
2024-06-26 20:32:54 +0000wbooze(~wbooze@2a02:908:1244:9a20:3d84:fc89:d93b:3334)
2024-06-26 20:35:04 +0000Xe(~cadey@bras-base-orlnon0609w-grc-21-184-145-123-58.dsl.bell.ca) (Quit: WeeChat 4.2.1)
2024-06-26 20:35:19 +0000Xe(~cadey@bras-base-orlnon0609w-grc-21-184-145-123-58.dsl.bell.ca)
2024-06-26 20:35:29 +0000Xe(~cadey@bras-base-orlnon0609w-grc-21-184-145-123-58.dsl.bell.ca) (Changing host)
2024-06-26 20:35:29 +0000Xe(~cadey@perl/impostor/xe)
2024-06-26 20:37:11 +0000soverysour(~soverysou@user/soverysour) (Ping timeout: 264 seconds)
2024-06-26 20:41:02 +0000lxsameer(~lxsameer@Serene/lxsameer) (Ping timeout: 252 seconds)
2024-06-26 20:45:28 +0000__monty__(~toonn@user/toonn) (Quit: leaving)
2024-06-26 20:48:35 +0000mechap(~mechap@user/mechap) (Quit: WeeChat 4.3.3)
2024-06-26 20:51:31 +0000 <ncf> you mean in terms of cartesianProduct f xs ys? it's going to be some ugly one-in-length-ys-interleaving of f y's
2024-06-26 21:08:50 +0000Miroboru(~myrvoll@178-164-114.82.3p.ntebredband.no) (Quit: Lost terminal)
2024-06-26 21:17:51 +0000Garbanzo(~Garbanzo@2602:304:6eac:dc10::46)
2024-06-26 21:22:24 +0000waleee(~waleee@h-176-10-144-38.NA.cust.bahnhof.se) (Remote host closed the connection)
2024-06-26 21:23:26 +0000phma(~phma@host-67-44-208-116.hnremote.net) (Read error: Connection reset by peer)
2024-06-26 21:24:53 +0000phma(phma@2001:5b0:210f:1ad8:36db:ca4e:16e7:7eb)
2024-06-26 21:25:22 +0000waleee(~waleee@h-176-10-144-38.NA.cust.bahnhof.se)
2024-06-26 21:41:07 +0000target_i(~target_i@user/target-i/x-6023099) (Quit: leaving)
2024-06-26 21:43:34 +0000joeyadams(~joeyadams@2603:6010:5100:2ed:93a8:3ab0:fdc9:ca35)
2024-06-26 21:45:27 +0000dcoutts_(~duncan@2a00:23c6:1c8d:901:b94:4566:9d63:4848) (Ping timeout: 256 seconds)
2024-06-26 21:46:27 +0000lain`(lain@user/lain/x-9874679) (Ping timeout: 264 seconds)
2024-06-26 21:59:11 +0000takuan(~takuan@178-116-218-225.access.telenet.be) (Remote host closed the connection)
2024-06-26 21:59:39 +0000Tuplanolla(~Tuplanoll@91-159-69-59.elisa-laajakaista.fi) (Quit: Leaving.)
2024-06-26 22:07:58 +0000safinaskar(~quassel@212.73.77.104)
2024-06-26 22:08:54 +0000 <safinaskar> hi. i just proved in haskell that (0 + x = x) from (x + 0 = x) and induction https://godbolt.org/z/Tvqdaozoh
2024-06-26 22:09:09 +0000 <safinaskar> i did NOT implement prover in haskell, i used type system of haskell itself as a prover
2024-06-26 22:10:53 +0000 <safinaskar> unfortunately, i just understand that my proof is wrong. type application in haskell is injective, thus in my code (Add (N Z) Z ~ Add Z (N Z)) (this is true) implies (Z ~ N Z) (which is false)
2024-06-26 22:10:59 +0000 <safinaskar> is there a way to fix this?
2024-06-26 22:11:48 +0000 <safinaskar> maybe there is some experimental feature of haskell, which disables type application injectivity?
2024-06-26 22:14:46 +0000 <ncf> it's injective with respect to type equality (~) (in some cases), but it shouldn't be injective with respect to your custom Equal type, should it?
2024-06-26 22:15:16 +0000 <ncf> since you've gone with the weird axiomatic definition instead of the inductive definition with a refl constructor
2024-06-26 22:15:19 +0000 <safinaskar> ncf: hmm, seems correct. thank you!
2024-06-26 22:15:56 +0000 <ncf> i'm not even sure which type families are considered injective. https://ghc.gitlab.haskell.org/ghc/doc/users_guide/exts/type_families.html has some information
2024-06-26 22:15:57 +0000Sgeo(~Sgeo@user/sgeo)
2024-06-26 22:22:41 +0000 <zzz> are typefamilies worth it or can i just get by with "simple" haskell?
2024-06-26 22:24:00 +0000 <monochrom> I'm going to answer tautologically. Type families are worth it when you need type families. You can get by with simple Haskell when simple Haskell suffices.
2024-06-26 22:24:01 +0000acidjnk_new3(~acidjnk@p200300d6e714dc96bd88011075acd305.dip0.t-ipconnect.de) (Ping timeout: 246 seconds)
2024-06-26 22:24:04 +0000tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2024-06-26 22:24:27 +0000 <monochrom> But I will add that I have only ever needed fairly simple Haskell most of the time.
2024-06-26 22:25:14 +0000 <monochrom> But there are times when I miss SML's parametrized modules, and I can use type families to do something similar.
2024-06-26 22:26:12 +0000 <monochrom> i.e., when I want to make some fairly general abstraction.
2024-06-26 22:27:05 +0000 <monochrom> Or IOW when I use type families, it's for general template-like things, not for dependent typing.
2024-06-26 22:27:27 +0000 <EvanR> type synonym family is a fairly simple way to reduce the verbosity of some type level shenanigans, they just expand to some other shenanigan
2024-06-26 22:27:56 +0000 <safinaskar> ncf: unfortunately, no. see: https://godbolt.org/z/xEa54v666 . see "oops1" and "oops2" in the end. unfortunately i was able to prove that my Equal is equivalent to standard haskell equality
2024-06-26 22:27:57 +0000 <EvanR> associated type synonym family in a class can sometimes save you from multi-parameter type classes
2024-06-26 22:28:08 +0000michalz(~michalz@185.246.207.205) (Quit: ZNC 1.9.0 - https://znc.in)
2024-06-26 22:28:27 +0000 <monochrom> Yeah that's what I use them for.
2024-06-26 22:28:30 +0000 <EvanR> for the sake of argument "simple haskell" doesn't have you doing any of those so those don't help
2024-06-26 22:28:53 +0000CiaoSen(~Jura@2a05:5800:2d8:3a00:e6b9:7aff:fe80:3d03) (Ping timeout: 240 seconds)
2024-06-26 22:28:59 +0000 <safinaskar> (and no, i cannot just remove "subst", i use it in proof of "subst2" and i use "subst2" in proof of (0 + x = x) )
2024-06-26 22:28:59 +0000 <ncf> safinaskar: good point
2024-06-26 22:29:11 +0000 <zzz> that was my suspicion
2024-06-26 22:29:29 +0000 <zzz> i barey do any type-level acrobatics
2024-06-26 22:29:51 +0000 <zzz> s/barey/barely
2024-06-26 22:31:31 +0000 <safinaskar> ncf: "i'm not even sure which type families are considered injective" - according to https://hackage.haskell.org/package/base-4.20.0.1/docs/Data-Type-Equality.html#v:inner (f a ~ g b) always implies (a ~ b). but this relies on the fact that we can substitute given type-level function to "f" and "g"
2024-06-26 22:32:04 +0000 <safinaskar> ncf: so the rule is here: all type-level functions, which can be substituted to type-level variables, are injective
2024-06-26 22:32:58 +0000 <safinaskar> ncf: in particular (i checked this using expirement) if we have "type Foo a = ...", then "Foo" cannot be substituted, so "Foo" is not injective. But "Foo a" can be substituted, and thus it is injective
2024-06-26 22:33:21 +0000 <dolio> inner does not say type families are injective, because `f` and `g` do not range over type families.
2024-06-26 22:34:49 +0000 <safinaskar> dolio: i did expirement, and result are so. if i have "type family Foo a :: Type -> Type", then "Foo" cannot be substituted and thus is not injective. but "Foo a" can be substituted and thus injective
2024-06-26 22:35:02 +0000 <safinaskar> dolio: so yes, type families are not injective
2024-06-26 22:35:13 +0000 <safinaskar> type level functions are
2024-06-26 22:35:59 +0000waleee(~waleee@h-176-10-144-38.NA.cust.bahnhof.se) (Ping timeout: 252 seconds)
2024-06-26 22:36:01 +0000 <safinaskar> it seems i found solution. i just need to define "type family Add a b :: Nat", not "type family Add :: Nat -> Nat -> Nat"
2024-06-26 22:36:06 +0000 <safinaskar> cool!
2024-06-26 22:37:47 +0000 <geekosaur> they are if you declare them right (https://downloads.haskell.org/ghc/9.10.1/docs/users_guide/exts/type_families.html#injective-type-f…)
2024-06-26 22:37:59 +0000waleee(~waleee@h-176-10-144-38.NA.cust.bahnhof.se)
2024-06-26 22:44:04 +0000 <safinaskar> zzz: "are typefamilies worth it or can i just get by with "simple" haskell?" - i never needed type families except for this very weird code
2024-06-26 22:47:49 +0000JimL(~quassel@89.162.16.26) (Ping timeout: 268 seconds)
2024-06-26 22:51:09 +0000waleee(~waleee@h-176-10-144-38.NA.cust.bahnhof.se) (Ping timeout: 255 seconds)
2024-06-26 22:53:40 +0000 <safinaskar> ncf: thanks for link. i just slightly have read it. and yes, now i know that type families can be injective if specially annotated. i. e. one can add more injectivity to a program if needed
2024-06-26 22:54:24 +0000 <safinaskar> ncf: but in my case i want less injectivity, not more. and i already know how to do this. "type family Add a b :: Nat" instead of "type family Add :: Nat -> Nat -> Nat"
2024-06-26 22:55:43 +0000 <ncf> (i have no idea why this works)
2024-06-26 23:04:14 +0000 <safinaskar> ncf: i think i know why this works. "type family Add a b :: Nat" is somewhat similar to usual type synonym "type Add a b = ....". they are not injective (because you can easily write "type Add a b = Char"). and thus you should always apply all arguments, i. e. you cannot write (f @Add), you should write (f @(Add a b)). otherwise you could prove injectivity using "Data.Type.Equality.inner"
2024-06-26 23:05:34 +0000 <safinaskar> ncf: and in "type family Add :: Nat -> Nat -> Nat" we have injectivity (because one cannot define non-injective "Add"), thus we can rely on it
2024-06-26 23:13:29 +0000waleee(~waleee@h-176-10-144-38.NA.cust.bahnhof.se)
2024-06-26 23:17:09 +0000 <safinaskar> i found a wrong statement at https://ghc.gitlab.haskell.org/ghc/doc/users_guide/exts/type_families.html
2024-06-26 23:17:23 +0000 <safinaskar> but i will not report bug, because your bug reporting process is too compilected
2024-06-26 23:17:30 +0000 <safinaskar> *complicated
2024-06-26 23:18:07 +0000 <safinaskar> the statement is: "We call the number of parameters in a type family declaration, the family’s arity, and all applications of a type family must be fully saturated with respect to that arity. This requirement is unlike ordinary type synonyms and it implies that the kind of a type family is not sufficient to determine a family’s arity, and hence in general, also insufficient to determine whether a type family application is well formed."
2024-06-26 23:18:31 +0000 <safinaskar> the statement is wrong, because ordinary type synonyms share this property, too (determined by expirement)
2024-06-26 23:19:13 +0000gmg(~user@user/gehmehgeh) (Quit: Leaving)
2024-06-26 23:25:39 +0000Garbanzo(~Garbanzo@2602:304:6eac:dc10::46) (Remote host closed the connection)
2024-06-26 23:39:24 +0000emmanuelux(~emmanuelu@user/emmanuelux)
2024-06-26 23:43:11 +0000zzz(~yin@user/zero) (Ping timeout: 264 seconds)
2024-06-26 23:50:04 +0000zzz(~yin@user/zero)
2024-06-26 23:50:24 +0000xsarnik(xsarnik@lounge.fi.muni.cz) (Quit: Ping timeout (120 seconds))
2024-06-26 23:50:24 +0000xstill_(xstill@fimu/xstill) (Quit: Ping timeout (120 seconds))
2024-06-26 23:50:58 +0000malte(~malte@mal.tc) (Read error: Connection reset by peer)
2024-06-26 23:51:12 +0000malte(~malte@mal.tc)
2024-06-26 23:51:38 +0000rvalue(~rvalue@user/rvalue) (Quit: ZNC - https://znc.in)
2024-06-26 23:51:51 +0000it_(~quassel@v2202212189510211193.supersrv.de) (Quit: No Ping reply in 180 seconds.)
2024-06-26 23:52:00 +0000rvalue(~rvalue@user/rvalue)
2024-06-26 23:52:56 +0000xstill_(xstill@fimu/xstill)
2024-06-26 23:53:15 +0000it_(~quassel@v2202212189510211193.supersrv.de)
2024-06-26 23:53:55 +0000 <davean> safinaskar: why do you think that is wrong? Pretty sure I've defined classes on type synonyms for example
2024-06-26 23:56:04 +0000xsarnik(xsarnik@lounge.fi.muni.cz)
2024-06-26 23:57:58 +0000 <dolio> I don't think you can define classes on synonyms unless it satisfies a similar arity condition to families.
2024-06-26 23:58:24 +0000 <dolio> But LiberalTypeSynonyms let you partially apply them as long as they become saturated, and doesn't allow the same thing to happen with families.