2022/01/27

2022-01-27 00:00:51 +0100azimut(~azimut@gateway/tor-sasl/azimut) (Ping timeout: 276 seconds)
2022-01-27 00:02:30 +0100justsomeguy(~justsomeg@user/justsomeguy) (Ping timeout: 250 seconds)
2022-01-27 00:03:43 +0100_xor(~xor@dsl-50-5-233-169.fuse.net)
2022-01-27 00:05:46 +0100 <EvanR> speaking of lexical issues
2022-01-27 00:06:47 +0100 <EvanR> > Just (-1)
2022-01-27 00:06:48 +0100 <lambdabot> Just (-1)
2022-01-27 00:06:49 +0100mc47(~mc47@xmonad/TheMC47) (Remote host closed the connection)
2022-01-27 00:06:51 +0100 <EvanR> > Just -1
2022-01-27 00:06:52 +0100 <lambdabot> error:
2022-01-27 00:06:52 +0100 <lambdabot> • No instance for (Typeable a0)
2022-01-27 00:06:52 +0100 <lambdabot> arising from a use of ‘show_M56646709495744885058’
2022-01-27 00:06:58 +0100_xor(~xor@dsl-50-5-233-169.fuse.net) (Read error: Connection reset by peer)
2022-01-27 00:07:12 +0100 <geekosaur> % :set -XNegativeLiterals
2022-01-27 00:07:12 +0100 <yahb> geekosaur:
2022-01-27 00:07:15 +0100 <EvanR> with NegativeLiterals that seems to be accepted... but seems weird because I don't know how it's parsing anymore
2022-01-27 00:07:16 +0100 <geekosaur> % Just -1
2022-01-27 00:07:17 +0100 <yahb> geekosaur: Just (-1)
2022-01-27 00:07:27 +0100 <EvanR> % Just-1
2022-01-27 00:07:27 +0100 <yahb> EvanR: ; <interactive>:77:5: error:; * No instance for (Num (a0 -> Maybe a0)) arising from a use of `-'; (maybe you haven't applied a function to enough arguments?); * In the expression: Just - 1; In an equation for `it': it = Just - 1
2022-01-27 00:07:31 +0100 <geekosaur> the extension says how it's parsed iirc
2022-01-27 00:07:53 +0100 <EvanR> for me, Just-1 parses in ghci for me
2022-01-27 00:09:06 +0100 <EvanR> that error is what I get without the extension
2022-01-27 00:09:55 +0100 <geekosaur> % :set -XLexicalNegation
2022-01-27 00:09:55 +0100 <yahb> geekosaur:
2022-01-27 00:09:55 +0100_xor(~xor@dsl-50-5-233-169.fuse.net)
2022-01-27 00:10:01 +0100 <geekosaur> % Just-1
2022-01-27 00:10:01 +0100 <yahb> geekosaur: ; <interactive>:79:5: error:; * No instance for (Num (a0 -> Maybe a0)) arising from a use of `-'; (maybe you haven't applied a function to enough arguments?); * In the expression: Just - 1; In an equation for `it': it = Just - 1
2022-01-27 00:10:22 +0100 <geekosaur> % :set -NoNegativeLiterals
2022-01-27 00:10:22 +0100 <yahb> geekosaur: Some flags have not been recognized: -NoNegativeLiterals
2022-01-27 00:10:32 +0100 <geekosaur> % :set -XNoNegativeLiterals
2022-01-27 00:10:33 +0100 <yahb> geekosaur:
2022-01-27 00:10:36 +0100 <geekosaur> % Just-1
2022-01-27 00:10:36 +0100 <yahb> geekosaur: ; <interactive>:82:5: error:; * No instance for (Num (a0 -> Maybe a0)) arising from a use of `-'; (maybe you haven't applied a function to enough arguments?); * In the expression: Just - 1; In an equation for `it': it = Just - 1
2022-01-27 00:10:41 +0100 <geekosaur> hm
2022-01-27 00:10:47 +0100 <geekosaur> what version you running?
2022-01-27 00:11:04 +0100 <geekosaur> 9.x changed behavior wrt spaces betweek tokens
2022-01-27 00:11:09 +0100 <geekosaur> *between
2022-01-27 00:11:24 +0100Major_Biscuit(~MajorBisc@86-88-79-148.fixed.kpn.net)
2022-01-27 00:12:03 +0100 <EvanR> 8.10.7
2022-01-27 00:12:20 +0100 <EvanR> I see NegativeLiterals didn't get unanimous votes on GHC2021
2022-01-27 00:12:35 +0100 <geekosaur> @let {-# LANGUAGE NegativeLiterals #-}
2022-01-27 00:12:36 +0100 <lambdabot> Defined.
2022-01-27 00:12:44 +0100 <geekosaur> > Just-1
2022-01-27 00:12:45 +0100 <lambdabot> error:
2022-01-27 00:12:45 +0100 <lambdabot> • No instance for (Typeable a0)
2022-01-27 00:12:45 +0100 <lambdabot> arising from a use of ‘show_M63043554762056576148’
2022-01-27 00:12:57 +0100segfaultfizzbuzz(~rustisafu@2602:306:cd3c:9350:59e3:db49:aa0a:46e5) (Ping timeout: 240 seconds)
2022-01-27 00:13:49 +0100TheCoffeMaker(~TheCoffeM@user/thecoffemaker)
2022-01-27 00:14:02 +0100 <geekosaur> @let {-# LANGUAGE LexicalNegation #-}
2022-01-27 00:14:04 +0100 <lambdabot> Defined.
2022-01-27 00:14:06 +0100 <geekosaur> > Just-1
2022-01-27 00:14:08 +0100 <lambdabot> error:
2022-01-27 00:14:08 +0100 <lambdabot> • No instance for (Typeable a0)
2022-01-27 00:14:08 +0100 <lambdabot> arising from a use of ‘show_M45130066487191305358’
2022-01-27 00:14:12 +0100 <geekosaur> weird
2022-01-27 00:14:22 +0100 <geekosaur> @undef
2022-01-27 00:14:23 +0100 <lambdabot> Undefined.
2022-01-27 00:14:41 +0100 <EvanR> it's quite bizarre that this is accepted https://paste.tomsmeding.com/Ppvt93c8 xD
2022-01-27 00:14:55 +0100 <EvanR> for
2022-01-27 00:14:57 +0100 <EvanR> for me
2022-01-27 00:16:04 +0100__monty__(~toonn@user/toonn) (Quit: leaving)
2022-01-27 00:16:17 +0100wroathe(~wroathe@user/wroathe) (Ping timeout: 240 seconds)
2022-01-27 00:18:12 +0100 <dsal> Is there an opinion on `forkIO`? I see it in this codebase I'm working on, though not a lot. It's a bit of a smell to me, but it's not one I recognize very well.
2022-01-27 00:18:48 +0100 <monochrom> I don't know of any opinion against forkIO.
2022-01-27 00:19:05 +0100carbolymerlikes `async` more
2022-01-27 00:19:09 +0100 <EvanR> forkIO is great
2022-01-27 00:19:15 +0100 <EvanR> also async
2022-01-27 00:19:25 +0100_xor(~xor@dsl-50-5-233-169.fuse.net) (Read error: Connection reset by peer)
2022-01-27 00:19:30 +0100 <Axman6> yeah I would probably be looking more at using async so that exceptions are handled more fully
2022-01-27 00:19:32 +0100waleee(~waleee@2001:9b0:21d:fc00:398f:b003:b90d:acf4) (Ping timeout: 240 seconds)
2022-01-27 00:20:12 +0100 <Axman6> but if it's a throwaway thread that it returning or handling exceptions isn't too important, then just forIO and forget
2022-01-27 00:20:17 +0100 <Axman6> forkIO*
2022-01-27 00:20:45 +0100romesrf(~romes@44.190.189.46.rev.vodafone.pt)
2022-01-27 00:20:48 +0100 <carbolymer> you might want to setUncaughtExceptionHandler tho
2022-01-27 00:21:43 +0100waleee(~waleee@h-98-128-229-110.NA.cust.bahnhof.se)
2022-01-27 00:22:06 +0100 <monochrom> So, there can be a very good opinion on forkIO in a context so large that the whole context is reinventing a substantial portion of async, sure.
2022-01-27 00:22:21 +0100 <monochrom> That is still different from an opinion on forkIO period.
2022-01-27 00:22:53 +0100 <EvanR> it's great, period xD
2022-01-27 00:23:46 +0100 <dsal> I don't see any async, but I see forkIO. I see some signs of async being used indirectly.
2022-01-27 00:24:10 +0100TheCoffeMaker(~TheCoffeM@user/thecoffemaker) (Ping timeout: 250 seconds)
2022-01-27 00:24:29 +0100CiaoSen(~Jura@p200300c95737a2002a3a4dfffe84dbd5.dip0.t-ipconnect.de) (Ping timeout: 268 seconds)
2022-01-27 00:24:33 +0100ultsllt(~ultsllt@50.231.5.242) (Remote host closed the connection)
2022-01-27 00:24:41 +0100Major_Biscuit(~MajorBisc@86-88-79-148.fixed.kpn.net) (Ping timeout: 256 seconds)
2022-01-27 00:24:44 +0100wroathe(~wroathe@206-55-188-8.fttp.usinternet.com)
2022-01-27 00:24:44 +0100wroathe(~wroathe@206-55-188-8.fttp.usinternet.com) (Changing host)
2022-01-27 00:24:44 +0100wroathe(~wroathe@user/wroathe)
2022-01-27 00:24:48 +0100 <EvanR> as a library writer it's hard to argue that "this code will always run in a program where there is 1 thread"
2022-01-27 00:25:08 +0100 <EvanR> or an application writer who doesn't know everything about the application yet
2022-01-27 00:25:19 +0100_xor(~xor@dsl-50-5-233-169.fuse.net)
2022-01-27 00:25:35 +0100 <EvanR> luckily a lot of stuff still works when there are forkIO threads
2022-01-27 00:26:42 +0100TheCoffeMaker(~TheCoffeM@user/thecoffemaker)
2022-01-27 00:26:44 +0100 <EvanR> it kind of feels like a default aspect of the haskell environment, like purity and laziness
2022-01-27 00:27:08 +0100 <EvanR> which is why opengl can't be pure
2022-01-27 00:27:11 +0100 <geekosaur> it kinda derives from those, doesn't it?
2022-01-27 00:27:21 +0100_xor(~xor@dsl-50-5-233-169.fuse.net) (Read error: Connection reset by peer)
2022-01-27 00:27:25 +0100 <geekosaur> in particular purity means independence from other threads
2022-01-27 00:27:45 +0100_xor(~xor@dsl-50-5-233-169.fuse.net)
2022-01-27 00:28:43 +0100wombat875(~wombat875@pool-72-89-24-154.nycmny.fios.verizon.net) (Quit: WeeChat 2.2-dev)
2022-01-27 00:29:25 +0100wroathe(~wroathe@user/wroathe) (Ping timeout: 268 seconds)
2022-01-27 00:30:11 +0100imalsogreg(~imalsogre@2601:147:300:f930::ee17) (Remote host closed the connection)
2022-01-27 00:30:55 +0100Ocelot(~ocelot@50-78-208-189-static.hfc.comcastbusiness.net) (Read error: Connection reset by peer)
2022-01-27 00:31:15 +0100CHUD(~CHUD@host-80-41-89-108.as13285.net)
2022-01-27 00:32:07 +0100haskellb1(~nut@roc37-h01-176-170-197-243.dsl.sta.abo.bbox.fr) (Remote host closed the connection)
2022-01-27 00:32:09 +0100Ocelot(~ocelot@50-78-208-189-static.hfc.comcastbusiness.net)
2022-01-27 00:32:11 +0100Tuplanolla(~Tuplanoll@91-159-68-166.elisa-laajakaista.fi) (Quit: Leaving.)
2022-01-27 00:32:37 +0100machinedgod(~machinedg@24.105.81.50) (Ping timeout: 240 seconds)
2022-01-27 00:32:56 +0100_xor(~xor@dsl-50-5-233-169.fuse.net) (Read error: Connection reset by peer)
2022-01-27 00:33:22 +0100_xor(~xor@dsl-50-5-233-169.fuse.net)
2022-01-27 00:33:22 +0100acidsys(~LSD@2.lsd.systems) (Quit: I love you.)
2022-01-27 00:33:37 +0100acidsys(~LSD@2.lsd.systems)
2022-01-27 00:34:58 +0100cosimone(~user@93-44-185-255.ip98.fastwebnet.it) (Ping timeout: 268 seconds)
2022-01-27 00:35:31 +0100_xor(~xor@dsl-50-5-233-169.fuse.net) (Read error: Connection reset by peer)
2022-01-27 00:35:49 +0100_xor(~xor@dsl-50-5-233-169.fuse.net)
2022-01-27 00:36:17 +0100shapr(~user@pool-100-36-247-68.washdc.fios.verizon.net) (Remote host closed the connection)
2022-01-27 00:37:03 +0100shapr(~user@pool-100-36-247-68.washdc.fios.verizon.net)
2022-01-27 00:38:30 +0100segfaultfizzbuzz(~rustisafu@2602:306:cd3c:9350:59e3:db49:aa0a:46e5)
2022-01-27 00:44:03 +0100romesrf(~romes@44.190.189.46.rev.vodafone.pt) (Quit: WeeChat 3.4)
2022-01-27 00:44:37 +0100segfaultfizzbuzz(~rustisafu@2602:306:cd3c:9350:59e3:db49:aa0a:46e5) (Ping timeout: 240 seconds)
2022-01-27 00:44:53 +0100ProfSimm(~ProfSimm@87.227.196.109) (Remote host closed the connection)
2022-01-27 00:50:02 +0100soxen(~bob@pool-173-54-217-168.nwrknj.fios.verizon.net) (Ping timeout: 240 seconds)
2022-01-27 00:53:28 +0100bontaq(~user@ool-45779fe5.dyn.optonline.net) (Ping timeout: 268 seconds)
2022-01-27 00:53:42 +0100merijn(~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl)
2022-01-27 00:55:19 +0100ix(~ix@2a02:8010:674f:0:cda6:d05:f0d7:4922) (Quit: WeeChat 3.4)
2022-01-27 00:55:49 +0100marquis_andras(~marquis_a@124.170.163.166)
2022-01-27 00:55:59 +0100ix(~ix@2a02:8010:674f:0:cda6:d05:f0d7:4922)
2022-01-27 00:56:02 +0100ix(~ix@2a02:8010:674f:0:cda6:d05:f0d7:4922) (Remote host closed the connection)
2022-01-27 00:56:09 +0100ix(~ix@2a02:8010:674f:0:cda6:d05:f0d7:4922)
2022-01-27 00:56:13 +0100ix(~ix@2a02:8010:674f:0:cda6:d05:f0d7:4922) (Remote host closed the connection)
2022-01-27 00:56:28 +0100ix(~ix@2a02:8010:674f:0:cda6:d05:f0d7:4922)
2022-01-27 00:57:41 +0100marquis_andras(~marquis_a@124.170.163.166) (Client Quit)
2022-01-27 00:58:22 +0100yauhsien_(~yauhsien@61-231-17-3.dynamic-ip.hinet.net)
2022-01-27 00:58:24 +0100ProfSimm(~ProfSimm@87.227.196.109)
2022-01-27 00:59:32 +0100zebrag(~chris@user/zebrag) (Quit: Konversation terminated!)
2022-01-27 01:00:40 +0100imalsogreg(~imalsogre@c-73-172-114-3.hsd1.md.comcast.net)
2022-01-27 01:01:45 +0100bb010g(~bb010g@2001:470:69fc:105::9a5) (Quit: Client limit exceeded: 20000)
2022-01-27 01:03:13 +0100yauhsien_(~yauhsien@61-231-17-3.dynamic-ip.hinet.net) (Ping timeout: 256 seconds)
2022-01-27 01:04:42 +0100nomeata(~nomeata@2001:470:69fc:105::1:5ed4) (Quit: Client limit exceeded: 20000)
2022-01-27 01:05:56 +0100jkaye(~jkaye@2601:281:8300:7530:cf1a:5f6d:9faa:a84e)
2022-01-27 01:06:00 +0100marquis_andras(~marquis_a@124.170.163.166)
2022-01-27 01:07:08 +0100marquis_andras(~marquis_a@124.170.163.166) (Client Quit)
2022-01-27 01:07:24 +0100marquis_andras(~marquis_a@124.170.163.166)
2022-01-27 01:08:06 +0100justsomeguy(~justsomeg@user/justsomeguy)
2022-01-27 01:09:55 +0100lbseale_(~ep1ctetus@user/ep1ctetus)
2022-01-27 01:09:55 +0100lbseale_(~ep1ctetus@user/ep1ctetus) (Client Quit)
2022-01-27 01:11:09 +0100mon_aaraj(~MonAaraj@user/mon-aaraj/x-4416475) (Ping timeout: 256 seconds)
2022-01-27 01:13:08 +0100mon_aaraj(~MonAaraj@user/mon-aaraj/x-4416475)
2022-01-27 01:13:59 +0100lbseale(~ep1ctetus@user/ep1ctetus) (Ping timeout: 256 seconds)
2022-01-27 01:16:54 +0100alp(~alp@user/alp) (Ping timeout: 268 seconds)
2022-01-27 01:20:29 +0100segfaultfizzbuzz(~rustisafu@2602:306:cd3c:9350:59e3:db49:aa0a:46e5)
2022-01-27 01:22:51 +0100soxen(~bob@pool-173-54-217-168.nwrknj.fios.verizon.net)
2022-01-27 01:23:17 +0100merijn(~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl) (Ping timeout: 240 seconds)
2022-01-27 01:27:28 +0100max22-(~maxime@2a01cb0883359800ca42cd4ecfb21dbb.ipv6.abo.wanadoo.fr) (Remote host closed the connection)
2022-01-27 01:31:33 +0100Henson(~kvirc@107-179-133-201.cpe.teksavvy.com) (Ping timeout: 256 seconds)
2022-01-27 01:32:19 +0100notzmv(~zmv@user/notzmv) (Ping timeout: 268 seconds)
2022-01-27 01:34:02 +0100vglfr(~vglfr@88.155.70.5) (Ping timeout: 240 seconds)
2022-01-27 01:40:35 +0100little_mac(~little_ma@2601:410:4300:3ce0:dc4e:59ab:7b42:4b50) (Remote host closed the connection)
2022-01-27 01:49:13 +0100jeetelongname(~jeet@88-111-159-26.dynamic.dsl.as9105.com)
2022-01-27 01:53:01 +0100machinedgod(~machinedg@24.105.81.50)
2022-01-27 01:56:14 +0100TonyStone(~TonyStone@2603-7080-8607-c36a-65df-a0f5-02cd-1378.res6.spectrum.com) (Remote host closed the connection)
2022-01-27 01:56:29 +0100 <Axman6> I'm struggling a bit, what would be the church encoded equivalent of data Fold a b = forall x. Fold (x -> a -> Either x (Fold a b)) x (x -> b)?
2022-01-27 01:56:47 +0100bb010g(~bb010g@2001:470:69fc:105::9a5)
2022-01-27 01:57:00 +0100 <Axman6> I have newtype Fold' a b = forall x. Fold' (x -> a -> (x -> r) -> (Fold' a b -> r) -> ((x -> b) -> r) -> r) but I can't tell if that's correct
2022-01-27 01:57:02 +0100nomeata(~nomeata@2001:470:69fc:105::1:5ed4)
2022-01-27 01:57:37 +0100mon_aaraj(~MonAaraj@user/mon-aaraj/x-4416475) (Ping timeout: 256 seconds)
2022-01-27 01:58:05 +0100wroathe(~wroathe@206-55-188-8.fttp.usinternet.com)
2022-01-27 01:58:06 +0100wroathe(~wroathe@206-55-188-8.fttp.usinternet.com) (Changing host)
2022-01-27 01:58:06 +0100wroathe(~wroathe@user/wroathe)
2022-01-27 01:58:34 +0100TonyStone(~TonyStone@cpe-74-76-51-197.nycap.res.rr.com)
2022-01-27 01:58:42 +0100yauhsien_(~yauhsien@61-231-17-3.dynamic-ip.hinet.net)
2022-01-27 01:58:53 +0100mon_aaraj(~MonAaraj@user/mon-aaraj/x-4416475)
2022-01-27 02:02:11 +0100 <EvanR> are you basically just trying to eliminate an explicit Either
2022-01-27 02:02:15 +0100 <ski> forall o. (forall x. (x -> a -> Either x o) -> x -> (x -> b) -> o) -> o -- ?
2022-01-27 02:02:25 +0100 <Axman6> yeah
2022-01-27 02:03:03 +0100 <EvanR> where as ski eliminated the constructor itself instead
2022-01-27 02:03:06 +0100 <ski> i guess replace `Either x (Fold a b)' with `forall o. (x -> o) -> (Fold a b -> o) -> o' ?
2022-01-27 02:04:15 +0100 <ski> (perhaps further replacing `Fold a b -> o' with an equivalent data type)
2022-01-27 02:06:02 +0100 <ski> (in any case, i can't really follow your `newtype' suggestion)
2022-01-27 02:07:50 +0100imalsogreg(~imalsogre@c-73-172-114-3.hsd1.md.comcast.net) (Remote host closed the connection)
2022-01-27 02:07:51 +0100 <ski> (`forall r. x -> a -> (x -> r) -> (Fold a b -> r) -> ((x -> b) -> r) -> r' would be equivalent to `x -> a -> Either3 x (Fold a b) (x -> b))', fwiw)
2022-01-27 02:08:02 +0100imalsogreg(~imalsogre@2601:147:300:f930::ee17)
2022-01-27 02:10:39 +0100werneta(~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 256 seconds)
2022-01-27 02:11:21 +0100imalsogreg(~imalsogre@2601:147:300:f930::ee17) (Remote host closed the connection)
2022-01-27 02:11:44 +0100albet70(~xxx@2400:8902::f03c:92ff:fe60:98d8) (Remote host closed the connection)
2022-01-27 02:12:31 +0100frosky_(~froskyarr@203.175.13.219)
2022-01-27 02:12:33 +0100werneta(~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net)
2022-01-27 02:12:40 +0100frosky_(~froskyarr@203.175.13.219) (Client Quit)
2022-01-27 02:13:02 +0100imalsogreg(~imalsogre@2601:147:300:f930::ee17)
2022-01-27 02:13:16 +0100 <Axman6> I can't actually figure out how to use this thing...
2022-01-27 02:13:32 +0100FroskyArr(~froskyarr@203.175.13.219) (Ping timeout: 240 seconds)
2022-01-27 02:14:03 +0100cheater(~Username@user/cheater) (Ping timeout: 256 seconds)
2022-01-27 02:14:12 +0100FroskyArr(~froskyarr@203.175.13.219)
2022-01-27 02:14:13 +0100 <ski> which ?
2022-01-27 02:14:23 +0100 <Axman6> given drop :: Int -> Fold a b -> Fold a b, with the data type version, I can just write drop n (Fold step0 x0 done0) = Fold step n done where ... but I have no idea how to "store" the n in the church encoded version
2022-01-27 02:14:29 +0100 <ski> hmm
2022-01-27 02:14:36 +0100skiactually reads the type
2022-01-27 02:16:02 +0100 <ski> looks like `x' is the internal state, `x -> b' is applied when you don't want to supply any more items (end-of-input), while `x -> a -> Either x (Fold a b)' is applied when you do supply another item (`a') .. and then you either get a new state `x' .. or a new `Fold a b' (which can change the state type to some other type)
2022-01-27 02:16:15 +0100imalsogreg(~imalsogre@2601:147:300:f930::ee17) (Remote host closed the connection)
2022-01-27 02:16:54 +0100 <ski> (not quite sure where exactly the "change state type (and next-item & end-if-input)" ability is wanted)
2022-01-27 02:17:10 +0100cheater(~Username@user/cheater)
2022-01-27 02:17:27 +0100imalsogreg(~imalsogre@2601:147:300:f930::ee17)
2022-01-27 02:17:34 +0100FroskyArr(~froskyarr@203.175.13.219) (Client Quit)
2022-01-27 02:17:49 +0100FroskyArr(~froskyarr@203.175.13.219)
2022-01-27 02:17:51 +0100albet70(~xxx@2400:8902::f03c:92ff:fe60:98d8)
2022-01-27 02:18:08 +0100 <Axman6> yep that sounds about right - I was looking at how to avoid the state in foldl not being able to "shrink", like in the drop example, once n reaches zero, I don't care about it, but in the current foldl implementation it sticks around for the life of the fold
2022-01-27 02:19:10 +0100travisb_travisb
2022-01-27 02:19:33 +0100 <ski> drop n xs fold = xs (\step0 x0 done0 -> let ... in fold step n done) -- ?
2022-01-27 02:19:43 +0100travisbabemann
2022-01-27 02:19:50 +0100abemanntabemann
2022-01-27 02:20:13 +0100Morrow(~Morrow@bzq-110-168-31-106.red.bezeqint.net)
2022-01-27 02:21:46 +0100nunggu(~q@user/nunggu)
2022-01-27 02:22:17 +0100Null_A(~null_a@2601:645:8700:2290:8935:4edf:b32:6553)
2022-01-27 02:25:43 +0100 <ski> s/step n/step x/
2022-01-27 02:26:22 +0100 <ski> drop n xs fold = xs (\step0 s0 done0 -> let step (s,n) x = if n <= 0 then (step0 s x,n) else (s,n-1); s = (s0,n); done (s,_) = done0 s in fold step s done) -- i guess
2022-01-27 02:28:23 +0100imalsogreg(~imalsogre@2601:147:300:f930::ee17) (Remote host closed the connection)
2022-01-27 02:28:58 +0100imalsogreg(~imalsogre@2601:147:300:f930::ee17)
2022-01-27 02:29:46 +0100 <ski> drop n xs fold = xs (\step0 s0 done0 -> let step (s,Nothing) x = (step0 s x,Nothing); step (s,Just n) x = (s,if n <= 1 then Nothing else Just (n-1)); s | n <= 0 = (s0,Nothing) | otherwise = (s0,Just n); done (s,_) = done0 s in fold step s done) -- or, i suppose
2022-01-27 02:29:57 +0100myShoggoth(~myShoggot@97-120-67-120.ptld.qwest.net) (Ping timeout: 240 seconds)
2022-01-27 02:30:44 +0100imalsogreg(~imalsogre@2601:147:300:f930::ee17) (Remote host closed the connection)
2022-01-27 02:31:24 +0100bontaq(~user@ool-45779fe5.dyn.optonline.net)
2022-01-27 02:32:45 +0100Erutuon(~Erutuon@user/erutuon) (Ping timeout: 256 seconds)
2022-01-27 02:33:34 +0100imalsogreg(~imalsogre@2601:147:300:f930::ee17)
2022-01-27 02:35:29 +0100Henson(~kvirc@107-179-133-201.cpe.teksavvy.com)
2022-01-27 02:36:33 +0100CHUD(~CHUD@host-80-41-89-108.as13285.net) (Remote host closed the connection)
2022-01-27 02:36:50 +0100CHUD(~CHUD@host-80-41-89-108.as13285.net)
2022-01-27 02:40:46 +0100jeetelongname(~jeet@88-111-159-26.dynamic.dsl.as9105.com) (Ping timeout: 268 seconds)
2022-01-27 02:41:49 +0100lionhairdino(~jacoo@121.131.39.82)
2022-01-27 02:44:12 +0100_xor(~xor@dsl-50-5-233-169.fuse.net) (Read error: Connection reset by peer)
2022-01-27 02:45:09 +0100vysn(~vysn@user/vysn)
2022-01-27 02:45:50 +0100_xor(~xor@dsl-50-5-233-169.fuse.net)
2022-01-27 02:48:02 +0100raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) (Ping timeout: 240 seconds)
2022-01-27 02:51:27 +0100Gurkenglas(~Gurkengla@dslb-090-186-104-244.090.186.pools.vodafone-ip.de) (Ping timeout: 256 seconds)
2022-01-27 02:53:47 +0100imalsogreg(~imalsogre@2601:147:300:f930::ee17) (Remote host closed the connection)
2022-01-27 02:57:57 +0100jkaye(~jkaye@2601:281:8300:7530:cf1a:5f6d:9faa:a84e) (Ping timeout: 240 seconds)
2022-01-27 02:58:08 +0100segfaultfizzbuzz(~rustisafu@2602:306:cd3c:9350:59e3:db49:aa0a:46e5) (Quit: Leaving)
2022-01-27 02:58:37 +0100yauhsien_(~yauhsien@61-231-17-3.dynamic-ip.hinet.net) (Ping timeout: 240 seconds)
2022-01-27 03:03:08 +0100notzmv(~zmv@user/notzmv)
2022-01-27 03:03:48 +0100imalsogreg(~imalsogre@2601:147:300:f930::ee17)
2022-01-27 03:04:09 +0100vicfred(~vicfred@user/vicfred) (Quit: Leaving)
2022-01-27 03:11:00 +0100machinedgod(~machinedg@24.105.81.50) (Ping timeout: 250 seconds)
2022-01-27 03:12:07 +0100epolanski(uid312403@id-312403.helmsley.irccloud.com) (Quit: Connection closed for inactivity)
2022-01-27 03:12:30 +0100intersec1(~ivoolivei@a109-50-190-38.cpe.netcabo.pt)
2022-01-27 03:15:20 +0100intersect(~ivoolivei@a109-50-190-38.cpe.netcabo.pt) (Ping timeout: 250 seconds)
2022-01-27 03:15:38 +0100deadmarshal(~deadmarsh@95.38.119.169)
2022-01-27 03:17:42 +0100Morrow_(~Morrow@bzq-110-168-31-106.red.bezeqint.net)
2022-01-27 03:17:56 +0100soxen(~bob@pool-173-54-217-168.nwrknj.fios.verizon.net) (Ping timeout: 250 seconds)
2022-01-27 03:18:48 +0100joo-_(~joo-_@fsf/member/joo--) (Ping timeout: 250 seconds)
2022-01-27 03:19:47 +0100Morrow(~Morrow@bzq-110-168-31-106.red.bezeqint.net) (Ping timeout: 256 seconds)
2022-01-27 03:20:06 +0100deadmarshal(~deadmarsh@95.38.119.169) (Ping timeout: 250 seconds)
2022-01-27 03:20:14 +0100xff0x(~xff0x@2001:1a81:53ec:e00:f919:e263:9a7f:5670) (Ping timeout: 268 seconds)
2022-01-27 03:20:39 +0100joo-_(~joo-_@87-49-45-141-mobile.dk.customer.tdc.net)
2022-01-27 03:20:39 +0100joo-_(~joo-_@87-49-45-141-mobile.dk.customer.tdc.net) (Changing host)
2022-01-27 03:20:39 +0100joo-_(~joo-_@fsf/member/joo--)
2022-01-27 03:21:59 +0100xff0x(~xff0x@2001:1a81:523c:5300:707e:bf72:dc84:30f7)
2022-01-27 03:28:20 +0100Morrow_(~Morrow@bzq-110-168-31-106.red.bezeqint.net) (Read error: Connection reset by peer)
2022-01-27 03:28:33 +0100Morrow(~Morrow@bzq-110-168-31-106.red.bezeqint.net)
2022-01-27 03:29:55 +0100ProfSimm(~ProfSimm@87.227.196.109) (Remote host closed the connection)
2022-01-27 03:30:15 +0100ProfSimm(~ProfSimm@87.227.196.109)
2022-01-27 03:32:17 +0100Morrow_(~Morrow@bzq-110-168-31-106.red.bezeqint.net)
2022-01-27 03:33:54 +0100Morrow(~Morrow@bzq-110-168-31-106.red.bezeqint.net) (Read error: Connection reset by peer)
2022-01-27 03:33:59 +0100 <SrPx> is there any short way to get the first command line argument as an Int, without imports? `main = do { n <- getArg 0 :: IO Int; ... } ` ?
2022-01-27 03:34:45 +0100Morrow(~Morrow@bzq-110-168-31-106.red.bezeqint.net)
2022-01-27 03:35:11 +0100 <int-e> You need to import System.Environment, which has getArgs :: IO [String]
2022-01-27 03:36:53 +0100Morrow_(~Morrow@bzq-110-168-31-106.red.bezeqint.net) (Ping timeout: 268 seconds)
2022-01-27 03:36:54 +0100 <SrPx> so I need two lines at best, right?
2022-01-27 03:37:24 +0100 <SrPx> except if I could fmap to get the first element of the list and read as int, but I guess that would be hideous
2022-01-27 03:39:10 +0100 <int-e> n <- read . head <$> getArgs may be fine for throwaway code
2022-01-27 03:39:43 +0100 <ski> (or `n <- readIO . head =<< getArgs')
2022-01-27 03:40:00 +0100 <SrPx> `fmap (read.head) getArgs :: IO Int`
2022-01-27 03:40:09 +0100 <SrPx> oh I like your version
2022-01-27 03:40:37 +0100bjobjo(~bjobjo@user/bjobjo) (Ping timeout: 240 seconds)
2022-01-27 03:42:19 +0100 <geekosaur> and you can avoid imports if you enable -fimplicit-import-qualified and then use System.Environment.getArgs
2022-01-27 03:42:37 +0100 <geekosaur> that's kinda dodgy though (it's really intended for ghci)
2022-01-27 03:42:39 +0100bjobjo(~bjobjo@user/bjobjo)
2022-01-27 03:43:22 +0100 <jackdk> :t (readMaybe <=< listToMaybe) <$> getArgs
2022-01-27 03:43:23 +0100 <lambdabot> error:
2022-01-27 03:43:23 +0100 <lambdabot> Variable not in scope: readMaybe :: b0 -> Maybe c
2022-01-27 03:43:23 +0100 <lambdabot> error: Variable not in scope: getArgs :: f [b0]
2022-01-27 03:43:35 +0100Morrow(~Morrow@bzq-110-168-31-106.red.bezeqint.net) (Ping timeout: 256 seconds)
2022-01-27 03:43:41 +0100 <jackdk> % :m + System.Environment Text.Read
2022-01-27 03:43:41 +0100 <yahb> jackdk:
2022-01-27 03:43:54 +0100 <jackdk> % :t (readMaybe <=< listToMaybe) <$> getArgs
2022-01-27 03:43:54 +0100 <yahb> jackdk: Read c => IO (Maybe c)
2022-01-27 03:44:14 +0100 <jackdk> SrPx: ^^
2022-01-27 03:44:15 +0100 <jackdk> % :m - System.Environment Text.Read
2022-01-27 03:44:15 +0100 <yahb> jackdk:
2022-01-27 03:44:37 +0100 <int-e> yuck
2022-01-27 03:44:56 +0100 <int-e> getArgs >>= \case or something to that effect will be much more readable
2022-01-27 03:46:14 +0100andreabedini(~andreabed@8s8kj6nfnfll37n1mb0g.ip6.superloop.com)
2022-01-27 03:46:47 +0100 <int-e> (and that'll work reasonably well as long as you only have positional arguments and no switches)
2022-01-27 03:46:58 +0100 <jackdk> you could use a headMaybe from some package but I wanted to confine myself to base
2022-01-27 03:49:07 +0100intersec1(~ivoolivei@a109-50-190-38.cpe.netcabo.pt) (Read error: Connection reset by peer)
2022-01-27 03:51:06 +0100ProfSimm(~ProfSimm@87.227.196.109) (Remote host closed the connection)
2022-01-27 03:51:10 +0100wombat875(~wombat875@pool-72-89-24-154.nycmny.fios.verizon.net)
2022-01-27 03:53:48 +0100califax-(~califax@user/califx)
2022-01-27 03:54:00 +0100intersect(~ivoolivei@a109-50-190-38.cpe.netcabo.pt)
2022-01-27 03:57:43 +0100CHUD(~CHUD@host-80-41-89-108.as13285.net) (Remote host closed the connection)
2022-01-27 03:58:00 +0100CHUD(~CHUD@host-80-41-89-108.as13285.net)
2022-01-27 03:58:06 +0100califax(~califax@user/califx) (Ping timeout: 276 seconds)
2022-01-27 03:58:06 +0100califax-califax
2022-01-27 03:58:58 +0100segfaultfizzbuzz(~rustisafu@2602:306:cd3c:9350:59e3:db49:aa0a:46e5)
2022-01-27 03:59:06 +0100foul_owl(~kerry@174-21-143-101.tukw.qwest.net) (Ping timeout: 250 seconds)
2022-01-27 03:59:45 +0100 <segfaultfizzbuzz> very much a haskell noob here. i am interested to try to make some "real world use" of haskell's core language features, so i thought i would try to experiment with streams (and presumably benefit from laziness here?)
2022-01-27 04:00:05 +0100 <segfaultfizzbuzz> so i got a basic conduit http stream to print and am now trying to parse the xml it contains
2022-01-27 04:01:07 +0100 <Axman6> streams are not really about laziness at all, they generally make no use of it
2022-01-27 04:01:25 +0100 <segfaultfizzbuzz> oh really? but laziness is all about codata and infinite data structures...?
2022-01-27 04:03:59 +0100 <sm> laziness can be used for "streaming".. you get some similar benefits, but it's too uncontrolled and can bite you. Streaming libraries do it more robustly.
2022-01-27 04:04:28 +0100 <segfaultfizzbuzz> so streaming libraries follow strict eval?
2022-01-27 04:04:37 +0100davros(~davros@host86-184-82-149.range86-184.btcentralplus.com) (Ping timeout: 240 seconds)
2022-01-27 04:04:50 +0100 <Axman6> streams are an alternative to lazy-IO (among other things). in the past we might have just used readFile :: FileName -> IO Lazy.ByteString, which would read chunks as they're demanded, but this is difficult to control the behaviour of. streams make this explicit, each chunk from the file is passed explicitly, there's no lazy IO magic to produce each chunk
2022-01-27 04:05:39 +0100 <Axman6> streams allow consumers to say "I need some more input now" and have the upstream code do the work to produce that input, like read the next chunk from a file handle
2022-01-27 04:05:45 +0100nunggu(~q@user/nunggu) (Remote host closed the connection)
2022-01-27 04:05:55 +0100 <segfaultfizzbuzz> wow ok then i think i should probably split this inquiry in two (1) i still am interested to try to parse an http stream into xml using haskell and (2) i'm curious what a good "real" trial run of laziness might be
2022-01-27 04:06:08 +0100nunggu(~q@user/nunggu)
2022-01-27 04:06:25 +0100 <Axman6> with lazy IO, consumers believe they are working with a completely pure lazy bytestring, but in reality, when they try to evaluate the next chunk, there's some unsafeInlinePerformIO shenanigans going on to magically read from the file
2022-01-27 04:06:38 +0100 <segfaultfizzbuzz> if i short circuit (1) i'm trying to make this line work: runConduit $ responseBody response $ cursor $/ element "body" .| printC
2022-01-27 04:06:59 +0100 <segfaultfizzbuzz> using conduit and xml-conduit (or libraries you recommend, if those aren't a good choice)
2022-01-27 04:07:11 +0100CHUD(~CHUD@host-80-41-89-108.as13285.net) (Ping timeout: 256 seconds)
2022-01-27 04:07:21 +0100 <Axman6> I'm not familliar with dealing iwht xml with conduits sadly (luckily?)
2022-01-27 04:07:26 +0100 <segfaultfizzbuzz> ha
2022-01-27 04:07:32 +0100 <Axman6> s/ll/l
2022-01-27 04:07:54 +0100Vajb(~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) (Read error: Connection reset by peer)
2022-01-27 04:08:21 +0100 <Henson> somebody recommended to me some time ago to use Pipes instead of Conduit, not sure if that is still recommended.
2022-01-27 04:08:38 +0100 <Henson> it's the same idea, but I think easier to get started with than Conduit
2022-01-27 04:09:16 +0100 <Henson> looks like the pipes library isn't as popular as conduit, though
2022-01-27 04:10:08 +0100 <Axman6> I have never managed to make a working program using pipes, it's restrictions make it difficult to write useful programs IMO
2022-01-27 04:10:13 +0100 <jackdk> I particularly like `streaming`, which gives up bidirectional information flow in favour of a really simple type
2022-01-27 04:10:16 +0100 <jackdk> Axman6: ditto
2022-01-27 04:10:20 +0100 <Henson> one of the benefits of stream with pipes or conduit is that you can process really large amounts of data in constant memory, whereas if you try doing that lazily in IO you need to read the entire data into memory.
2022-01-27 04:10:32 +0100 <Axman6> jackdk and I have spoken at length on this, and gome to the same conclusion
2022-01-27 04:10:55 +0100 <segfaultfizzbuzz> so conduit is strictly evaluated...?
2022-01-27 04:11:11 +0100 <Henson> Axman6: so you guys would recommend conduit over pipes, then.
2022-01-27 04:11:23 +0100 <Axman6> Henson: well, the problem with lazy IO is that you _might_ read the whole file into memory, or you might not, and small changes in other parts of your program can change whether that happens or not
2022-01-27 04:11:26 +0100myShoggoth(~myShoggot@97-120-67-120.ptld.qwest.net)
2022-01-27 04:11:59 +0100 <jackdk> Henson: I prefer streaming. There are things I want to say with conduit that I don't seem to be able to
2022-01-27 04:12:12 +0100 <Axman6> I have used conduit quite a bit and managed to do a lot of real work using it. I haven't had much experience with streaming but IIRC is was also quite nice. Most of the work I've done has been around amazonka which exposes things via conduit
2022-01-27 04:12:23 +0100 <segfaultfizzbuzz> jackdk: wait so streaming is different from conduit...?
2022-01-27 04:13:03 +0100td_(~td@94.134.91.245) (Ping timeout: 256 seconds)
2022-01-27 04:13:07 +0100 <jackdk> https://hackage.haskell.org/package/streaming , with a nice workshop at https://github.com/ivan-m/LambdaJAM-Streaming-exercises if the haddocks aren't enough for you
2022-01-27 04:13:07 +0100Erutuon(~Erutuon@user/erutuon)
2022-01-27 04:14:15 +0100foul_owl(~kerry@94.140.8.105)
2022-01-27 04:14:37 +0100td_(~td@muedsl-82-207-238-147.citykom.de)
2022-01-27 04:14:58 +0100 <segfaultfizzbuzz> " in truth "extracting a list or sequence from IO" is mostly just bad practice pure and simple. " heh
2022-01-27 04:16:18 +0100 <jackdk> Henson: it is relatively easy to convert between the types provided by each package. Because Michael Snoyman built a lot of libraries (wai, warp, http-client, etc), a lot of stuff ends up depending on conduit.
2022-01-27 04:16:56 +0100 <jackdk> If I was doing "a little" streaming, I would suck it up and use `conduit`. If I was doing "a lot of" streaming, I would probably use `streaming` in my code and convert in/out of `conduit` when I needed to
2022-01-27 04:16:57 +0100davros(~davros@host86-184-82-149.range86-184.btcentralplus.com)
2022-01-27 04:17:18 +0100pretty_dumm_guy(trottel@gateway/vpn/protonvpn/prettydummguy/x-88029655) (Quit: WeeChat 3.4)
2022-01-27 04:17:25 +0100zaquest(~notzaques@5.130.79.72) (Remote host closed the connection)
2022-01-27 04:18:18 +0100 <Henson> jackdk: yeah, I figured conduit might be more popular because it's a dependency of a bunch of Michael's packages. And just skimming through the docs it looks like it's pretty much the same idea. The types look simpler to understand, too, just a Conduit with a pipe operator, not Producer, Pipe, and Consumer with a bunch of different ways of fusing/connecting them together.
2022-01-27 04:19:19 +0100 <jackdk> Producer/Consumer/Pipe are all instances of a more general type, same as Source/Sink/Conduit. That's not really a point of difference
2022-01-27 04:19:33 +0100 <Henson> both Pipe and Conduit (it seems) process data in a conceptually simple way, using "await" to get new data from upstream, and "yield" to send data downstream. Similar conceptually to Python iterators.
2022-01-27 04:19:43 +0100pavonia(~user@user/siracusa) (Read error: Connection reset by peer)
2022-01-27 04:20:02 +0100 <segfaultfizzbuzz> i'm flipping through the slides here now https://ivan-m.github.io/LambdaJAM-Streaming/#/why-streaming
2022-01-27 04:20:59 +0100 <Henson> Axman6: what restrictions does Pipes have that makes it difficult to write useful programs?
2022-01-27 04:21:12 +0100 <jackdk> I would also suggest that the best library is the one you can understand and use to build a working program.
2022-01-27 04:22:03 +0100zaquest(~notzaques@5.130.79.72)
2022-01-27 04:24:48 +0100Vajb(~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi)
2022-01-27 04:25:41 +0100 <segfaultfizzbuzz> i mean i'm struggling with everything at the moment lol. i switched over to trying to understand some stream documentation. https://hackage.haskell.org/package/HTTP-4000.3.16/docs/Network-HTTP-Stream.html can this generate a stream from an http request? everything i see here sends a stream in
2022-01-27 04:25:46 +0100 <jackdk> the problem I have with the pipes/conduit model is that your composition actually gets a bit harder: connecting the output of one stream into another's input is a separate operation with its own operators/rules/etc to manipulating the stream itself
2022-01-27 04:26:18 +0100james[m]123(~jamesnina@2001:470:69fc:105::1:4203) (Quit: Client limit exceeded: 20000)
2022-01-27 04:27:32 +0100int-e(~noone@int-e.eu) (Remote host closed the connection)
2022-01-27 04:27:47 +0100 <jackdk> segfaultfizzbuzz: let's back up to your initial problem. You want to make HTTP requests of some server?
2022-01-27 04:28:02 +0100james[m]123(~jamesnina@2001:470:69fc:105::1:4203)
2022-01-27 04:28:08 +0100 <jackdk> and you're possibly expecting large response bodies, so you want to stream the response somewhere?
2022-01-27 04:28:34 +0100int-e(~noone@int-e.eu)
2022-01-27 04:29:55 +0100pavonia(~user@user/siracusa)
2022-01-27 04:30:36 +0100 <segfaultfizzbuzz> yeah the response is like 100 gb of zipped xml
2022-01-27 04:31:01 +0100 <jackdk> so you want to stream it to disk
2022-01-27 04:31:02 +0100 <segfaultfizzbuzz> but i am trying to build up to that by doing streaming calculations on some trivially sized xml delivered over http
2022-01-27 04:31:12 +0100 <segfaultfizzbuzz> no i want to do everything in ram. just network and ram
2022-01-27 04:31:42 +0100 <Axman6> Henson: I can't remember exqctly what I ran into, but one thing I did want to do was write something that could pipe a bytestring through, and when the bytestring had all been processed, I would return the hash of it - seems simple enough, but IIRC that is impossible to do. In conduit it just had type Conduit ByteString ByteString m (Digent SHA256) or something
2022-01-27 04:32:11 +0100 <jackdk> ok segfaultfizzbuzz, you want to do some streaming computation over this without buffering everything everywhere
2022-01-27 04:32:28 +0100retroid_(~retro@2e40edd9.skybroadband.com) (Ping timeout: 250 seconds)
2022-01-27 04:33:00 +0100 <segfaultfizzbuzz> not sure what "everything everywhere" means but yeah the actual calculation i need to do over the file looks like accumulating a few dozen bytes and then writing those few dozen bytes to disk
2022-01-27 04:33:24 +0100 <jackdk> fair. Have a look at https://hackage.haskell.org/package/http-conduit-2.3.8/docs/Network-HTTP-Simple.html
2022-01-27 04:33:45 +0100 <segfaultfizzbuzz> initially i started doing this in rust but ran into some problems and could never figure out whether there was a bug in the rust xml parser i was using or the file itself had some kind of formatting issue (i think it was invalid utf8)
2022-01-27 04:34:00 +0100 <segfaultfizzbuzz> whatever the case, this sounded like the sort of thing that haskellers say haskell is good at so i thought i would just give it a try
2022-01-27 04:35:16 +0100 <jackdk> let's see how we go. There's a note at the top of the linked document about turning on OverloadedStrings to construct the request in the first place, then you'll want to use `httpSource` and `getResponseBody` to get a conduit that represents the response body itself.
2022-01-27 04:35:28 +0100cheater(~Username@user/cheater) (Ping timeout: 268 seconds)
2022-01-27 04:35:43 +0100cheater(~Username@user/cheater)
2022-01-27 04:35:49 +0100 <segfaultfizzbuzz> ok i'll try starting from this
2022-01-27 04:36:32 +0100 <segfaultfizzbuzz> i mean ok the example works. should i try to feed this into Text.XML ?
2022-01-27 04:36:33 +0100 <jackdk> if you get stuck, put something in a pastebin and someone should be able to take a look
2022-01-27 04:38:24 +0100 <jackdk> I would look at https://hackage.haskell.org/package/xml-conduit-1.9.1.1/docs/Text-XML-Stream-Parse.html#v:parseBytes which you should be able to connect to the conduit from the response body
2022-01-27 04:41:16 +0100 <segfaultfizzbuzz> thanks i'll give that a try
2022-01-27 04:49:22 +0100intersect(~ivoolivei@a109-50-190-38.cpe.netcabo.pt) (Ping timeout: 250 seconds)
2022-01-27 04:54:29 +0100 <segfaultfizzbuzz> ok well here is my first attempt: main = httpBS "http://zombo.com" >>= parseBytes def .| printC
2022-01-27 04:54:34 +0100Jing(~hedgehog@240e:390:7c53:a7e1:54d9:91e1:8da8:c09f)
2022-01-27 05:00:08 +0100FroskyArr(~froskyarr@203.175.13.219) (Remote host closed the connection)
2022-01-27 05:00:31 +0100FroskyArr(~froskyarr@203.175.13.219)
2022-01-27 05:01:57 +0100 <jackdk> well yeah, anything is possible at zombocom
2022-01-27 05:02:22 +0100 <segfaultfizzbuzz> hahaha even my bad, wrong haskell code
2022-01-27 05:04:20 +0100 <segfaultfizzbuzz> anyway i can't get things to fit. it says can't match ConduitT B8.ByteString c0 m0 () with ConduitM B8.ByteString c0 m0 ()
2022-01-27 05:04:56 +0100Morrow(~Morrow@bzq-110-168-31-106.red.bezeqint.net)
2022-01-27 05:05:06 +0100 <segfaultfizzbuzz> i forget, does haskell do implicit type conversion...? no, right?
2022-01-27 05:05:32 +0100 <segfaultfizzbuzz> you would use polymorphism to achieve that or something along those lines...?
2022-01-27 05:07:47 +0100 <andreabedini> segfaultfizzbuzz: that's correct
2022-01-27 05:08:01 +0100waleee(~waleee@h-98-128-229-110.NA.cust.bahnhof.se) (Ping timeout: 256 seconds)
2022-01-27 05:09:12 +0100 <segfaultfizzbuzz> so i see the T there which smells like i need to understand monad transformers to do this stuff perhaps?
2022-01-27 05:09:13 +0100retroid_(~retro@2e40edd9.skybroadband.com)
2022-01-27 05:09:49 +0100 <segfaultfizzbuzz> i was reading through Real World Haskell a few days ago and i feel like i finally understood the meaning of the term "monad" once the author used the words "chain" and "inject"
2022-01-27 05:11:39 +0100 <Axman6> you might find this useful to solidify that a bit: https://tomstu.art/refactoring-ruby-with-monads
2022-01-27 05:11:44 +0100imalsogreg(~imalsogre@2601:147:300:f930::ee17) (Remote host closed the connection)
2022-01-27 05:12:42 +0100 <andreabedini> I am not familiar with Conduit but in this case it looks like ConduitM is an alias for ContuitT, kept for backward compatibility
2022-01-27 05:12:45 +0100 <andreabedini> https://hackage.haskell.org/package/conduit-1.3.4.2/docs/Data-Conduit.html#t:ConduitM
2022-01-27 05:13:01 +0100 <andreabedini> so you might avoid that rabbit hole :)
2022-01-27 05:14:11 +0100leungbk(~user@2603-8000-1201-2dd2-79d4-db3d-bfd4-b037.res6.spectrum.com)
2022-01-27 05:16:38 +0100 <segfaultfizzbuzz> is an alias...? if it is an alias then why doesn't haskell treat them as the same...?
2022-01-27 05:19:15 +0100 <segfaultfizzbuzz> i mean it says right there in the documentation, type ConduitM = ConduitT so ... do i have to give haskell permission to treat the types as equivalent...?
2022-01-27 05:21:46 +0100leungbk(~user@2603-8000-1201-2dd2-79d4-db3d-bfd4-b037.res6.spectrum.com) (Quit: ERC 5.4 (IRC client for GNU Emacs 28.0.91))
2022-01-27 05:21:56 +0100 <Axman6> sounds like your problem might be something else
2022-01-27 05:22:26 +0100 <segfaultfizzbuzz> i'll do a bigger paste if you like
2022-01-27 05:23:08 +0100 <segfaultfizzbuzz> https://paste.rs/FE4.hs
2022-01-27 05:24:10 +0100leungbk(~user@2603-8000-1201-2dd2-79d4-db3d-bfd4-b037.res6.spectrum.com)
2022-01-27 05:24:39 +0100soxen(~bob@pool-173-54-217-168.nwrknj.fios.verizon.net)
2022-01-27 05:25:11 +0100mbuf(~Shakthi@223.190.239.151)
2022-01-27 05:27:00 +0100yauhsien(~yauhsien@2402:7500:5e5:b1b6:819e:4473:2cd6:e659)
2022-01-27 05:27:17 +0100myShoggoth(~myShoggot@97-120-67-120.ptld.qwest.net) (Ping timeout: 240 seconds)
2022-01-27 05:28:28 +0100 <andreabedini> segfaultfizzbuzz: you are not reading the error correctly. GHC is saying "I cannot match A, I was expecting B but I got A"
2022-01-27 05:29:08 +0100 <andreabedini> it was expecting IO () but it got a ConduitT i0 Event m0
2022-01-27 05:30:54 +0100 <andreabedini> in general terms, I think with Conduit you build a pipeline (with types like ConduitT a b c or something) and then you "run" it, turning the pipeline into an IO type (typically, but it doens't have to be IO)
2022-01-27 05:31:17 +0100 <asivitz> is there a good library for serializing a random generator's state? for some reason StdGen doesn't have a Read instance
2022-01-27 05:32:23 +0100wroathe(~wroathe@user/wroathe) (Ping timeout: 256 seconds)
2022-01-27 05:32:51 +0100 <dsal> You can use a different generator, I guess.
2022-01-27 05:33:22 +0100 <dsal> :t randomR
2022-01-27 05:33:23 +0100 <lambdabot> (Random a, RandomGen g) => (a, a) -> g -> (a, g)
2022-01-27 05:34:51 +0100 <asivitz> yea; I assume there has to be an existing library that implements some serializable RandomGen?
2022-01-27 05:35:53 +0100 <andreabedini> asivitz: for context https://github.com/haskell/random/issues/123
2022-01-27 05:37:03 +0100 <jackdk> segfaultfizzbuzz: Possibly helpful: https://www.irccloud.com/pastebin/tIkjGAtc/Zombo.hs
2022-01-27 05:38:08 +0100 <asivitz> andreabedini: ah ok. well that's definitely what I'm looking for. glad it's being considered. thanks
2022-01-27 05:38:09 +0100Morrow(~Morrow@bzq-110-168-31-106.red.bezeqint.net) (Remote host closed the connection)
2022-01-27 05:38:10 +0100leungbk(~user@2603-8000-1201-2dd2-79d4-db3d-bfd4-b037.res6.spectrum.com) (Read error: Connection reset by peer)
2022-01-27 05:38:33 +0100Morrow(~Morrow@bzq-110-168-31-106.red.bezeqint.net)
2022-01-27 05:38:46 +0100jmc(~jmc@softbank126150248096.bbtec.net)
2022-01-27 05:38:52 +0100 <segfaultfizzbuzz> ah the issue was that i wasn't using .|
2022-01-27 05:39:55 +0100 <andreabedini> segfaultfizzbuzz: glad you sorted it, Conduit has its own operators to combine pieces of a pipeline, I never remember them
2022-01-27 05:40:40 +0100 <jackdk> .| connects the output of one conduit to the input of another. `runConduit :: Monad m => ConduitT () Void m r -> m r` runs a conduit that takes no input from upstream and produces no input downstream (`Void` is an uninhabited type)
2022-01-27 05:40:44 +0100 <segfaultfizzbuzz> your zombo example is almost identical to what i was originally doing, except that it is using runResourceT
2022-01-27 05:40:45 +0100wroathe(~wroathe@206-55-188-8.fttp.usinternet.com)
2022-01-27 05:40:46 +0100wroathe(~wroathe@206-55-188-8.fttp.usinternet.com) (Changing host)
2022-01-27 05:40:46 +0100wroathe(~wroathe@user/wroathe)
2022-01-27 05:41:13 +0100 <jackdk> I needed that because it complained about no MonadResource instance for IO
2022-01-27 05:41:38 +0100 <jackdk> It closes any open connections, etc
2022-01-27 05:42:34 +0100 <jmc> How do I force-recompile base? I want to get .hie files for it, but Cabal doesn't seem to let me. Compiling from source doesn't work for reasons I hope not to have to get into
2022-01-27 05:43:20 +0100yauhsien(~yauhsien@2402:7500:5e5:b1b6:819e:4473:2cd6:e659) (Remote host closed the connection)
2022-01-27 05:45:25 +0100wroathe(~wroathe@user/wroathe) (Ping timeout: 256 seconds)
2022-01-27 05:46:48 +0100deadmarshal(~deadmarsh@95.38.119.169)
2022-01-27 05:53:14 +0100CHUD(~CHUD@host-80-41-89-108.as13285.net)
2022-01-27 05:58:16 +0100soxen(~bob@pool-173-54-217-168.nwrknj.fios.verizon.net) (Ping timeout: 250 seconds)
2022-01-27 06:08:31 +0100jao(~jao@68.235.43.173)
2022-01-27 06:10:54 +0100bitdex(~bitdex@gateway/tor-sasl/bitdex)
2022-01-27 06:15:15 +0100alMalsamo(~alMalsamo@gateway/tor-sasl/almalsamo) (Ping timeout: 276 seconds)
2022-01-27 06:22:35 +0100bitmapper(uid464869@id-464869.lymington.irccloud.com)
2022-01-27 06:24:44 +0100intersect(~ivoolivei@a109-50-190-38.cpe.netcabo.pt)
2022-01-27 06:29:33 +0100intersect(~ivoolivei@a109-50-190-38.cpe.netcabo.pt) (Ping timeout: 268 seconds)
2022-01-27 06:30:14 +0100jao(~jao@68.235.43.173) (Remote host closed the connection)
2022-01-27 06:31:07 +0100alMalsamo(~alMalsamo@gateway/tor-sasl/almalsamo)
2022-01-27 06:43:37 +0100 <segfaultfizzbuzz> so in rust there's a trick where you can say let _ : () = foo to make the compiler print out the type of something,... is there an equivalent in haskell?
2022-01-27 06:43:37 +0100vglfr(~vglfr@46.96.142.183)
2022-01-27 06:43:46 +0100 <segfaultfizzbuzz> substantially all of my debugging is printf
2022-01-27 06:44:06 +0100 <segfaultfizzbuzz> equivalent for compiled code that is, i know about :t for ghci
2022-01-27 06:45:29 +0100mon_aaraj(~MonAaraj@user/mon-aaraj/x-4416475) (Ping timeout: 256 seconds)
2022-01-27 06:46:54 +0100yauhsien(~yauhsien@61-231-17-3.dynamic-ip.hinet.net)
2022-01-27 06:47:15 +0100mon_aaraj(~MonAaraj@user/mon-aaraj/x-4416475)
2022-01-27 06:48:06 +0100ensyde(~ensyde@2600:1700:2050:1040:c06a:eb2:e18d:4418)
2022-01-27 06:49:45 +0100 <ski> segfaultfizzbuzz : i guess you could add a type ascription `... :: Bool' or something, and it'll complain that `...' is not of type `Bool' (if it isn't), and say something about the type it has inferred for it (often just giving some of the detail, though, like the top-level type constructor)
2022-01-27 06:49:49 +0100 <jackdk> % length (_ ++ [1, 2, 3])
2022-01-27 06:49:54 +0100 <yahb> jackdk: [Timed out]
2022-01-27 06:50:16 +0100 <jackdk> > length (_ ++ [1, 2, 3])
2022-01-27 06:50:21 +0100 <lambdabot> error:
2022-01-27 06:50:21 +0100 <lambdabot> • Found hole: _ :: [Integer]
2022-01-27 06:50:21 +0100 <lambdabot> • In the first argument of ‘(++)’, namely ‘_’
2022-01-27 06:50:22 +0100 <ski> % :t length (?xs ++ [0,1,2])
2022-01-27 06:50:23 +0100 <yahb> ski: (?xs::[a], Num a) => Int
2022-01-27 06:50:44 +0100Null_A(~null_a@2601:645:8700:2290:8935:4edf:b32:6553) (Remote host closed the connection)
2022-01-27 06:51:19 +0100 <jackdk> segfaultfizzbuzz: there we go. an `_foo` in an expression is a _typed hole_ which will dump (among other things) the type it expects in that space. 99% of my working with haskell is filling in typed holes
2022-01-27 06:52:05 +0100CHUD(~CHUD@host-80-41-89-108.as13285.net) (Ping timeout: 256 seconds)
2022-01-27 06:52:32 +0100yauhsien(~yauhsien@61-231-17-3.dynamic-ip.hinet.net) (Ping timeout: 240 seconds)
2022-01-27 06:55:51 +0100little_mac(~little_ma@2601:410:4300:3ce0:4184:bb26:81f2:501e)
2022-01-27 06:57:55 +0100HotblackDesiato(~HotblackD@gateway/tor-sasl/hotblackdesiato) (Remote host closed the connection)
2022-01-27 06:58:09 +0100HotblackDesiato(~HotblackD@gateway/tor-sasl/hotblackdesiato)
2022-01-27 06:58:25 +0100 <jackdk> segfaultfizzbuzz: the reverse, where you're like "what is this thing?" I like to either do what ski says and stick a`:: ()` after the expression I'm unsure of (wrapping it in brackets if necessary), or stick a `_ $` in front of the whole thing, which will solve for a function type. That will tell me both what I have and what GHC wants
2022-01-27 07:01:51 +0100pottsy(~pottsy@129.227.183.244)
2022-01-27 07:07:20 +0100wea(~wea@node-1w7jr9qkwjp07dpr4fj1qaoky.ipv6.telus.net)
2022-01-27 07:08:04 +0100 <wea> how to actually see/print Alt type https://paste.tomsmeding.com/cYfmnPLO ?
2022-01-27 07:08:53 +0100 <wea> when using `string "asdf"` i get no instance of Show
2022-01-27 07:13:17 +0100Erutuon(~Erutuon@user/erutuon) (Ping timeout: 240 seconds)
2022-01-27 07:13:59 +0100 <segfaultfizzbuzz> jackdk: thanks (and ski, thanks)
2022-01-27 07:14:04 +0100 <jackdk> wea: doesn't lok like you get one. I would try to build one using runAlt : the alternative instance for [] is append, so you could build some kind of strings
2022-01-27 07:19:32 +0100 <jackdk> and probably not a full show instance, just a function `Alt Primitive a -> String` or something that dumps enough to see what's going on
2022-01-27 07:21:22 +0100img(~img@user/img) (Quit: ZNC 1.8.2 - https://znc.in)
2022-01-27 07:22:17 +0100segfaultfizzbuzz(~rustisafu@2602:306:cd3c:9350:59e3:db49:aa0a:46e5) (Ping timeout: 240 seconds)
2022-01-27 07:22:46 +0100img(~img@user/img)
2022-01-27 07:23:13 +0100 <wea> kinda lost, is it somethin glike `runAlt (:) (string "ADF")` ?
2022-01-27 07:30:11 +0100img(~img@user/img) (Quit: ZNC 1.8.2 - https://znc.in)
2022-01-27 07:30:13 +0100 <EvanR> :t runAlt
2022-01-27 07:30:14 +0100 <lambdabot> error: Variable not in scope: runAlt
2022-01-27 07:31:09 +0100little_mac(~little_ma@2601:410:4300:3ce0:4184:bb26:81f2:501e) (Quit: Leaving)
2022-01-27 07:31:25 +0100little_mac(~little_ma@2601:410:4300:3ce0:4184:bb26:81f2:501e)
2022-01-27 07:31:35 +0100img(~img@user/img)
2022-01-27 07:31:58 +0100[itchyjunk](~itchyjunk@user/itchyjunk/x-7353470) (Read error: Connection reset by peer)
2022-01-27 07:33:59 +0100Chewt(~hayden@2601:1c0:8101:7310::144a) (Quit: WeeChat 3.4)
2022-01-27 07:35:12 +0100 <EvanR> :t getAlt
2022-01-27 07:35:13 +0100 <lambdabot> forall k (f :: k -> *) (a :: k). Alt f a -> f a
2022-01-27 07:35:47 +0100 <jackdk> nah, it's this one: https://hackage.haskell.org/package/free-4.12.4/docs/Control-Alternative-Free.html looks like wea 's working through jle` 's free alternative regexp blog post
2022-01-27 07:37:55 +0100takuan(~takuan@178-116-218-225.access.telenet.be)
2022-01-27 07:42:37 +0100n3rdy1(~n3rdy1@2600:1700:4570:3480:1b88:50f:dae0:9293) (Ping timeout: 240 seconds)
2022-01-27 07:43:37 +0100Jing(~hedgehog@240e:390:7c53:a7e1:54d9:91e1:8da8:c09f) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2022-01-27 07:43:52 +0100CHUD(~CHUD@host-80-41-89-108.as13285.net)
2022-01-27 07:44:55 +0100 <jackdk> wea: sorry, this is actually way harder than I thought: have a look at the `Ap` constructor for `AltF`: `Ap :: f a -> Alt f (a -> b) -> AltF f b`. So if I have a value of type `AltF f b` built with the `Ap` constructor, all I know is _some_ `a` was chosen when the constructor was applied but I don't know what it is
2022-01-27 07:46:13 +0100 <jackdk> what I'd probably do is write functions that print the constructor name `altFName :: AltF f a -> String`but I'm not sure how to dig deeper than that
2022-01-27 07:47:47 +0100cherryblossom[m](~cherryblo@2001:470:69fc:105::b789) (Quit: Client limit exceeded: 20000)
2022-01-27 07:47:52 +0100afotgkmnzj7asv3r(~afotgkmnz@2001:470:69fc:105::c24b) (Quit: Client limit exceeded: 20000)
2022-01-27 07:49:13 +0100slowButPresent(~slowButPr@user/slowbutpresent) (Quit: leaving)
2022-01-27 07:49:50 +0100 <wea> i see, ty
2022-01-27 07:50:02 +0100afotgkmnzj7asv3r(~afotgkmnz@2001:470:69fc:105::c24b)
2022-01-27 07:50:14 +0100cherryblossom[m](~cherryblo@2001:470:69fc:105::b789)
2022-01-27 07:53:17 +0100_ht(~quassel@2a02:a468:b619:1:fb02:7b89:e577:dc30)
2022-01-27 07:53:29 +0100ardell(~ardell@user/ardell)
2022-01-27 07:54:25 +0100wea(~wea@node-1w7jr9qkwjp07dpr4fj1qaoky.ipv6.telus.net) (Remote host closed the connection)
2022-01-27 07:54:35 +0100Jing(~hedgehog@240e:390:7c53:a7e1:54bc:3778:6db0:347c)
2022-01-27 07:56:56 +0100jao(~jao@68.235.43.173)
2022-01-27 08:01:59 +0100jao(~jao@68.235.43.173) (Ping timeout: 256 seconds)
2022-01-27 08:04:04 +0100rusrushal13(~rusrushal@2409:4056:e98:f867:6156:ffe6:54be:d062)
2022-01-27 08:08:42 +0100geekosaur(~geekosaur@xmonad/geekosaur) (Remote host closed the connection)
2022-01-27 08:09:10 +0100rusrushal13(~rusrushal@2409:4056:e98:f867:6156:ffe6:54be:d062) (Ping timeout: 256 seconds)
2022-01-27 08:12:57 +0100little_mac(~little_ma@2601:410:4300:3ce0:4184:bb26:81f2:501e) (Ping timeout: 240 seconds)
2022-01-27 08:13:02 +0100xsperry(~xs@user/xsperry)
2022-01-27 08:16:12 +0100justGhost3(~justache@user/justache)
2022-01-27 08:16:17 +0100yauhsien(~yauhsien@61-231-17-3.dynamic-ip.hinet.net)
2022-01-27 08:16:30 +0100nurupo_(~nurupo.ga@user/nurupo)
2022-01-27 08:16:34 +0100codolio(~dolio@130.44.130.54)
2022-01-27 08:16:40 +0100geekosaur(~geekosaur@xmonad/geekosaur)
2022-01-27 08:16:44 +0100nonzen_(~nonzen@user/nonzen) (Ping timeout: 256 seconds)
2022-01-27 08:16:58 +0100nonzen(~nonzen@user/nonzen)
2022-01-27 08:17:18 +0100dolio(~dolio@130.44.130.54) (Ping timeout: 256 seconds)
2022-01-27 08:17:18 +0100ystael(~ystael@user/ystael) (Ping timeout: 256 seconds)
2022-01-27 08:17:18 +0100justGhost(~justache@user/justache) (Ping timeout: 256 seconds)
2022-01-27 08:17:18 +0100edr(~edr@user/edr) (Ping timeout: 256 seconds)
2022-01-27 08:17:18 +0100nurupo(~nurupo.ga@user/nurupo) (Ping timeout: 256 seconds)
2022-01-27 08:17:18 +0100justGhost3justGhost
2022-01-27 08:17:32 +0100ystael(~ystael@user/ystael)
2022-01-27 08:17:40 +0100Morrow(~Morrow@bzq-110-168-31-106.red.bezeqint.net) (Read error: Connection reset by peer)
2022-01-27 08:17:52 +0100tureba(~tureba@tureba.org) (Ping timeout: 256 seconds)
2022-01-27 08:17:52 +0100Morrow(~Morrow@bzq-110-168-31-106.red.bezeqint.net)
2022-01-27 08:18:07 +0100Erutuon(~Erutuon@user/erutuon)
2022-01-27 08:20:01 +0100nurupo_nurupo
2022-01-27 08:20:09 +0100xsperry(~xs@user/xsperry) ()
2022-01-27 08:21:42 +0100yauhsien(~yauhsien@61-231-17-3.dynamic-ip.hinet.net) (Ping timeout: 250 seconds)
2022-01-27 08:22:28 +0100edr(~edr@enlo.co)
2022-01-27 08:22:29 +0100edr(~edr@enlo.co) (Changing host)
2022-01-27 08:22:29 +0100edr(~edr@user/edr)
2022-01-27 08:23:14 +0100intersect(~ivoolivei@a109-50-190-38.cpe.netcabo.pt)
2022-01-27 08:23:44 +0100yauhsien(~yauhsien@61-231-17-3.dynamic-ip.hinet.net)
2022-01-27 08:24:53 +0100dhouthoo(~dhouthoo@178-117-36-167.access.telenet.be)
2022-01-27 08:25:29 +0100Inst(~delicacie@2601:6c4:4080:3f80:9d39:f8e3:aac8:5b1b)
2022-01-27 08:25:34 +0100 <Inst> ugh @evanr
2022-01-27 08:25:37 +0100 <Inst> you cowards
2022-01-27 08:25:52 +0100 <Inst> you don't even teach monads in your ANU course
2022-01-27 08:26:20 +0100 <EvanR> why do you think I work at ANU
2022-01-27 08:27:29 +0100intersect(~ivoolivei@a109-50-190-38.cpe.netcabo.pt) (Ping timeout: 256 seconds)
2022-01-27 08:28:36 +0100Morrow_(~Morrow@bzq-110-168-31-106.red.bezeqint.net)
2022-01-27 08:28:56 +0100Morrow(~Morrow@bzq-110-168-31-106.red.bezeqint.net) (Read error: Connection reset by peer)
2022-01-27 08:29:22 +0100yauhsien(~yauhsien@61-231-17-3.dynamic-ip.hinet.net) (Remote host closed the connection)
2022-01-27 08:30:05 +0100Morrow(~Morrow@bzq-110-168-31-106.red.bezeqint.net)
2022-01-27 08:30:10 +0100tureba(~tureba@tureba.org)
2022-01-27 08:30:17 +0100zmt00(~zmt00@user/zmt00) (Ping timeout: 240 seconds)
2022-01-27 08:30:45 +0100yauhsien(~yauhsien@61-231-17-3.dynamic-ip.hinet.net)
2022-01-27 08:31:56 +0100Vajb(~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) (Read error: Connection reset by peer)
2022-01-27 08:32:08 +0100Vajb(~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi)
2022-01-27 08:33:09 +0100Morrow_(~Morrow@bzq-110-168-31-106.red.bezeqint.net) (Ping timeout: 256 seconds)
2022-01-27 08:35:24 +0100shriekingnoise(~shrieking@201.231.16.156) (Quit: Quit)
2022-01-27 08:37:12 +0100michalz(~michalz@185.246.204.61)
2022-01-27 08:37:29 +0100 <Inst> blame axeman6
2022-01-27 08:37:37 +0100 <Inst> apparently you were teaching there once upon a time
2022-01-27 08:38:02 +0100 <dibblego> no, and you don't know if monads are taught
2022-01-27 08:39:07 +0100fef(~thedawn@user/thedawn)
2022-01-27 08:40:19 +0100CHUD(~CHUD@host-80-41-89-108.as13285.net) (Ping timeout: 256 seconds)
2022-01-27 08:40:56 +0100 <Inst> not in the intro course
2022-01-27 08:41:03 +0100 <Inst> or maybe he was talking about you, but w/e
2022-01-27 08:41:31 +0100 <Inst> the intro course iirc had an open course website
2022-01-27 08:41:31 +0100mc47(~mc47@xmonad/TheMC47)
2022-01-27 08:41:40 +0100 <dibblego> no, also no
2022-01-27 08:42:14 +0100thevishy(~Nishant@2405:201:f005:c007:4ce:a391:7558:6be8)
2022-01-27 08:43:44 +0100 <Inst> https://cs.anu.edu.au/courses/comp1100/lectures/
2022-01-27 08:44:38 +0100 <Inst> https://cs.anu.edu.au/courses/comp1100/lectures/
2022-01-27 08:45:00 +0100 <Inst> https://cs.anu.edu.au/courses/comp1100/labs/
2022-01-27 08:45:51 +0100 <EvanR> can I get some help here, I can't remember how to refer to the correct proxy to select an instance for KnownSymbol within a GADT pattern match
2022-01-27 08:45:59 +0100 <EvanR> or even what to search for
2022-01-27 08:46:15 +0100yauhsien(~yauhsien@61-231-17-3.dynamic-ip.hinet.net) (Remote host closed the connection)
2022-01-27 08:46:53 +0100 <EvanR> some sort of type signature within the pattern or something
2022-01-27 08:47:57 +0100Akiva(~Akiva@user/Akiva) (Ping timeout: 240 seconds)
2022-01-27 08:48:11 +0100 <EvanR> wait I found it
2022-01-27 08:48:43 +0100 <jackdk> EvanR: either "type applications" (`Proxy @foo`), a type annotation (`Proxy :: Proxy foo`), plus "scoped type variables" if you need to refer to a type variable from an enclosing type signature
2022-01-27 08:49:02 +0100 <EvanR> right, no foo in scope
2022-01-27 08:49:13 +0100 <jackdk> scoped type variables may save you
2022-01-27 08:49:20 +0100 <EvanR> it's from a hidden variable in the GADT element
2022-01-27 08:49:35 +0100 <EvanR> I see an example of how I did it lying around
2022-01-27 08:49:45 +0100 <jackdk> can you show me? now I'm curious
2022-01-27 08:51:49 +0100 <ski> % data Foo = forall a. Show a => MkF [a]
2022-01-27 08:51:49 +0100 <yahb> ski:
2022-01-27 08:51:57 +0100 <ski> % :t \(MkF (xs :: [a])) -> show (reverse (xs :: [a]))
2022-01-27 08:51:57 +0100 <yahb> ski: Foo -> String
2022-01-27 08:52:01 +0100 <ski> % :t \(MkF @a xs) -> show (reverse (xs :: [a]))
2022-01-27 08:52:01 +0100 <yahb> ski: ; <interactive>:1:3: error: Type applications in patterns are not yet supported
2022-01-27 08:52:22 +0100 <jackdk> ah right . turn on scoped type variables then name them in an annotation on the pattern. thanks.
2022-01-27 08:52:31 +0100 <EvanR> I can show you after it works xD
2022-01-27 08:53:21 +0100 <EvanR> ski are you trying to use type applications to introduce a name for the variable?
2022-01-27 08:53:28 +0100 <ski> yes
2022-01-27 08:53:36 +0100 <EvanR> :thonk:
2022-01-27 08:54:10 +0100 <EvanR> or does the name a already exist
2022-01-27 08:54:54 +0100 <EvanR> (I can't actually use the name that was originally used to define the GADT, since it's not in scope)
2022-01-27 08:55:49 +0100 <ski> @quote lazy.bottoms
2022-01-27 08:55:49 +0100 <lambdabot> newsham says: lazy bottoms thunk empty thoughts
2022-01-27 08:56:22 +0100 <ski> (which name ?)
2022-01-27 08:58:00 +0100 <EvanR> https://paste.tomsmeding.com/FpFT2efP what eventually works
2022-01-27 08:58:08 +0100alp(~alp@user/alp)
2022-01-27 08:58:19 +0100gehmehgeh(~user@user/gehmehgeh)
2022-01-27 08:59:13 +0100 <EvanR> (ScopedTypeVariables enabled)
2022-01-27 08:59:34 +0100 <ski> does that really work ?
2022-01-27 08:59:37 +0100 <EvanR> yeah
2022-01-27 09:00:54 +0100 <EvanR> trying to pattern match at the same time as do type annotations doesn't
2022-01-27 09:01:36 +0100andreabedini(~andreabed@8s8kj6nfnfll37n1mb0g.ip6.superloop.com) (Quit: WeeChat 3.3)
2022-01-27 09:07:17 +0100kanin(~kanin@2409:8a14:10e7:52d0:4526:1e35:f024:52e7)
2022-01-27 09:07:56 +0100 <ski> % let fieldNames :: RecF f ts -> [String]; fieldNames R0 = []; fieldNames ent@(R1 _ _) = case ent of (R1 x xs :: KnownSymbol n => RecF f ('(n,t) : qs)) -> symbolVal (Proxy :: Proxy n) : fieldNames xs
2022-01-27 09:07:57 +0100 <yahb> ski:
2022-01-27 09:08:03 +0100 <ski> % let fieldNames :: RecF f ts -> [String]; fieldNames R0 = []; fieldNames ent = case ent of (R1 x xs :: KnownSymbol n => RecF f ('(n,t) : qs)) -> symbolVal (Proxy :: Proxy n) : fieldNames xs
2022-01-27 09:08:03 +0100 <yahb> ski: ; <interactive>:26:92: error:; * No instance for (KnownSymbol n) arising from a pattern; * In the pattern: R1 x xs; In the pattern: R1 x xs :: KnownSymbol n => RecF f ('(n, t) : qs); In a case alternative: (R1 x xs :: KnownSymbol n => RecF f ('(n, t) : qs)) -> symbolVal (Proxy :: Proxy n) : fieldNames xs; <interactive>:26:92: error:; * Couldn't match type `ts' with '(n, t) : qs;
2022-01-27 09:08:07 +0100 <ski> curious
2022-01-27 09:08:08 +0100Morrow_(~Morrow@bzq-110-168-31-106.red.bezeqint.net)
2022-01-27 09:10:16 +0100 <EvanR> in your second try, it may be that 'ent' doesn't properly "open" the gadt
2022-01-27 09:10:33 +0100Morrow(~Morrow@bzq-110-168-31-106.red.bezeqint.net) (Ping timeout: 256 seconds)
2022-01-27 09:10:36 +0100 <EvanR> 2nd equation
2022-01-27 09:11:05 +0100 <EvanR> i.e. even though we know it's R1 it does not
2022-01-27 09:14:41 +0100lortabac(~lortabac@2a01:e0a:541:b8f0:2912:7d04:4a3c:64d7)
2022-01-27 09:14:57 +0100mvk(~mvk@2607:fea8:5cdc:bf00::a2bf) (Ping timeout: 240 seconds)
2022-01-27 09:15:34 +0100Sgeo(~Sgeo@user/sgeo) (Read error: Connection reset by peer)
2022-01-27 09:16:56 +0100Morrow(~Morrow@bzq-110-168-31-106.red.bezeqint.net)
2022-01-27 09:17:00 +0100yauhsien(~yauhsien@61-231-17-3.dynamic-ip.hinet.net)
2022-01-27 09:19:14 +0100Guest98(~Guest98@82.212.88.89)
2022-01-27 09:19:17 +0100Morrow_(~Morrow@bzq-110-168-31-106.red.bezeqint.net) (Ping timeout: 240 seconds)
2022-01-27 09:19:21 +0100 <EvanR> read about those TREX records from hugs earlier, pretty snazzy
2022-01-27 09:19:31 +0100 <EvanR> beats the hell outta this
2022-01-27 09:20:48 +0100Null_A(~null_a@2601:645:8700:2290:8935:4edf:b32:6553)
2022-01-27 09:21:19 +0100Morrow(~Morrow@bzq-110-168-31-106.red.bezeqint.net) (Ping timeout: 256 seconds)
2022-01-27 09:23:34 +0100 <Guest98> Hi everyone, Im a functional programming beginner, im working through real world haskell, one exercise  asks me to write a function to check for a palindrome, I didn't want to do the simple way using the length functions or others, I am having an issue with a pattern but I am not sure why : checkPalindrome (xs ++ ys) is invalid, could someone
2022-01-27 09:23:35 +0100 <Guest98> explain why ? couldn't figure it out online :(
2022-01-27 09:24:02 +0100cosimone(~user@93-44-184-251.ip98.fastwebnet.it)
2022-01-27 09:24:05 +0100dschrempf(~dominik@070-207.dynamic.dsl.fonira.net)
2022-01-27 09:24:40 +0100 <Guest98> heres the function : https://paste.tomsmeding.com/F6xrDzBB
2022-01-27 09:24:41 +0100akegalj(~akegalj@141-136-245-236.dsl.iskon.hr)
2022-01-27 09:25:11 +0100CHUD(~CHUD@host-80-41-89-108.as13285.net)
2022-01-27 09:25:20 +0100 <Christoph[m]> Guest98: Pattern matching works with constructors, not with functions.
2022-01-27 09:25:32 +0100 <polyphem> you cant use ++ in pattern matching , how does +++ know where to split the strings
2022-01-27 09:25:55 +0100 <Guest98> right, so pattern matching is only checking for which type constructor is used for some type ?
2022-01-27 09:26:47 +0100 <polyphem> in case of functions accepting lists , you have to match the list constructors [] and (:) , at least
2022-01-27 09:26:48 +0100 <EvanR> some languages have ++ pattern matching somehow xD
2022-01-27 09:26:53 +0100 <EvanR> not haskell
2022-01-27 09:27:10 +0100 <Guest98> Okay
2022-01-27 09:27:18 +0100 <EvanR> yes pattern matching checks the constructor
2022-01-27 09:27:24 +0100 <dminuoso> I want to construct a text from a bytestring via builder by converting bytes into multiple characters. Should I use foldr or foldl'?
2022-01-27 09:27:25 +0100 <Guest98> Thanks everyone, makes sense :)
2022-01-27 09:27:42 +0100 <dminuoso> That is, would I foldr or rather foldl' over the octets of the bytestring?
2022-01-27 09:27:51 +0100 <ski> (Erlang has it as a special case. Mercury as a general case (comparable to view patterns, albeit directly connected to the usual "forward" mode of the function))
2022-01-27 09:28:14 +0100 <EvanR> for a lazy text, I'd imagine foldr
2022-01-27 09:28:21 +0100coot(~coot@213.134.190.95)
2022-01-27 09:29:08 +0100 <EvanR> to build a strict text I'd imagine using the library functions not try to do it with foldl'
2022-01-27 09:29:21 +0100 <dminuoso> EvanR: What library function are you referring to?
2022-01-27 09:29:34 +0100EvanRgoes to the haddocks
2022-01-27 09:29:35 +0100 <dminuoso> Does bytestring have some "rebuild" function?
2022-01-27 09:30:13 +0100 <dminuoso> By the way, the bytestring will never exceed 65 bytes if that's relevant.
2022-01-27 09:31:02 +0100yauhsien(~yauhsien@61-231-17-3.dynamic-ip.hinet.net) (Remote host closed the connection)
2022-01-27 09:31:47 +0100 <EvanR> really, then I daresay just convert to a list of Word8 and do whatever you want xD
2022-01-27 09:31:47 +0100yauhsien(~yauhsien@61-231-17-3.dynamic-ip.hinet.net)
2022-01-27 09:32:07 +0100 <EvanR> Data.Text.pack the resulting list of Chars
2022-01-27 09:32:19 +0100 <dminuoso> Mmm, I think Ill rather go through Data.ByteString.fold
2022-01-27 09:32:25 +0100 <dminuoso> Otherwise Id have to rely on GHC to do deforestation
2022-01-27 09:32:47 +0100 <dminuoso> Yeah Data.Text.pack wont work, I cant guarantee this to be UTF8 encoded
2022-01-27 09:33:07 +0100 <dminuoso> Which is why Ill roughly turn non-printable characters into text chunks like '\x00'
2022-01-27 09:33:11 +0100 <EvanR> ah no I wasn't suggesting dumpping the Word8 directly into Chars
2022-01-27 09:33:38 +0100 <dminuoso> Ah I see what you mean.
2022-01-27 09:33:50 +0100 <dminuoso> No that wont work either, as this is not a byte-to-char conversion
2022-01-27 09:33:52 +0100 <EvanR> I don't see a Data.Text method to take a known length vector of Chars or anything
2022-01-27 09:34:02 +0100 <dminuoso> It's actually `Word8 -> Text`, as some bytes get translated into multiple characters
2022-01-27 09:34:12 +0100 <EvanR> it has scanl, but you aren't scanning a source Text
2022-01-27 09:34:14 +0100 <dminuoso> Or rather `Word8 -> Data.Text.Builder`
2022-01-27 09:34:28 +0100 <EvanR> if you have the Builders, then you can just run the final builder
2022-01-27 09:34:44 +0100 <dminuoso> So if I build that builder chain, should I be strict in that? :p
2022-01-27 09:34:53 +0100 <dminuoso> How can I even know this beforehand
2022-01-27 09:35:00 +0100Vajb(~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) (Read error: Connection reset by peer)
2022-01-27 09:35:14 +0100 <EvanR> ok, 65 bytes
2022-01-27 09:35:22 +0100 <EvanR> but how much text does it expand to? xD
2022-01-27 09:35:36 +0100 <dminuoso> In almost all cases 65 characters of text.
2022-01-27 09:35:46 +0100 <EvanR> then I don't see a point in being lazy
2022-01-27 09:35:53 +0100 <dminuoso> In the most generate case you'd have 65*4-1 chars of output
2022-01-27 09:36:05 +0100 <dminuoso> degenerate
2022-01-27 09:36:17 +0100 <EvanR> force it now, get a packed up to 65 char strict Text
2022-01-27 09:36:17 +0100yauhsien(~yauhsien@61-231-17-3.dynamic-ip.hinet.net) (Ping timeout: 240 seconds)
2022-01-27 09:36:34 +0100 <dminuoso> Okay, so Data.ByteString.foldl' it is
2022-01-27 09:36:59 +0100 <EvanR> wait, is the folding function composing builders
2022-01-27 09:37:14 +0100 <dminuoso> Yeah
2022-01-27 09:37:38 +0100 <EvanR> then strictness doesn't matter, but order matters
2022-01-27 09:37:39 +0100 <dminuoso> I can alternatively also just mappend them together, but doing this 65 times seems like a waste of allocations
2022-01-27 09:38:01 +0100 <EvanR> compose them backwards and it ruins your day for a minute
2022-01-27 09:38:02 +0100Morrow(~Morrow@bzq-110-168-31-106.red.bezeqint.net)
2022-01-27 09:38:30 +0100yauhsien(~yauhsien@61-231-17-3.dynamic-ip.hinet.net)
2022-01-27 09:39:28 +0100 <dminuoso> Mmm, perhaps I could also use Data.ByteString.concatMap, and then just use pack!
2022-01-27 09:39:31 +0100 <EvanR> because the output will be jumbled
2022-01-27 09:39:33 +0100 <dminuoso> concatMap :: (Word8 -> ByteString) -> ByteString -> ByteString
2022-01-27 09:40:01 +0100 <dminuoso> Ah but no, this will actually force tons of mappends
2022-01-27 09:40:02 +0100Null_A(~null_a@2601:645:8700:2290:8935:4edf:b32:6553) (Read error: Connection reset by peer)
2022-01-27 09:40:36 +0100 <EvanR> bytestring concat shouldn't do a bunch of intermediate mappends, but I don't see how that gets you to your Text
2022-01-27 09:41:02 +0100 <dminuoso> concatMap f = concat . foldr ((:) . f) []
2022-01-27 09:41:14 +0100 <EvanR> well, don't do that
2022-01-27 09:41:20 +0100 <dminuoso> Yeah :)
2022-01-27 09:41:59 +0100 <EvanR> note if you had utf8 that wouldn't really help a dumb coercion to Text, since it doesn't use utf8
2022-01-27 09:44:28 +0100 <c_wraith> sufficiently new versions of text do use UTF-8
2022-01-27 09:44:53 +0100 <EvanR> orly
2022-01-27 09:47:42 +0100yauhsien(~yauhsien@61-231-17-3.dynamic-ip.hinet.net) (Ping timeout: 260 seconds)
2022-01-27 09:48:36 +0100eggplantade(~Eggplanta@2600:1700:bef1:5e10:7175:fef6:491:2dba) (Remote host closed the connection)
2022-01-27 09:49:01 +0100lawt(~lawt@2601:200:8101:f140:dea6:32ff:fea1:adf9)
2022-01-27 09:49:42 +0100machinedgod(~machinedg@24.105.81.50)
2022-01-27 09:51:55 +0100Erutuon(~Erutuon@user/erutuon) (Ping timeout: 256 seconds)
2022-01-27 09:52:05 +0100 <c_wraith> https://hackage.haskell.org/package/text-2.0/changelog
2022-01-27 09:54:50 +0100Erutuon(~Erutuon@user/erutuon)
2022-01-27 09:56:37 +0100 <EvanR> I can't wait to abuse this
2022-01-27 09:56:52 +0100 <Guest98> Is it impossible to use a parametrized type and to check if an instance of that type is equal to another one ??
2022-01-27 09:57:29 +0100 <EvanR> if the type in question is an instance of Eq you can do it
2022-01-27 09:57:45 +0100 <c_wraith> it's easy to require that two types be the same. It's quite a lot harder to test if two types are the same.
2022-01-27 09:58:10 +0100 <EvanR> ah, two different types
2022-01-27 09:58:26 +0100 <Guest98> is it possible to require for both to be instances of eq ?
2022-01-27 09:58:32 +0100 <Guest98> the same instance of eq even
2022-01-27 09:58:48 +0100 <Guest98> last line here is giving me an error : https://paste.tomsmeding.com/RS0X7dZ6
2022-01-27 09:58:48 +0100merijn(~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl)
2022-01-27 09:58:53 +0100 <ski> by "instance of that type", do you mean a value having that type ?
2022-01-27 09:59:28 +0100 <EvanR> myfun :: Eq a => a -> (a,a) -> [a] -> Whatever
2022-01-27 09:59:36 +0100 <EvanR> myfun can test all the a's for equality
2022-01-27 09:59:59 +0100 <EvanR> note they will all be of the same type
2022-01-27 10:00:06 +0100 <ski> Guest98 : yes, add `Eq a => ' just after the `::' for `checkPalindrome'
2022-01-27 10:00:19 +0100 <Guest98> Okay thanks
2022-01-27 10:00:41 +0100 <Guest98> Eq a => just means like where a is an instance of Eq ?
2022-01-27 10:00:42 +0100 <ski> (also, the definition of `getLastElement' has a type error)
2022-01-27 10:00:46 +0100 <ski> yes
2022-01-27 10:01:04 +0100 <Guest98> ah you are right, since it can return []
2022-01-27 10:01:12 +0100 <ski> instead of `tail(xs)' you can just say `tail xs'
2022-01-27 10:01:12 +0100 <Guest98> will fix, thanks again
2022-01-27 10:01:34 +0100 <ski> but better than that is to replace the `xs' in the pattern with say `(_:xs)', and then `xs' is the tail
2022-01-27 10:01:48 +0100 <Guest98> why is that better ?
2022-01-27 10:01:51 +0100 <Guest98> readability or ?
2022-01-27 10:02:05 +0100chomwitt(~chomwitt@2a02:587:dc16:6e00:12c3:7bff:fe6d:d374)
2022-01-27 10:02:36 +0100 <ski> when it's reasonable to access parts by pattern-matching, it's usually nicer to do so
2022-01-27 10:03:00 +0100 <Guest98> sure, so its just the standard, ill try to do that moving forward
2022-01-27 10:03:23 +0100 <ski> readability, yes. and the implementation knows that what you're accessing is there, so it doesn't introduce any extra checking (like `tail' possibly would do)
2022-01-27 10:03:48 +0100 <ski> (anyway, you can say just `getLastElement xs', rather than `getLastElement(xs)')
2022-01-27 10:04:14 +0100 <ski> (oh, and ditto for `init')
2022-01-27 10:04:38 +0100 <ski> if you want to, you could replace the pattern `(x:[])' by `[x]'
2022-01-27 10:04:59 +0100 <Guest98> sorry, im  just used to parenthesis from my non functional experience lol
2022-01-27 10:05:01 +0100 <Guest98> sure
2022-01-27 10:05:56 +0100 <ski> the problem with `checkPalindrome :: [a] -> Bool' was that it promised to work for *all* types `a', regardless of whether they're instances of `Eq' or not
2022-01-27 10:06:05 +0100 <ski> (not all types are)
2022-01-27 10:06:26 +0100d0ku(~d0ku@178.43.12.98.ipv4.supernova.orange.pl)
2022-01-27 10:06:40 +0100 <Guest98> i understand, will fix it and get back to you
2022-01-27 10:06:41 +0100 <Guest98> thx
2022-01-27 10:07:17 +0100 <dminuoso> EvanR: https://gist.github.com/dminuoso/3ba87266e2df0729ca575df7132d6d10
2022-01-27 10:07:20 +0100 <dminuoso> Works like a charm.
2022-01-27 10:07:29 +0100 <dminuoso> And you were right, foldl' and foldr' make a difference here with respect to the order
2022-01-27 10:07:51 +0100 <EvanR> I don't think the prime does anything
2022-01-27 10:08:14 +0100 <EvanR> or doesn't do much
2022-01-27 10:08:36 +0100 <EvanR> and foldr' might be actively bad
2022-01-27 10:09:17 +0100 <dminuoso> It's really frustrating that after a few years of Haskell, I cant say whether the prime does anything, whether foldr' would be good or bad here..
2022-01-27 10:10:11 +0100 <EvanR> you're using lazy text after all?
2022-01-27 10:10:22 +0100 <EvanR> recalculating
2022-01-27 10:10:39 +0100 <dminuoso> Builder produces lazy text necessarily
2022-01-27 10:11:00 +0100 <EvanR> makes sense
2022-01-27 10:11:29 +0100intersect(~ivoolivei@a109-50-190-38.cpe.netcabo.pt)
2022-01-27 10:11:31 +0100 <dminuoso> I figured it makes much less sense to turn it strict here, the user can always do this if they want
2022-01-27 10:11:41 +0100 <dminuoso> But Im not sure, library decisions.
2022-01-27 10:11:56 +0100 <Guest98> ski all is working now, thanks :)
2022-01-27 10:12:02 +0100 <EvanR> then you have a choice to stream it or solidify it with toStrict
2022-01-27 10:12:14 +0100 <dminuoso> Well if I want to stream it, Id rather give you a Builder
2022-01-27 10:12:23 +0100 <dminuoso> So I guess its either Builder or strict text?
2022-01-27 10:13:03 +0100 <EvanR> lazy text will let you stream it, builder will let you continue to concattenate it in whatever way
2022-01-27 10:13:45 +0100 <EvanR> since it's only like 64 chars I lean toward returning strict
2022-01-27 10:13:45 +0100 <dminuoso> Given the length I think Im fine turning it into a strict text
2022-01-27 10:13:47 +0100 <dminuoso> Yeah
2022-01-27 10:14:00 +0100 <dminuoso> Well, strictly the entirety of the output can be as long as 255
2022-01-27 10:14:14 +0100 <dminuoso> But realistically this will be as long as usual presentation forms of domains
2022-01-27 10:14:16 +0100 <dminuoso> So 10-20ish
2022-01-27 10:14:44 +0100fendor(~fendor@77.119.174.56.wireless.dyn.drei.com)
2022-01-27 10:14:54 +0100 <EvanR> there's always some asshat with a domain 400 characters long xD
2022-01-27 10:15:23 +0100 <dminuoso> No, domains cannot be longer than 253/254 characters in the usual presentation
2022-01-27 10:15:31 +0100 <EvanR> ok, url
2022-01-27 10:15:52 +0100intersect(~ivoolivei@a109-50-190-38.cpe.netcabo.pt) (Ping timeout: 268 seconds)
2022-01-27 10:16:17 +0100 <EvanR> I'm just skeptical on hard bounds for these things
2022-01-27 10:17:02 +0100tzh(~tzh@c-24-21-73-154.hsd1.or.comcast.net) (Quit: zzz)
2022-01-27 10:17:07 +0100 <Guest98> is init xs o(n) ?
2022-01-27 10:17:29 +0100 <Guest98> or even last xs
2022-01-27 10:17:32 +0100geekosaur(~geekosaur@xmonad/geekosaur) (Killed (NickServ (GHOST command used by allbery_b)))
2022-01-27 10:17:32 +0100allbery_b(~geekosaur@xmonad/geekosaur)
2022-01-27 10:17:35 +0100allbery_bgeekosaur
2022-01-27 10:18:19 +0100 <ski> yes
2022-01-27 10:19:42 +0100econo(uid147250@user/econo) (Quit: Connection closed for inactivity)
2022-01-27 10:20:22 +0100 <EvanR> but init xs is much lazier so the cost doesn't hurt as much
2022-01-27 10:20:27 +0100 <EvanR> potentially
2022-01-27 10:20:50 +0100Gurkenglas(~Gurkengla@dslb-090-186-104-244.090.186.pools.vodafone-ip.de)
2022-01-27 10:20:50 +0100 <Guest98> hm.. that means my check palindrome is o(n^2).. is there an o(n) way to do it ? I assume reverse xs is also o(n^2) since they are basically linked lists and I dont know of a stack to help with reversing
2022-01-27 10:20:50 +0100 <EvanR> last xs has sticker shock
2022-01-27 10:21:21 +0100 <merijn> Reverse shouldn't be O(n^2)??
2022-01-27 10:21:33 +0100 <EvanR> Guest98 is using a custom algorithm
2022-01-27 10:21:34 +0100 <merijn> Why would it?
2022-01-27 10:21:45 +0100 <Guest98> how do you reverse a linked list in o(n) without stacks and pointers ?
2022-01-27 10:22:07 +0100 <Guest98> (in haskell, obviously)
2022-01-27 10:22:20 +0100 <EvanR> implement reverse and see xD
2022-01-27 10:22:33 +0100 <Guest98> ok.. ill try
2022-01-27 10:22:37 +0100 <EvanR> (without stacks and pointers)
2022-01-27 10:23:06 +0100 <c_wraith> Notably, do it only with pattern matching and recursion, so you can see the amount of work it's doing
2022-01-27 10:23:22 +0100 <Guest98> noted
2022-01-27 10:23:38 +0100Vajb(~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi)
2022-01-27 10:23:44 +0100 <ski> (what does "without stacks and pointers" mean ?)
2022-01-27 10:24:36 +0100 <Guest98> oh wow
2022-01-27 10:24:45 +0100 <Guest98> wait nvm
2022-01-27 10:26:17 +0100CHUD(~CHUD@host-80-41-89-108.as13285.net) (Ping timeout: 256 seconds)
2022-01-27 10:26:18 +0100 <Guest98> that was easy i guess
2022-01-27 10:26:31 +0100 <EvanR> without stacks means don't use forth. without pointers means don't use C
2022-01-27 10:26:34 +0100 <Guest98> myReverse (x:xs) = myReverse(xs) ++ (x:[])
2022-01-27 10:26:54 +0100 <int-e> now *that* is quadratic
2022-01-27 10:27:05 +0100 <Guest98> why ?
2022-01-27 10:27:21 +0100 <EvanR> implement ++ and see xD
2022-01-27 10:27:45 +0100 <Guest98> I assumed ++ is o(1) since they are linked lists rofl
2022-01-27 10:27:53 +0100 <EvanR> :thonk:
2022-01-27 10:28:10 +0100 <EvanR> except we only have a pointer to the wrong end
2022-01-27 10:28:18 +0100 <EvanR> and we can't modify either end
2022-01-27 10:28:22 +0100 <EvanR> immutability
2022-01-27 10:28:22 +0100 <Guest98> makes sense
2022-01-27 10:28:29 +0100 <int-e> and even if we had a pointer to the end we can't update the successor
2022-01-27 10:28:44 +0100 <Guest98> i keep forgetting the immutability thing lmao
2022-01-27 10:28:46 +0100 <Guest98> let me try again
2022-01-27 10:28:55 +0100 <int-e> *but* the linked lists we have still work as stacks
2022-01-27 10:29:07 +0100 <int-e> (plural; you can have more than one)
2022-01-27 10:29:17 +0100Major_Biscuit(~MajorBisc@wlan-145-94-218-48.wlan.tudelft.nl)
2022-01-27 10:30:01 +0100 <Maxdamantus> A unique immutable list in a linearly typed system could update the successor, and (++) could be O(1).
2022-01-27 10:30:15 +0100 <Maxdamantus> (though that's not the case here)
2022-01-27 10:30:29 +0100 <EvanR> since a list is basically a stack, Guest98 you're allowed to use stacks after all lol
2022-01-27 10:30:35 +0100 <EvanR> so to speak
2022-01-27 10:31:05 +0100 <int-e> I'm mentioning this because I actually think of the linear time list reversal that way
2022-01-27 10:31:20 +0100 <EvanR> yeah I think Guest98 also did
2022-01-27 10:31:24 +0100 <int-e> so /maybe/ it's a view that helps somebody else as well
2022-01-27 10:31:33 +0100 <ski> (s/linearly typed/uniqueness type/)
2022-01-27 10:31:45 +0100 <Guest98> i understand, but im not sure how i would implement that in a [a] -> [a] function
2022-01-27 10:31:57 +0100 <Guest98> let me try though, 2 mins
2022-01-27 10:31:58 +0100 <int-e> you can add a helper
2022-01-27 10:32:03 +0100 <Guest98> whats a helper ?
2022-01-27 10:32:10 +0100 <Guest98> let me search it
2022-01-27 10:32:16 +0100 <int-e> an auxiliary function
2022-01-27 10:32:20 +0100 <c_wraith> you only need to have [a] -> [a] as the interface. You can write a more complex function to use internally
2022-01-27 10:32:30 +0100 <ski> another operations, whose raison d'etre is to help with implementing the operation you're trying to define
2022-01-27 10:32:32 +0100 <int-e> (one that has a different type than [a] -> [a])
2022-01-27 10:33:06 +0100 <Guest98> oh so like a literal other function
2022-01-27 10:33:16 +0100 <Guest98> let me think for a second then
2022-01-27 10:35:20 +0100max22-(~maxime@2a01cb08833598003a5001b0ea2a052d.ipv6.abo.wanadoo.fr)
2022-01-27 10:36:10 +0100 <EvanR> funny you can't reverse an infinite list... but... if you had two infinite lists as a zipper, then you can trivially reverse that
2022-01-27 10:36:24 +0100 <EvanR> two can'ts make a can
2022-01-27 10:37:26 +0100 <c_wraith> reversing a list is a global operation - the first observable change is that the first element has been replaced with one that came from far away
2022-01-27 10:37:42 +0100 <c_wraith> reversing a zipper is local: you keep the same neighbors.
2022-01-27 10:38:05 +0100 <EvanR> like captain kirk changing the rules of the test to win
2022-01-27 10:39:06 +0100pottsy(~pottsy@129.227.183.244) (Ping timeout: 250 seconds)
2022-01-27 10:39:30 +0100 <Guest98> this should be it no ? or am i missing something ? https://paste.tomsmeding.com/5iEskgd8
2022-01-27 10:39:32 +0100mon_aaraj(~MonAaraj@user/mon-aaraj/x-4416475) (Ping timeout: 240 seconds)
2022-01-27 10:39:42 +0100 <Guest98> wait nevermind
2022-01-27 10:39:44 +0100 <Guest98> i forgot to update it
2022-01-27 10:40:13 +0100 <EvanR> if the zipper represents a cyclic list, then you get the best of both worlds (local neighbors that are simultaneously far away)
2022-01-27 10:40:49 +0100 <Guest98> THIS should be it: https://paste.tomsmeding.com/HK7PPcrT
2022-01-27 10:40:50 +0100 <Guest98> yes ????
2022-01-27 10:41:07 +0100o(~niko@libera/staff/niko)
2022-01-27 10:41:13 +0100 <c_wraith> that'll work.
2022-01-27 10:41:35 +0100 <int-e> yes. except we would normally not pass a tuple in Haskell, just make myReverseHelper :: [a] -> [a] -> [a] instead
2022-01-27 10:41:38 +0100mon_aaraj(~MonAaraj@user/mon-aaraj/x-4416475)
2022-01-27 10:41:48 +0100 <c_wraith> it's usual to just have two parameters instead of a pair, but that probably won't result in any difference in how it's compiled
2022-01-27 10:41:59 +0100 <Guest98> why ?
2022-01-27 10:42:07 +0100 <EvanR> currying
2022-01-27 10:42:11 +0100 <int-e> the compiler is good at passing multiple arguements so it's the same speed or faster that way
2022-01-27 10:42:28 +0100 <Guest98> alright
2022-01-27 10:42:38 +0100 <c_wraith> also, if the compiler didn't optimize it out, you would be allocating a lot of pairs you don't actually need to
2022-01-27 10:43:07 +0100 <Guest98> i dont get that, you are always calling it with two different parameters so why does it matter if the params are in a pair or not
2022-01-27 10:43:30 +0100 <int-e> naively the pair is its own heap object
2022-01-27 10:43:42 +0100 <EvanR> I would not want a new pair allocating for each loop
2022-01-27 10:43:54 +0100zeenk(~zeenk@2a02:2f04:a208:c500:649e:b5e2:d15c:7960)
2022-01-27 10:43:55 +0100 <int-e> which needs to be allocated, with a new pair being created every time you call myReverseHelper
2022-01-27 10:44:05 +0100fef(~thedawn@user/thedawn) (Quit: Leaving)
2022-01-27 10:44:10 +0100 <EvanR> not that that has anything to do with reality after compilation
2022-01-27 10:44:14 +0100 <Guest98> I think i understand
2022-01-27 10:44:42 +0100 <EvanR> rather it's common to curry everything out of a defensive suspicion you'll be partially applying stuff
2022-01-27 10:44:53 +0100 <Guest98> you are saying that (xs, x:ys) is a new pair that would have to be allocated but otherwise id be just suing xs ys directly
2022-01-27 10:45:10 +0100 <Guest98> using not suing*
2022-01-27 10:45:15 +0100CHUD(~CHUD@host-80-41-89-108.as13285.net)
2022-01-27 10:45:18 +0100 <EvanR> also if you don't use a tuple, less parentheses probably
2022-01-27 10:45:26 +0100 <EvanR> definitely less commas
2022-01-27 10:45:35 +0100 <Guest98> let me try and see what i get
2022-01-27 10:45:49 +0100 <int-e> Guest98: yes. though the reality is more complicated because ghc will likely realize that the pair is immediately deconstructed and thus avoid the allocation
2022-01-27 10:46:06 +0100 <Guest98> deconstructed as in pattern matched ?
2022-01-27 10:46:17 +0100 <ski> yes
2022-01-27 10:46:27 +0100Topsi(~Tobias@dyndsl-091-249-083-234.ewe-ip-backbone.de)
2022-01-27 10:46:29 +0100 <int-e> and then it'll make an auxiliary worker function for myReverseHelper that takes two arguments
2022-01-27 10:46:41 +0100yauhsien(~yauhsien@61-231-17-3.dynamic-ip.hinet.net)
2022-01-27 10:46:43 +0100 <Guest98> ok i get it
2022-01-27 10:47:34 +0100pottsy(~pottsy@129.227.183.244)
2022-01-27 10:48:00 +0100 <Guest98> alright fixed
2022-01-27 10:48:09 +0100 <EvanR> if there's a choice between "you can pass 1 arg now or 2 args now" and "you must pass 2 args now", one of these is a superset of the other and I don't even wanna think about it again xD
2022-01-27 10:48:35 +0100 <EvanR> hence currying by default
2022-01-27 10:48:40 +0100 <int-e> We <3 the S in STG.
2022-01-27 10:48:47 +0100 <Guest98> wtf is stg
2022-01-27 10:49:01 +0100 <ski> Spineless Tagless G-machine
2022-01-27 10:49:05 +0100eggplantade(~Eggplanta@2600:1700:bef1:5e10:41be:eda7:26bd:771e)
2022-01-27 10:49:10 +0100 <Guest98> I somehow doubt that
2022-01-27 10:49:17 +0100 <int-e> Guest98: sorry that kind of wasn't for you.
2022-01-27 10:49:26 +0100 <Guest98> oh my mistake
2022-01-27 10:49:32 +0100 <ski> @quote spineless
2022-01-27 10:49:33 +0100 <lambdabot> spopejoy says: That [Spineless Tagless G Machine] will always sound like the villian in an upcoming Ghostbusters sequel to me :)
2022-01-27 10:49:44 +0100 <Guest98> thats actually a thing ? XD
2022-01-27 10:50:08 +0100 <c_wraith> it's part of (an early version of) GHC's evaluation model
2022-01-27 10:50:18 +0100 <int-e> The lack of spine in the argument stack is why passing several arguments at once isn't more expensive than passing a single one in Haskell.
2022-01-27 10:51:18 +0100Vajb(~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) (Read error: Connection reset by peer)
2022-01-27 10:52:02 +0100Vajb(~Vajb@2001:999:50:e6be:1e98:9376:d93e:4506)
2022-01-27 10:52:06 +0100ensyde(~ensyde@2600:1700:2050:1040:c06a:eb2:e18d:4418) (Quit: Leaving)
2022-01-27 10:53:15 +0100 <Guest98> I am done with this chapter i think, thanks everyone for the help, ill be back if I am stumped on anything again ;)
2022-01-27 10:53:16 +0100Vajb(~Vajb@2001:999:50:e6be:1e98:9376:d93e:4506) (Read error: Connection reset by peer)
2022-01-27 10:53:30 +0100eggplantade(~Eggplanta@2600:1700:bef1:5e10:41be:eda7:26bd:771e) (Ping timeout: 260 seconds)
2022-01-27 10:53:33 +0100cynomys(~cynomys@user/cynomys) (Remote host closed the connection)
2022-01-27 10:53:49 +0100 <Guest98> I have to say its definitely a very different way of thinking than when I am just writing some c++ or java code, its very cool
2022-01-27 10:54:12 +0100Vajb(~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi)
2022-01-27 10:54:27 +0100 <EvanR> so your reverse function basically walks down the list with a stack
2022-01-27 10:54:33 +0100 <Guest98> Is there any demand for functional programmers ?
2022-01-27 10:54:35 +0100 <Guest98> yes
2022-01-27 10:54:36 +0100 <EvanR> putting whatever it sees on the top
2022-01-27 10:54:41 +0100 <EvanR> done
2022-01-27 10:54:46 +0100 <Guest98> i couldn't think of a different way :(
2022-01-27 10:54:53 +0100 <Guest98> that is also o(n)
2022-01-27 10:55:01 +0100 <EvanR> well there's this
2022-01-27 10:55:27 +0100 <EvanR> > foldl (\stack x -> x : stack) [] [1,2,3,4,5]
2022-01-27 10:55:29 +0100 <lambdabot> [5,4,3,2,1]
2022-01-27 10:55:33 +0100cfricke(~cfricke@user/cfricke)
2022-01-27 10:55:39 +0100 <EvanR> but it does the same thing
2022-01-27 10:56:10 +0100 <Guest98> sure
2022-01-27 10:56:13 +0100 <int-e> pop from one stack, push on another, repeat until first stack is empty...
2022-01-27 10:56:31 +0100 <Guest98> yep, thats the reverse function i wrote basically
2022-01-27 10:56:36 +0100 <EvanR> the 90s game KLAX
2022-01-27 10:56:45 +0100fef(~thedawn@user/thedawn)
2022-01-27 10:56:52 +0100fef(~thedawn@user/thedawn) (Client Quit)
2022-01-27 10:57:13 +0100 <Guest98> I asked if there is any demand for functional programmers and got no response, thats a bad indication :P
2022-01-27 10:58:15 +0100 <EvanR> sorry I have enough
2022-01-27 10:58:23 +0100 <dminuoso> Im sure there is *some* demand.
2022-01-27 10:58:39 +0100 <dminuoso> Quite certain that there's at least one open position on this planet?
2022-01-27 10:59:02 +0100 <c_wraith> obviously there's demand. Otherwise there wouldn't be any. (laziness joke)
2022-01-27 10:59:20 +0100 <Guest98> lmao
2022-01-27 10:59:28 +0100 <EvanR> oooooo snap
2022-01-27 10:59:28 +0100 <Guest98> guess ill see you guys tmw, thanks again, bye.
2022-01-27 10:59:37 +0100cyphase(~cyphase@user/cyphase) (Ping timeout: 240 seconds)
2022-01-27 10:59:41 +0100Guest98(~Guest98@82.212.88.89) (Quit: Client closed)
2022-01-27 11:00:07 +0100FroskyArr(~froskyarr@203.175.13.219) (Remote host closed the connection)
2022-01-27 11:00:38 +0100Vajb(~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) (Read error: Connection reset by peer)
2022-01-27 11:00:51 +0100Vajb(~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi)
2022-01-27 11:00:55 +0100FroskyArr(~froskyarr@120.239.9.162)
2022-01-27 11:02:43 +0100 <EvanR> that's annoying
2022-01-27 11:02:58 +0100 <EvanR> when did new style Read parsers appear
2022-01-27 11:03:06 +0100 <dminuoso> What is new-style Read?
2022-01-27 11:03:07 +0100 <EvanR> I think I'm too out of date
2022-01-27 11:03:11 +0100 <dminuoso> o.o
2022-01-27 11:03:35 +0100ubert1(~Thunderbi@p200300ecdf0994bb4b7b6c6de4b2c475.dip0.t-ipconnect.de)
2022-01-27 11:03:36 +0100 <EvanR> minimal implementation readsPrec or readPrec
2022-01-27 11:03:46 +0100 <EvanR> readPrec is a new kind of parser
2022-01-27 11:03:53 +0100fef(~thedawn@user/thedawn)
2022-01-27 11:04:01 +0100 <EvanR> https://hackage.haskell.org/package/base-4.16.0.0/docs/Text-Read.html
2022-01-27 11:04:12 +0100dut(~dut@user/dut)
2022-01-27 11:04:30 +0100chele(~chele@user/chele)
2022-01-27 11:04:41 +0100 <dminuoso> https://hackage.haskell.org/package/base-4.16.0.0/docs/Text-ParserCombinators-ReadPrec.html#t:Read…
2022-01-27 11:04:51 +0100 <dminuoso> -- Copyright : (c) The University of Glasgow 2002
2022-01-27 11:04:56 +0100 <dminuoso> That sounds.. old?
2022-01-27 11:05:39 +0100 <EvanR> just did a double take, 4.16 is latest base
2022-01-27 11:05:54 +0100 <EvanR> with haddocks
2022-01-27 11:06:47 +0100__monty__(~toonn@user/toonn)
2022-01-27 11:06:53 +0100 <dminuoso> Just wondering since you called it new, but if that module has existed for 20 years?
2022-01-27 11:06:59 +0100 <dminuoso> Merely curious
2022-01-27 11:07:13 +0100cyphase(~cyphase@user/cyphase)
2022-01-27 11:08:01 +0100 <merijn> I mean, Text.ParserCombinators.ReadP and Text.ParserCombinators.ReadPrec both already exist in base 3.0, so...
2022-01-27 11:08:28 +0100 <EvanR> ‘readPrec’ is not a (visible) method of class ‘Read’
2022-01-27 11:08:48 +0100 <dminuoso> I feel like I dont know anything. We can have invisible methods? :(
2022-01-27 11:09:02 +0100 <dminuoso> This is too much
2022-01-27 11:09:06 +0100 <int-e> dminuoso: it was converted from .lhs to .hs in 2002, before that it said: % $Id: ReadP.lhs % (c) The University of Glasgow, 1994-2000
2022-01-27 11:09:27 +0100 <int-e> readPrec != readsPrec
2022-01-27 11:09:31 +0100 <EvanR> well
2022-01-27 11:09:36 +0100 <int-e> you can have class methods that aren't exported
2022-01-27 11:09:44 +0100 <int-e> making them invisible
2022-01-27 11:09:54 +0100 <EvanR> apparently I do have readPrec but I can't implement it without importing Text.Read
2022-01-27 11:10:04 +0100 <EvanR> unlike Show
2022-01-27 11:10:22 +0100 <EvanR> not exactly encouraging
2022-01-27 11:11:00 +0100 <int-e> Well showsPrec is in the Haskell report, readPrec isn't?
2022-01-27 11:11:20 +0100 <int-e> (but readsPrec and readList are)
2022-01-27 11:11:29 +0100OscarH(~OscarH@2a02:c7f:a0da:ae00:ba27:ebff:fe84:d2f4) (Quit: ZNC 1.7.2+deb3 - https://znc.in)
2022-01-27 11:11:32 +0100 <EvanR> oh it's GHC specific
2022-01-27 11:11:44 +0100OscarH(~OscarH@90.201.86.195)
2022-01-27 11:11:49 +0100 <EvanR> and highly recommended
2022-01-27 11:12:40 +0100 <merijn> I'd say "not having a Read instance" is highly recommended :p
2022-01-27 11:13:20 +0100 <EvanR> not a fan?
2022-01-27 11:13:42 +0100kritzefitz(~kritzefit@debian/kritzefitz) (Remote host closed the connection)
2022-01-27 11:13:51 +0100 <int-e> > read ('"' : repeat ' ') :: Int
2022-01-27 11:13:55 +0100kritzefitz(~kritzefit@debian/kritzefitz)
2022-01-27 11:13:58 +0100 <lambdabot> mueval-core: Time limit exceeded
2022-01-27 11:14:16 +0100 <int-e> > read ('"' : replicate 42 ' ') :: Int
2022-01-27 11:14:18 +0100 <lambdabot> *Exception: Prelude.read: no parse
2022-01-27 11:14:34 +0100 <EvanR> I made a working show instance for this crazy ass type and thought it might be cool to restore it from showed state
2022-01-27 11:14:46 +0100 <int-e> Read is convenient. I think that's about the only positive thing I can say about it.
2022-01-27 11:14:46 +0100 <EvanR> and now it's a rabbit hole
2022-01-27 11:15:13 +0100 <int-e> (to use, not to implement when `deriving` doesn't cut it)
2022-01-27 11:15:14 +0100Erutuon(~Erutuon@user/erutuon) (Ping timeout: 256 seconds)
2022-01-27 11:16:57 +0100yauhsien(~yauhsien@61-231-17-3.dynamic-ip.hinet.net) (Remote host closed the connection)
2022-01-27 11:17:00 +0100 <dminuoso> merijn: One major thing I dislike about Read, is this coherence between Show and Read that is often assumed.
2022-01-27 11:17:10 +0100 <merijn> EvanR: Read is slow and bad
2022-01-27 11:17:38 +0100 <merijn> It's convenient for some ghetto things while developping. But entirely unsuitable for anything serious
2022-01-27 11:17:41 +0100 <int-e> And this is basically unfixable because the slow and bad things are in the Haskell report.
2022-01-27 11:17:45 +0100 <dminuoso> int-e: I found, if you really want to quickly serialize and deserialize stuff, aesons TH/generics is much better and robust.
2022-01-27 11:17:53 +0100 <dminuoso> Than compared to Show/Read
2022-01-27 11:18:18 +0100 <dminuoso> And you get free interop with other languages as well.
2022-01-27 11:19:12 +0100 <EvanR> all of Read is bad or just Reads stuff
2022-01-27 11:19:23 +0100 <EvanR> the new style parsers are also slow and bad?
2022-01-27 11:19:45 +0100 <int-e> Yes
2022-01-27 11:19:49 +0100 <EvanR> about seriousness, I mean, Show is basically in the same boat
2022-01-27 11:20:01 +0100 <merijn> EvanR: All of it, tbh
2022-01-27 11:20:06 +0100 <EvanR> the output is atrocious by default and typing deriving Show everywhere sucks
2022-01-27 11:20:22 +0100 <int-e> The cardinal error is that everything in the standard and derived instances goes through a Haskell tokenizer (lex :: ReadP...)
2022-01-27 11:20:36 +0100 <merijn> I mean, a custom Read implementation using (mega)parsec might not be bad, but then just use those :p
2022-01-27 11:20:49 +0100 <int-e> which is how read ('"' : replicate 42 ' ') :: Int diverges instead of just giving up at the "
2022-01-27 11:21:15 +0100 <int-e> err not that one, I meant the `repeat ' '` variant.
2022-01-27 11:21:59 +0100 <int-e> but the lexer also means that even when it works, parsing an int doesn't use the simple state machine that it should be using... and it has a profound effect on performance
2022-01-27 11:22:53 +0100yauhsien(~yauhsien@61-231-17-3.dynamic-ip.hinet.net)
2022-01-27 11:22:59 +0100 <int-e> `Show` is mostly fine, except that without `Read` it's not good for serialization.
2022-01-27 11:23:36 +0100 <int-e> (And of course it's tied to String... which is questionable, but handled surprisingly efficiently in practice)
2022-01-27 11:24:07 +0100yauhsien(~yauhsien@61-231-17-3.dynamic-ip.hinet.net) (Remote host closed the connection)
2022-01-27 11:24:56 +0100yauhsien(~yauhsien@61-231-17-3.dynamic-ip.hinet.net)
2022-01-27 11:29:54 +0100yauhsien(~yauhsien@61-231-17-3.dynamic-ip.hinet.net) (Ping timeout: 260 seconds)
2022-01-27 11:30:11 +0100raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net)
2022-01-27 11:30:32 +0100tomjaguarpaw(~tom@li367-225.members.linode.com)
2022-01-27 11:36:33 +0100Athas(~athas@sigkill.dk) (Ping timeout: 256 seconds)
2022-01-27 11:37:05 +0100lambdap2(~lambdap@static.167.190.119.168.clients.your-server.de)
2022-01-27 11:37:07 +0100fiddlerwoaroof(~fiddlerwo@user/fiddlerwoaroof) (Ping timeout: 256 seconds)
2022-01-27 11:37:07 +0100lambdabot(~lambdabot@haskell/bot/lambdabot) (Ping timeout: 256 seconds)
2022-01-27 11:37:07 +0100shanemikel(~shanemike@desk.roadwar.net) (Ping timeout: 256 seconds)
2022-01-27 11:37:14 +0100Athas(athas@sigkill.dk)
2022-01-27 11:37:19 +0100sajith_(~sajith@user/sajith)
2022-01-27 11:37:41 +0100mjrosenb(~mjrosenb@pool-108-54-97-96.nycmny.fios.verizon.net) (Ping timeout: 256 seconds)
2022-01-27 11:37:41 +0100douglaswinship(~douglaswi@78.40.148.180) (Ping timeout: 256 seconds)
2022-01-27 11:37:41 +0100heath(~heath@user/heath) (Ping timeout: 256 seconds)
2022-01-27 11:37:41 +0100bcoppens(~bartcopp@vpn2.bartcoppens.be) (Ping timeout: 256 seconds)
2022-01-27 11:37:41 +0100sajith(~sajith@user/sajith) (Ping timeout: 256 seconds)
2022-01-27 11:37:45 +0100fiddlerwoaroof(~fiddlerwo@user/fiddlerwoaroof)
2022-01-27 11:37:47 +0100bcoppens(~bartcopp@vpn2.bartcoppens.be)
2022-01-27 11:37:49 +0100mjrosenb(~mjrosenb@pool-108-54-97-96.nycmny.fios.verizon.net)
2022-01-27 11:37:53 +0100douglaswinship(~douglaswi@78.40.148.180)
2022-01-27 11:37:59 +0100heath(~heath@user/heath)
2022-01-27 11:38:15 +0100jjhoo(~jahakala@user/jjhoo) (Ping timeout: 256 seconds)
2022-01-27 11:38:15 +0100myme(~myme@40.51-175-185.customer.lyse.net) (Ping timeout: 256 seconds)
2022-01-27 11:38:15 +0100lambdap(~lambdap@static.167.190.119.168.clients.your-server.de) (Ping timeout: 256 seconds)
2022-01-27 11:38:15 +0100lambdap2lambdap
2022-01-27 11:38:26 +0100shanemikel(~shanemike@desk.roadwar.net)
2022-01-27 11:38:37 +0100lambdabot(~lambdabot@silicon.int-e.eu)
2022-01-27 11:38:37 +0100lambdabot(~lambdabot@silicon.int-e.eu) (Changing host)
2022-01-27 11:38:37 +0100lambdabot(~lambdabot@haskell/bot/lambdabot)
2022-01-27 11:39:51 +0100myme(~myme@40.51-175-185.customer.lyse.net)
2022-01-27 11:39:58 +0100jjhoo(~jahakala@user/jjhoo)
2022-01-27 11:40:23 +0100coot(~coot@213.134.190.95) (Quit: coot)
2022-01-27 11:40:48 +0100coot(~coot@213.134.190.95)
2022-01-27 11:43:21 +0100Morrow_(~Morrow@bzq-110-168-31-106.red.bezeqint.net)
2022-01-27 11:43:21 +0100 <dminuoso> Is there a common idiom to express a law like `pretty . parse ~~~ id` where I want to emphasis "ignoring the Left case of parse"?
2022-01-27 11:43:35 +0100phma(phma@2001:5b0:211f:5068:5bee:1f6d:8374:247d) (Read error: Connection reset by peer)
2022-01-27 11:44:47 +0100 <dminuoso> I mean I could write: right pretty . parse ~~~ Right
2022-01-27 11:44:52 +0100 <dminuoso> But would that get the point across?
2022-01-27 11:45:14 +0100phma(phma@2001:5b0:211c:37e8:e22d:196:60ef:f166)
2022-01-27 11:46:04 +0100Morrow_(~Morrow@bzq-110-168-31-106.red.bezeqint.net) (Read error: Connection reset by peer)
2022-01-27 11:46:58 +0100Morrow(~Morrow@bzq-110-168-31-106.red.bezeqint.net) (Ping timeout: 256 seconds)
2022-01-27 11:47:58 +0100Lord_of_Life(~Lord@user/lord-of-life/x-2819915) (Ping timeout: 250 seconds)
2022-01-27 11:49:27 +0100tubogram4(~tubogram@user/tubogram) (Quit: See ya later!)
2022-01-27 11:50:33 +0100haskellberryfinn(~nut@roc37-h01-176-170-197-243.dsl.sta.abo.bbox.fr)
2022-01-27 11:52:39 +0100Lord_of_Life(~Lord@user/lord-of-life/x-2819915)
2022-01-27 11:52:46 +0100jgeerds(~jgeerds@55d4a547.access.ecotel.net)
2022-01-27 11:55:42 +0100 <opqdonut> dminuoso: it's usually simpler to specify `parse . pretty ~~~ id`
2022-01-27 11:55:46 +0100 <opqdonut> so you always start with a valid AST
2022-01-27 11:59:08 +0100 <dminuoso> opqdonut: Shouldn't that read Right though?
2022-01-27 11:59:38 +0100jmc(~jmc@softbank126150248096.bbtec.net) (Quit: Leaving)
2022-01-27 12:00:40 +0100__monty__(~toonn@user/toonn) (Quit: leaving)
2022-01-27 12:00:48 +0100intersect(~ivoolivei@a109-50-190-38.cpe.netcabo.pt)
2022-01-27 12:01:03 +0100 <opqdonut> yeah if parse returns Either Err AST then `parse . pretty ~~~ pure`
2022-01-27 12:01:13 +0100 <opqdonut> or Right if you want concreteness
2022-01-27 12:04:57 +0100intersect(~ivoolivei@a109-50-190-38.cpe.netcabo.pt) (Ping timeout: 240 seconds)
2022-01-27 12:07:14 +0100zer0bitz(~zer0bitz@2001:2003:f444:a000:a9ef:8cb1:3f34:9694)
2022-01-27 12:07:27 +0100haskellberryfinn(~nut@roc37-h01-176-170-197-243.dsl.sta.abo.bbox.fr) (Ping timeout: 250 seconds)
2022-01-27 12:08:56 +0100fef(~thedawn@user/thedawn) (Remote host closed the connection)
2022-01-27 12:09:47 +0100haskellberryfinn(~nut@roc37-h01-176-170-197-243.dsl.sta.abo.bbox.fr)
2022-01-27 12:10:03 +0100waleee(~waleee@2001:9b0:21d:fc00:398f:b003:b90d:acf4)
2022-01-27 12:12:28 +0100d0ku(~d0ku@178.43.12.98.ipv4.supernova.orange.pl) (Ping timeout: 256 seconds)
2022-01-27 12:13:14 +0100dschrempf(~dominik@070-207.dynamic.dsl.fonira.net) (Quit: WeeChat 3.3)
2022-01-27 12:15:04 +0100d0ku(~d0ku@178.43.12.98.ipv4.supernova.orange.pl)
2022-01-27 12:17:05 +0100 <jackdk> dminuoso: I have seen these called "round-tripping properties"
2022-01-27 12:17:25 +0100 <jackdk> dminuoso: https://hackage.haskell.org/package/hedgehog-1.1/docs/Hedgehog-Internal-Tripping.html#v:tripping
2022-01-27 12:18:51 +0100 <geekosaur> if we're being formal, I think idempotency?
2022-01-27 12:18:59 +0100jgeerds(~jgeerds@55d4a547.access.ecotel.net) (Ping timeout: 252 seconds)
2022-01-27 12:19:10 +0100haskellberryfinn(~nut@roc37-h01-176-170-197-243.dsl.sta.abo.bbox.fr) (Ping timeout: 250 seconds)
2022-01-27 12:20:14 +0100 <polyphem> isnt idempotency : f a == f (f a) ?
2022-01-27 12:20:14 +0100 <jackdk> idempotency is P(P(x)) = P(x), no?
2022-01-27 12:20:31 +0100 <polyphem> isomorphic , maybe
2022-01-27 12:20:36 +0100 <geekosaur> yes, but here it'd a compund action that is idempotent
2022-01-27 12:21:50 +0100 <geekosaur> (parse . pretty) is the idempotent function since you should get the same result by doing it twice
2022-01-27 12:21:57 +0100kanin(~kanin@2409:8a14:10e7:52d0:4526:1e35:f024:52e7) (Ping timeout: 240 seconds)
2022-01-27 12:22:07 +0100 <geekosaur> admittedly that's a somewhat roundabout way of expressing the property
2022-01-27 12:22:23 +0100 <polyphem> geekosaur: yes, in that case it is
2022-01-27 12:22:24 +0100fef(~thedawn@user/thedawn)
2022-01-27 12:22:36 +0100Null_A(~null_a@2601:645:8700:2290:8935:4edf:b32:6553)
2022-01-27 12:25:13 +0100yauhsien(~yauhsien@61-231-17-3.dynamic-ip.hinet.net)
2022-01-27 12:29:15 +0100slowtyper(~slowtyper@user/slowtyper) (Ping timeout: 256 seconds)
2022-01-27 12:29:28 +0100 <ski> a retract situation `rectraction . section = id' gives rise to an idempotent `section . retraction'
2022-01-27 12:29:37 +0100slowtyper(~slowtyper@user/slowtyper)
2022-01-27 12:30:02 +0100yauhsien(~yauhsien@61-231-17-3.dynamic-ip.hinet.net) (Ping timeout: 256 seconds)
2022-01-27 12:30:11 +0100waleee(~waleee@2001:9b0:21d:fc00:398f:b003:b90d:acf4) (Ping timeout: 250 seconds)
2022-01-27 12:32:12 +0100Null_A(~null_a@2601:645:8700:2290:8935:4edf:b32:6553) (Remote host closed the connection)
2022-01-27 12:38:49 +0100Vajb(~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) (Read error: Connection reset by peer)
2022-01-27 12:38:58 +0100Vajb(~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi)
2022-01-27 12:43:54 +0100xsperry(~xs@user/xsperry)
2022-01-27 12:47:46 +0100merijn(~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl) (Ping timeout: 250 seconds)
2022-01-27 12:48:09 +0100merijn(~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl)
2022-01-27 12:53:16 +0100merijn(~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl) (Ping timeout: 256 seconds)
2022-01-27 12:53:33 +0100 <tomjaguarpaw> parse . pretty . parse == parse and pretty . parse . pretty == pretty are stronger conditions than idempotency. That's what I've used in the past.
2022-01-27 12:53:51 +0100merijn(~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl)
2022-01-27 12:55:56 +0100ski. o O ( <https://en.wikipedia.org/wiki/Pseudo-inverse> )
2022-01-27 12:57:27 +0100polyphemlikes skis think bubble notation
2022-01-27 12:59:08 +0100merijn(~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl) (Ping timeout: 252 seconds)
2022-01-27 12:59:46 +0100merijn(~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl)
2022-01-27 13:02:20 +0100romesrf(~romes@44.190.189.46.rev.vodafone.pt)
2022-01-27 13:02:44 +0100mvk(~mvk@2607:fea8:5cdc:bf00::a2bf)
2022-01-27 13:04:32 +0100merijn(~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl) (Ping timeout: 240 seconds)
2022-01-27 13:05:16 +0100kritzefitz(~kritzefit@debian/kritzefitz) (Remote host closed the connection)
2022-01-27 13:07:47 +0100kritzefitz(~kritzefit@debian/kritzefitz)
2022-01-27 13:08:00 +0100fef(~thedawn@user/thedawn) (Ping timeout: 276 seconds)
2022-01-27 13:08:39 +0100ubert1(~Thunderbi@p200300ecdf0994bb4b7b6c6de4b2c475.dip0.t-ipconnect.de) (Read error: Connection reset by peer)
2022-01-27 13:08:47 +0100chenqisu1(~chenqisu1@183.217.200.249)
2022-01-27 13:09:02 +0100chenqisu1(~chenqisu1@183.217.200.249) (Remote host closed the connection)
2022-01-27 13:11:19 +0100 <zzz> where can i get a searchable list of compiler warnings?
2022-01-27 13:11:44 +0100 <dminuoso> The user manual
2022-01-27 13:11:50 +0100 <dminuoso> https://downloads.haskell.org/~ghc/9.0.1/docs/html/users_guide/using-warnings.html
2022-01-27 13:12:21 +0100 <zzz> i remeber there being a command (?)
2022-01-27 13:12:26 +0100 <geekosaur> there's also a llist of all compiler options which includes all the warning options
2022-01-27 13:13:18 +0100 <geekosaur> ghc --show-options ?
2022-01-27 13:13:51 +0100nunggu(~q@user/nunggu) (Ping timeout: 276 seconds)
2022-01-27 13:14:44 +0100yauhsien(~yauhsien@61-231-17-3.dynamic-ip.hinet.net)
2022-01-27 13:15:53 +0100 <zzz> that was it!
2022-01-27 13:16:14 +0100 <zzz> so there's no warning for the use of undefined?
2022-01-27 13:16:17 +0100kjak(~kjak@pool-108-45-56-21.washdc.fios.verizon.net) (Ping timeout: 240 seconds)
2022-01-27 13:16:44 +0100 <geekosaur> none that I'm aware of
2022-01-27 13:19:23 +0100 <zzz> sometimes i fill my code with undefineds and progressively turn them into "defined" code. i was hoping there was a way for the compiler to keep warning me while i still have one or more undefined, in case i forget some
2022-01-27 13:19:34 +0100yauhsien(~yauhsien@61-231-17-3.dynamic-ip.hinet.net) (Ping timeout: 260 seconds)
2022-01-27 13:20:04 +0100 <polyphem> grep -R undefined ?
2022-01-27 13:20:14 +0100 <geekosaur> search in an editor (or grep) is generally good for that
2022-01-27 13:20:38 +0100 <zzz> polyphem: that's what i'm doing now
2022-01-27 13:20:44 +0100fef(~thedawn@user/thedawn)
2022-01-27 13:20:45 +0100 <geekosaur> I also do things like `(...) = undefined` and then search for uses of that
2022-01-27 13:20:52 +0100 <geekosaur> it stands out more
2022-01-27 13:21:08 +0100 <geekosaur> and to me reads somewhat better than undefined
2022-01-27 13:21:16 +0100dschrempf(~dominik@070-207.dynamic.dsl.fonira.net)
2022-01-27 13:23:03 +0100intersect(~ivoolivei@a109-50-190-38.cpe.netcabo.pt)
2022-01-27 13:25:33 +0100fef(~thedawn@user/thedawn) (Ping timeout: 276 seconds)
2022-01-27 13:27:07 +0100 <zzz> somewhat related question: is there something keeping the type system from detecting if something has type `:: forall a. a` and wouldn't this be iseful for some kind of "bottomlessness check (modulo some infinite recursion?)
2022-01-27 13:27:30 +0100alMalsamo(~alMalsamo@gateway/tor-sasl/almalsamo) (Ping timeout: 276 seconds)
2022-01-27 13:28:12 +0100 <zzz> by detecting i mean warning if there is any possibility of your program evaluating some value :: a
2022-01-27 13:28:49 +0100 <geekosaur> but that also rules out useful things like
2022-01-27 13:28:52 +0100 <geekosaur> :t forever
2022-01-27 13:28:53 +0100 <lambdabot> Applicative f => f a -> f b
2022-01-27 13:29:55 +0100 <zzz> the f is constrained, that would be fine
2022-01-27 13:31:23 +0100 <polyphem> :t id
2022-01-27 13:31:25 +0100 <lambdabot> a -> a
2022-01-27 13:32:32 +0100 <zzz> i'm talking specifically about `:: forall a. a`
2022-01-27 13:33:01 +0100 <zzz> hence the "modulo some infinite recursion"
2022-01-27 13:33:43 +0100 <lortabac> zzz: instead of using undefined, you can use _ and get a warning
2022-01-27 13:33:50 +0100 <ski> @type \(v :: Void) -> case v of {}
2022-01-27 13:33:51 +0100 <lambdabot> Void -> p
2022-01-27 13:34:40 +0100merijn(~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl)
2022-01-27 13:34:57 +0100tubogram4(~tubogram@user/tubogram)
2022-01-27 13:35:09 +0100 <zzz> > (\(v :: Void) -> case v of {}) Void
2022-01-27 13:35:11 +0100 <lambdabot> error:
2022-01-27 13:35:11 +0100 <lambdabot> • Data constructor not in scope: Void :: Void
2022-01-27 13:35:11 +0100 <lambdabot> • Perhaps you meant one of these:
2022-01-27 13:35:29 +0100tubogram4(~tubogram@user/tubogram) (Client Quit)
2022-01-27 13:35:33 +0100 <zzz> > data Void; (\(v :: Void) -> case v of {}) Void
2022-01-27 13:35:35 +0100 <lambdabot> <hint>:1:1: error: parse error on input ‘data’
2022-01-27 13:35:51 +0100 <dminuoso> zzz: Based on my sketchy understanding, I think it'd be very hard to special case that in.
2022-01-27 13:36:18 +0100 <zzz> how do i get lambdabot to do this?
2022-01-27 13:36:24 +0100xkuru(~xkuru@user/xkuru) (Remote host closed the connection)
2022-01-27 13:36:30 +0100 <dminuoso> @let data Void
2022-01-27 13:36:31 +0100 <lambdabot> Defined.
2022-01-27 13:36:38 +0100 <dminuoso> > (\(v :: Void) -> case v of {}) Void
2022-01-27 13:36:40 +0100 <lambdabot> error:
2022-01-27 13:36:40 +0100 <lambdabot> Ambiguous occurrence ‘Void’
2022-01-27 13:36:40 +0100 <lambdabot> It could refer to
2022-01-27 13:36:50 +0100 <dminuoso> @let data MyVoid
2022-01-27 13:36:51 +0100 <lambdabot> Defined.
2022-01-27 13:36:58 +0100 <dminuoso> Now what?
2022-01-27 13:37:17 +0100 <zzz> > data Void; (\(v :: MyVoid) -> case v of {}) MyVoid
2022-01-27 13:37:18 +0100 <lambdabot> <hint>:1:1: error: parse error on input ‘data’
2022-01-27 13:37:26 +0100 <zzz> > (\(v :: MyVoid) -> case v of {}) MyVoid
2022-01-27 13:37:26 +0100tubogram4(~tubogram@user/tubogram)
2022-01-27 13:37:28 +0100 <lambdabot> error:
2022-01-27 13:37:28 +0100 <lambdabot> • Data constructor not in scope: MyVoid :: MyVoid
2022-01-27 13:37:28 +0100 <lambdabot> • Perhaps you meant variable ‘_Void’ (imported from Control.Lens)
2022-01-27 13:37:37 +0100 <zzz> ah
2022-01-27 13:37:42 +0100zzzfacepalms
2022-01-27 13:37:53 +0100 <geekosaur> I thought the point of (My)Void was that there were no data constructors forit?
2022-01-27 13:37:56 +0100 <geekosaur> therefore no values
2022-01-27 13:38:21 +0100 <geekosaur> I think the _ suggestion (unannotated typed hole) was probably best
2022-01-27 13:38:32 +0100 <polyphem> :t Proxy :: Void
2022-01-27 13:38:33 +0100 <lambdabot> error:
2022-01-27 13:38:33 +0100 <lambdabot> Ambiguous occurrence ‘Void’
2022-01-27 13:38:33 +0100 <lambdabot> It could refer to
2022-01-27 13:38:48 +0100xkuru(~xkuru@user/xkuru)
2022-01-27 13:39:05 +0100merijn(~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl) (Ping timeout: 250 seconds)
2022-01-27 13:39:12 +0100 <dminuoso> zzz: For what its worth, in my experience what creates *far* more bottoms than undefined, is `read`.
2022-01-27 13:39:15 +0100 <geekosaur> :t Proxy :: MyVoid -- don't think this works
2022-01-27 13:39:15 +0100 <lambdabot> error:
2022-01-27 13:39:16 +0100 <lambdabot> • Couldn't match expected type ‘MyVoid’ with actual type ‘Proxy t0’
2022-01-27 13:39:16 +0100 <lambdabot> • In the expression: Proxy :: MyVoid
2022-01-27 13:39:34 +0100 <geekosaur> :t Proxy :: Proxy MyVoid -- this does but isn't what was asked
2022-01-27 13:39:35 +0100 <lambdabot> Proxy MyVoid
2022-01-27 13:39:40 +0100merijn(~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl)
2022-01-27 13:39:50 +0100 <polyphem> yep
2022-01-27 13:40:06 +0100 <dminuoso> `read` tends to look so innocent, and if thats hidden inside some library, this can cause issues in the entire transitive dependency graph
2022-01-27 13:42:12 +0100 <zzz> ok i see
2022-01-27 13:42:21 +0100tubogram4(~tubogram@user/tubogram) (Quit: See ya later!)
2022-01-27 13:42:54 +0100 <dminuoso> Something like `undefined` can easily be addressed by git hooks or perhaps a linter
2022-01-27 13:43:11 +0100 <dminuoso> Or maybe your editor has some tooling for that as well
2022-01-27 13:43:21 +0100nunggu(~q@user/nunggu)
2022-01-27 13:43:24 +0100tubogram4(~tubogram@user/tubogram)
2022-01-27 13:43:41 +0100haskellberryfinn(~nut@roc37-h01-176-170-197-243.dsl.sta.abo.bbox.fr)
2022-01-27 13:44:50 +0100merijn(~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl) (Ping timeout: 256 seconds)
2022-01-27 13:47:50 +0100 <lortabac> zzz: in alternative you can define your own undefined with a custom warning
2022-01-27 13:47:58 +0100 <lortabac> classy-prelude does it
2022-01-27 13:48:57 +0100 <lortabac> but I think _ is the best way to declare unfinished pieces of code
2022-01-27 13:54:47 +0100Pickchea(~private@user/pickchea)
2022-01-27 13:57:12 +0100jespada(~jespada@87.74.36.188) (Quit: Textual IRC Client: www.textualapp.com)
2022-01-27 13:59:30 +0100kanin(~kanin@2409:8a14:10e7:52d0:e868:e5f3:fdc5:9fd)
2022-01-27 14:00:31 +0100kanin(~kanin@2409:8a14:10e7:52d0:e868:e5f3:fdc5:9fd) (Max SendQ exceeded)
2022-01-27 14:00:58 +0100merijn(~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl)
2022-01-27 14:01:00 +0100kanin(~kanin@2409:8a14:10e7:52d0:e868:e5f3:fdc5:9fd)
2022-01-27 14:01:21 +0100mason0(~bc8147f2@cerf.good1.com)
2022-01-27 14:01:39 +0100denbrahe[m]denbrahe
2022-01-27 14:04:35 +0100max22-(~maxime@2a01cb08833598003a5001b0ea2a052d.ipv6.abo.wanadoo.fr) (Ping timeout: 252 seconds)
2022-01-27 14:04:35 +0100denbrahe(~denbrahem@2001:470:69fc:105::19c0) (Quit: Reconnecting)
2022-01-27 14:09:20 +0100kmein(~weechat@user/kmein) (Quit: ciao kakao)
2022-01-27 14:09:40 +0100kmein(~weechat@user/kmein)
2022-01-27 14:10:55 +0100fendor_(~fendor@77.119.199.145.wireless.dyn.drei.com)
2022-01-27 14:13:54 +0100fendor(~fendor@77.119.174.56.wireless.dyn.drei.com) (Ping timeout: 268 seconds)
2022-01-27 14:16:50 +0100bitdex(~bitdex@gateway/tor-sasl/bitdex) (Quit: = "")
2022-01-27 14:17:44 +0100szkl(uid110435@id-110435.uxbridge.irccloud.com) (Quit: Connection closed for inactivity)
2022-01-27 14:20:30 +0100intersect(~ivoolivei@a109-50-190-38.cpe.netcabo.pt) (Ping timeout: 250 seconds)
2022-01-27 14:25:07 +0100slowButPresent(~slowButPr@user/slowbutpresent)
2022-01-27 14:25:57 +0100mon_aaraj(~MonAaraj@user/mon-aaraj/x-4416475) (Ping timeout: 240 seconds)
2022-01-27 14:27:32 +0100Henson(~kvirc@107-179-133-201.cpe.teksavvy.com) (Ping timeout: 240 seconds)
2022-01-27 14:28:08 +0100mon_aaraj(~MonAaraj@user/mon-aaraj/x-4416475)
2022-01-27 14:32:55 +0100ph88(~ph88@2a02:8109:9e00:71d0:3c42:1d7a:5c49:19d9) (Remote host closed the connection)
2022-01-27 14:33:18 +0100ph88(~ph88@2a02:8109:9e00:71d0:f12b:1b26:c11c:e722)
2022-01-27 14:33:45 +0100yauhsien(~yauhsien@61-231-17-3.dynamic-ip.hinet.net)
2022-01-27 14:37:44 +0100intersect(~ivoolivei@a109-50-190-38.cpe.netcabo.pt)
2022-01-27 14:38:27 +0100yauhsien(~yauhsien@61-231-17-3.dynamic-ip.hinet.net) (Ping timeout: 250 seconds)
2022-01-27 14:40:08 +0100andreabedini(~andreabed@8s8kj6nj5000h5zkmpxr.ip6.superloop.com)
2022-01-27 14:45:49 +0100ph88(~ph88@2a02:8109:9e00:71d0:f12b:1b26:c11c:e722) (Quit: Leaving)
2022-01-27 14:46:06 +0100ph88(~ph88@95.90.247.31)
2022-01-27 14:46:57 +0100Megant(megant@user/megant) (Ping timeout: 240 seconds)
2022-01-27 14:48:25 +0100dschrempf(~dominik@070-207.dynamic.dsl.fonira.net) (Quit: WeeChat 3.3)
2022-01-27 14:49:05 +0100Megant(megant@user/megant)
2022-01-27 14:52:35 +0100eggplantade(~Eggplanta@2600:1700:bef1:5e10:41be:eda7:26bd:771e)
2022-01-27 14:54:31 +0100intersec1(~ivoolivei@a109-50-190-38.cpe.netcabo.pt)
2022-01-27 14:54:35 +0100intersect(~ivoolivei@a109-50-190-38.cpe.netcabo.pt) (Read error: No route to host)
2022-01-27 14:55:13 +0100 <unclechu> Hey, does anyone has any idea why names of the property tests are snake_cased?
2022-01-27 14:55:28 +0100 <unclechu> https://hackage.haskell.org/package/QuickCheck-2.14.2/docs/Test-QuickCheck.html
2022-01-27 14:55:30 +0100 <unclechu> https://hackage.haskell.org/package/hedgehog-1.0.5/docs/Hedgehog.html
2022-01-27 14:55:32 +0100 <unclechu> Two examples
2022-01-27 14:55:51 +0100 <unclechu> “prop_reverse” for instance
2022-01-27 14:56:01 +0100 <maerwald> does that bother you?
2022-01-27 14:56:29 +0100 <geekosaur> possibly to help avoid collision with exported functions
2022-01-27 14:56:37 +0100eggplantade(~Eggplanta@2600:1700:bef1:5e10:41be:eda7:26bd:771e) (Ping timeout: 240 seconds)
2022-01-27 14:56:45 +0100 <geekosaur> in any case it's just convention, not a requirement
2022-01-27 14:57:33 +0100 <unclechu> geekosaur Okay, but the convention actually is? What’s the point of doing it?
2022-01-27 14:57:48 +0100 <unclechu> What the convention actually is*
2022-01-27 14:58:08 +0100 <geekosaur> how would I know? I'm not the author of either
2022-01-27 14:58:26 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 15:00:50 +0100akegalj(~akegalj@141-136-245-236.dsl.iskon.hr) (Quit: Lost terminal)
2022-01-27 15:01:37 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 15:01:40 +0100vysn(~vysn@user/vysn) (Ping timeout: 250 seconds)
2022-01-27 15:03:11 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 15:03:18 +0100 <merijn> quickcheck can auto detect tests starting with prop_ I think?
2022-01-27 15:03:44 +0100Henson(~kvirc@107-179-133-201.cpe.teksavvy.com)
2022-01-27 15:03:46 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 15:04:51 +0100imalsogreg(~imalsogre@2601:147:300:f930::ee17)
2022-01-27 15:05:20 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 15:06:06 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 15:07:16 +0100 <tomsmeding> indeed
2022-01-27 15:07:41 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 15:07:49 +0100 <tomsmeding> using what I now see is, ahem, slightly hacky code
2022-01-27 15:07:56 +0100 <tomsmeding> https://hackage.haskell.org/package/QuickCheck-2.14.2/docs/src/Test.QuickCheck.All.html#allPropert…
2022-01-27 15:08:18 +0100kuribas(~user@ip-188-118-57-242.reverse.destiny.be)
2022-01-27 15:08:29 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 15:09:29 +0100imalsogreg(~imalsogre@2601:147:300:f930::ee17) (Ping timeout: 252 seconds)
2022-01-27 15:10:03 +0100imalsogreg(~imalsogre@c-73-172-114-3.hsd1.md.comcast.net)
2022-01-27 15:10:03 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 15:11:02 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 15:12:36 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 15:12:42 +0100fjmorazan(~quassel@user/fjmorazan) (Quit: fjmorazan)
2022-01-27 15:13:14 +0100fjmorazan(~quassel@user/fjmorazan)
2022-01-27 15:13:23 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 15:13:31 +0100andreabedini(~andreabed@8s8kj6nj5000h5zkmpxr.ip6.superloop.com) (Quit: WeeChat 3.3)
2022-01-27 15:14:57 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 15:15:11 +0100max22-(~maxime@2a01cb08833598002ebd2aed9b6751c0.ipv6.abo.wanadoo.fr)
2022-01-27 15:15:44 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 15:17:20 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 15:18:20 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 15:19:37 +0100max22-(~maxime@2a01cb08833598002ebd2aed9b6751c0.ipv6.abo.wanadoo.fr) (Ping timeout: 250 seconds)
2022-01-27 15:19:54 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 15:20:59 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 15:21:05 +0100RFV(~Thunderbi@49.red-88-12-220.dynamicip.rima-tde.net)
2022-01-27 15:21:36 +0100fef(~thedawn@user/thedawn)
2022-01-27 15:21:55 +0100RFV(~Thunderbi@49.red-88-12-220.dynamicip.rima-tde.net) (Client Quit)
2022-01-27 15:22:18 +0100Major_Biscuit(~MajorBisc@wlan-145-94-218-48.wlan.tudelft.nl) (Ping timeout: 260 seconds)
2022-01-27 15:22:32 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 15:23:34 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 15:25:09 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 15:26:13 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 15:26:34 +0100mncheckm(~mncheck@193.224.205.254) (Quit: Leaving)
2022-01-27 15:27:46 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 15:27:51 +0100justsomeguy(~justsomeg@user/justsomeguy) (Quit: WeeChat 3.3)
2022-01-27 15:28:50 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 15:30:25 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 15:31:19 +0100coot(~coot@213.134.190.95) (Quit: coot)
2022-01-27 15:31:24 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 15:31:52 +0100coot(~coot@213.134.190.95)
2022-01-27 15:32:59 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 15:34:12 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 15:35:45 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 15:36:01 +0100wroathe(~wroathe@206-55-188-8.fttp.usinternet.com)
2022-01-27 15:36:02 +0100wroathe(~wroathe@206-55-188-8.fttp.usinternet.com) (Changing host)
2022-01-27 15:36:02 +0100wroathe(~wroathe@user/wroathe)
2022-01-27 15:36:44 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 15:38:18 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 15:38:49 +0100doyougnu(~doyougnu@cpe-67-249-83-190.twcny.res.rr.com)
2022-01-27 15:39:13 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 15:40:26 +0100Henson(~kvirc@107-179-133-201.cpe.teksavvy.com) (Ping timeout: 256 seconds)
2022-01-27 15:40:47 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 15:41:47 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 15:43:20 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 15:44:28 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 15:45:50 +0100jkaye(~jkaye@2601:281:8300:7530:ca78:9af1:544b:8917)
2022-01-27 15:46:04 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 15:46:40 +0100Pickchea(~private@user/pickchea) (Ping timeout: 256 seconds)
2022-01-27 15:47:13 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 15:47:17 +0100Null_A(~null_a@2601:645:8700:2290:8935:4edf:b32:6553)
2022-01-27 15:47:34 +0100 <kuribas> hmm, any language which has list comprehension has monad syntax...
2022-01-27 15:47:49 +0100n3rdy1(~n3rdy1@2600:1700:4570:3480::41)
2022-01-27 15:48:30 +0100 <kuribas> So if someone claims monads aren't useful, you can point them to this fact.
2022-01-27 15:48:41 +0100imalsogreg(~imalsogre@c-73-172-114-3.hsd1.md.comcast.net) (Remote host closed the connection)
2022-01-27 15:48:47 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 15:49:18 +0100 <romesrf> kuribas: how is list comprehension is monad syntax?
2022-01-27 15:49:57 +0100 <geekosaur> @undo [ x + 5 | x <- xs ]
2022-01-27 15:49:57 +0100 <lambdabot> concatMap (\ x -> [x + 5]) xs
2022-01-27 15:50:06 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 15:50:25 +0100 <geekosaur> now remember that concatMap is =<< for lists
2022-01-27 15:50:28 +0100 <kuribas> romesrf: [(x, y) | x <- [1..3], y <- [4..6]] => do x <- [1..3]; y <- [4..6]; pure (x, y)
2022-01-27 15:50:31 +0100LiaoTao_(~LiaoTao@gateway/tor-sasl/liaotao)
2022-01-27 15:50:52 +0100 <kuribas> romesrf: in fact, you can turn list comprehensions into monads using a syntax extension.
2022-01-27 15:50:55 +0100 <kuribas> in ghc
2022-01-27 15:51:24 +0100 <kuribas> well, generalize the syntax more precisely...
2022-01-27 15:51:41 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 15:52:17 +0100 <dminuoso> kuribas: I believe that one of the primary problems with monads is the imprecise use of the word.
2022-01-27 15:52:30 +0100 <dminuoso> Like you just excercised
2022-01-27 15:52:45 +0100segfaultfizzbuzz(~rustisafu@2602:306:cd3c:9350:59e3:db49:aa0a:46e5)
2022-01-27 15:52:55 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 15:52:55 +0100SummerSonw(~The_viole@203.77.49.232)
2022-01-27 15:53:06 +0100LiaoTao(~LiaoTao@gateway/tor-sasl/liaotao) (Ping timeout: 276 seconds)
2022-01-27 15:53:33 +0100 <dminuoso> Monad in Haskell is not just useful not because it happens to match things we do, but because we can write generalize over it.
2022-01-27 15:53:46 +0100 <dminuoso> The power of "Monad" only happens precisely when you are able to write something akin to: f :: Monad m => ...
2022-01-27 15:53:52 +0100 <dminuoso> That is, something that is polymorphic over *any* such thinig.
2022-01-27 15:54:09 +0100 <dminuoso> Monoids are not useful because we can add numbers together, but because they give us a generalized tool.
2022-01-27 15:54:24 +0100 <romesrf> geekosaur: that's a great explanation :)
2022-01-27 15:54:29 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 15:54:39 +0100 <romesrf> or rather a great example
2022-01-27 15:54:53 +0100 <romesrf> that showcases it exactly =)
2022-01-27 15:55:32 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 15:55:35 +0100 <kuribas> dminuoso: sure. I just mean that people who claim they don't need monads, already use them.
2022-01-27 15:55:47 +0100 <dminuoso> "need monads", "use them"
2022-01-27 15:55:54 +0100geekosaurconsiders posting the sigfpe link again
2022-01-27 15:55:58 +0100 <dminuoso> This I think is terribly confusing.
2022-01-27 15:56:03 +0100 <geekosaur> "you could have invented monads"
2022-01-27 15:56:05 +0100 <romesrf> geekosaur: what is sigfpe?
2022-01-27 15:56:10 +0100 <dminuoso> A monad is not something you "have" or "use"
2022-01-27 15:56:14 +0100 <dminuoso> Or rather
2022-01-27 15:56:15 +0100shriekingnoise(~shrieking@201.231.16.156)
2022-01-27 15:56:23 +0100 <kuribas> romesrf: floating point exception.
2022-01-27 15:56:32 +0100 <geekosaur> http://blog.sigfpe.com/2006/08/you-could-have-invented-monads-and.html
2022-01-27 15:56:42 +0100 <romesrf> hahah
2022-01-27 15:56:48 +0100sweater(~sweater@206.81.18.26) (Quit: WeeChat 2.8)
2022-01-27 15:57:04 +0100sweater(~sweater@206.81.18.26)
2022-01-27 15:57:08 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 15:57:12 +0100sweater(~sweater@206.81.18.26) (Client Quit)
2022-01-27 15:57:21 +0100adanwan_(~adanwan@gateway/tor-sasl/adanwan)
2022-01-27 15:57:41 +0100imalsogreg(~imalsogre@2601:147:300:f930::ee17)
2022-01-27 15:58:03 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 15:58:18 +0100adanwan(~adanwan@gateway/tor-sasl/adanwan) (Ping timeout: 276 seconds)
2022-01-27 15:58:42 +0100soxen(~bob@pool-173-54-217-168.nwrknj.fios.verizon.net)
2022-01-27 15:59:23 +0100Null_A(~null_a@2601:645:8700:2290:8935:4edf:b32:6553) (Read error: Connection reset by peer)
2022-01-27 15:59:38 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 16:00:02 +0100 <romesrf> i was wondering what IRC client you use
2022-01-27 16:00:14 +0100zmt00(~zmt00@user/zmt00)
2022-01-27 16:00:22 +0100 <romesrf> i have to reconfigure weechat to make all these join/leave messages better
2022-01-27 16:00:33 +0100 <geekosaur> I use hexchat
2022-01-27 16:00:39 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 16:00:42 +0100 <geekosaur> but I choose to track all the joins/parts
2022-01-27 16:00:55 +0100coot(~coot@213.134.190.95) (Quit: coot)
2022-01-27 16:00:58 +0100 <geekosaur> I could turn them off but there are enough times when I need to know, so
2022-01-27 16:01:33 +0100 <geekosaur> (among other things, I'm a channel admin)
2022-01-27 16:02:03 +0100 <romesrf> oh! got it
2022-01-27 16:02:15 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 16:03:09 +0100WhateverRabbit(~rabbit@206.81.18.26) (Quit: WeeChat 2.8)
2022-01-27 16:03:13 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 16:03:40 +0100mon_aaraj(~MonAaraj@user/mon-aaraj/x-4416475) (Ping timeout: 268 seconds)
2022-01-27 16:04:01 +0100sweater(~sweater@206.81.18.26)
2022-01-27 16:04:04 +0100Null_A(~null_a@c-98-210-133-39.hsd1.ca.comcast.net)
2022-01-27 16:04:47 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 16:05:41 +0100coot(~coot@213.134.190.95)
2022-01-27 16:05:51 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 16:07:06 +0100polyphem(~rod@2a02:810d:840:8754:ab25:19d5:5fa5:69d5) (Ping timeout: 250 seconds)
2022-01-27 16:07:24 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 16:08:12 +0100soxen(~bob@pool-173-54-217-168.nwrknj.fios.verizon.net) (Ping timeout: 256 seconds)
2022-01-27 16:08:27 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 16:08:30 +0100 <dminuoso> I need some guidance. I have a powerdns binding library, and inside I expose a `data RRSet = RRSet { rrset_name :: T.Text, ... }`. Now the DNS standards require limited case-insensitivity (case folding on the ASCII-subset of bytes) on nameserver and recursor implementations do limited case-insensitivity.
2022-01-27 16:08:42 +0100 <dminuoso> Do I implement that same case insensitivity on the Eq instance of RRSet?
2022-01-27 16:08:55 +0100 <dminuoso> (Which is essentially just a data structure to read/write DNS records with)
2022-01-27 16:09:51 +0100 <merijn> dminuoso: There's a case-insensitivity newtype for text
2022-01-27 16:10:04 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 16:10:06 +0100 <dminuoso> merijn: Which would be incorrect, even.
2022-01-27 16:10:26 +0100 <dminuoso> I need a limited case insensitivity which is only insensitive on the code points in the ASCII subset
2022-01-27 16:10:32 +0100 <dminuoso> But not insensitive on the rest
2022-01-27 16:10:38 +0100mon_aaraj(~MonAaraj@user/mon-aaraj/x-4416475)
2022-01-27 16:11:07 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 16:12:41 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 16:13:42 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 16:14:49 +0100 <geekosaur> I'm confused. isn't the only way to get stuff outside the ASCII subset punycode?
2022-01-27 16:14:51 +0100waleee(~waleee@2001:9b0:21d:fc00:398f:b003:b90d:acf4)
2022-01-27 16:15:17 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 16:15:30 +0100raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) (Ping timeout: 260 seconds)
2022-01-27 16:15:43 +0100 <dminuoso> geekosaur: No, DNS names themselves can be arbitrary bytestrings with just some limitations on their length.
2022-01-27 16:16:14 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 16:16:49 +0100 <imalsogreg> dminuoso: It looks like the case-insensivite package implements the type of case insensitivity you want? https://hackage.haskell.org/package/case-insensitive-1.2.1.0/docs/src/Data.CaseInsensitive.Interna… So you could wrap `rrset_name` in the `CI` constructor if you want RRsets to compare case-insensitively.
2022-01-27 16:17:25 +0100dfg(dfg@user/dfg) (Quit: I hate quit messages.)
2022-01-27 16:17:26 +0100 <dminuoso> imalsogreg: Nope, definitely not correct.
2022-01-27 16:17:33 +0100shapr(~user@pool-100-36-247-68.washdc.fios.verizon.net) (Read error: Connection reset by peer)
2022-01-27 16:17:40 +0100dfg(dfg@dfg.rocks)
2022-01-27 16:17:40 +0100dfg(dfg@dfg.rocks) (Changing host)
2022-01-27 16:17:40 +0100dfg(dfg@user/dfg)
2022-01-27 16:17:42 +0100 <dminuoso> imalsogreg: That would at minimum also casefold latin supplement characters
2022-01-27 16:17:51 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 16:17:54 +0100Null_A(~null_a@c-98-210-133-39.hsd1.ca.comcast.net) (Remote host closed the connection)
2022-01-27 16:17:55 +0100 <dminuoso> Which would be non-conforming to DNS RFCs
2022-01-27 16:18:10 +0100 <dminuoso> I mean rolling this myself is not a big deal
2022-01-27 16:18:17 +0100 <dminuoso> Im merely wondering whether RRSet *should* receive that treatment
2022-01-27 16:18:55 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 16:19:12 +0100raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net)
2022-01-27 16:19:14 +0100wroathe(~wroathe@user/wroathe) (Ping timeout: 250 seconds)
2022-01-27 16:19:30 +0100Major_Biscuit(~MajorBisc@wlan-145-94-218-48.wlan.tudelft.nl)
2022-01-27 16:19:41 +0100shapr(~user@pool-100-36-247-68.washdc.fios.verizon.net)
2022-01-27 16:19:45 +0100Null_A(~null_a@2601:645:8700:2290:8935:4edf:b32:6553)
2022-01-27 16:20:30 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 16:20:32 +0100 <imalsogreg> dminuoso: Will you be writing `foo :: RSSet == bar :: RSSet` a lot - and would you want equality to "mean" equality according to the DNS spec?
2022-01-27 16:21:32 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 16:21:48 +0100raym(~raym@user/raym) (Ping timeout: 256 seconds)
2022-01-27 16:22:46 +0100 <dminuoso> geekosaur: The story behind punycode is a bit bizarre, in principle we don't actually need it. My best guess so far is that it exists because plenty software only accepts letter-hyphen-digit-undercore in domain names
2022-01-27 16:22:56 +0100 <dminuoso> say mail clients or servers
2022-01-27 16:23:05 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 16:24:17 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 16:25:52 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 16:26:46 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 16:27:20 +0100Sgeo(~Sgeo@user/sgeo)
2022-01-27 16:27:29 +0100wroathe(~wroathe@206-55-188-8.fttp.usinternet.com)
2022-01-27 16:27:30 +0100wroathe(~wroathe@206-55-188-8.fttp.usinternet.com) (Changing host)
2022-01-27 16:27:30 +0100wroathe(~wroathe@user/wroathe)
2022-01-27 16:27:55 +0100shailangsa(~shailangs@host86-185-98-37.range86-185.btcentralplus.com)
2022-01-27 16:28:21 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 16:28:22 +0100polyphem(~rod@2a02:810d:840:8754:2622:b61:ec32:bf43)
2022-01-27 16:29:21 +0100Null_A(~null_a@2601:645:8700:2290:8935:4edf:b32:6553) (Remote host closed the connection)
2022-01-27 16:29:24 +0100imalsogreg(~imalsogre@2601:147:300:f930::ee17) ()
2022-01-27 16:29:25 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 16:31:00 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 16:31:23 +0100Henson(~kvirc@107-179-133-201.cpe.teksavvy.com)
2022-01-27 16:31:48 +0100wombat875(~wombat875@pool-72-89-24-154.nycmny.fios.verizon.net) (Ping timeout: 250 seconds)
2022-01-27 16:31:59 +0100wroathe(~wroathe@user/wroathe) (Ping timeout: 250 seconds)
2022-01-27 16:32:09 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 16:32:39 +0100dsrt^(~dsrt@50.231.5.242)
2022-01-27 16:33:43 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 16:33:51 +0100wombat875(~wombat875@pool-72-89-24-154.nycmny.fios.verizon.net)
2022-01-27 16:34:48 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 16:34:57 +0100n3rdy1(~n3rdy1@2600:1700:4570:3480::41) (Ping timeout: 240 seconds)
2022-01-27 16:36:23 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 16:36:33 +0100sajith_sajith
2022-01-27 16:37:26 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 16:39:01 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 16:39:05 +0100mncheck(~mncheck@193.224.205.254)
2022-01-27 16:40:05 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 16:41:42 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 16:41:50 +0100romesrf(~romes@44.190.189.46.rev.vodafone.pt) (Quit: WeeChat 3.4)
2022-01-27 16:42:08 +0100romesrf(~romes@44.190.189.46.rev.vodafone.pt)
2022-01-27 16:42:23 +0100raym(~raym@user/raym)
2022-01-27 16:42:51 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 16:44:28 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 16:45:40 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 16:45:49 +0100myShoggoth(~myShoggot@97-120-67-120.ptld.qwest.net)
2022-01-27 16:47:15 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 16:47:58 +0100n3rdy1(~n3rdy1@2600:1700:4570:3480:1b88:50f:dae0:9293)
2022-01-27 16:48:36 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 16:49:10 +0100romesrf(~romes@44.190.189.46.rev.vodafone.pt) (Quit: WeeChat 3.4)
2022-01-27 16:49:27 +0100romesrf(~romes@44.190.189.46.rev.vodafone.pt)
2022-01-27 16:50:12 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 16:51:19 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 16:52:11 +0100jakalx(~jakalx@base.jakalx.net) ()
2022-01-27 16:52:24 +0100wombat875(~wombat875@pool-72-89-24-154.nycmny.fios.verizon.net) (Ping timeout: 256 seconds)
2022-01-27 16:52:54 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 16:53:54 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 16:54:07 +0100wombat875(~wombat875@pool-72-89-24-154.nycmny.fios.verizon.net)
2022-01-27 16:54:19 +0100alt-romes(~romes@44.190.189.46.rev.vodafone.pt)
2022-01-27 16:55:00 +0100Ocelot(~ocelot@50-78-208-189-static.hfc.comcastbusiness.net) (Remote host closed the connection)
2022-01-27 16:55:31 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 16:56:38 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 16:56:56 +0100romesrf(~romes@44.190.189.46.rev.vodafone.pt) (Ping timeout: 250 seconds)
2022-01-27 16:58:13 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be)
2022-01-27 16:59:13 +0100betelgeuse9(~betelgeus@94-225-47-8.access.telenet.be) (Read error: Connection reset by peer)
2022-01-27 16:59:42 +0100mbuf(~Shakthi@223.190.239.151) (Quit: Leaving)
2022-01-27 17:00:01 +0100jakalx(~jakalx@base.jakalx.net)
2022-01-27 17:04:10 +0100alt-romes(~romes@44.190.189.46.rev.vodafone.pt) (Quit: WeeChat 3.4)
2022-01-27 17:04:46 +0100cfricke(~cfricke@user/cfricke) (Quit: WeeChat 3.3)
2022-01-27 17:05:37 +0100mon_aaraj(~MonAaraj@user/mon-aaraj/x-4416475) (Ping timeout: 240 seconds)
2022-01-27 17:08:23 +0100raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) (Ping timeout: 250 seconds)
2022-01-27 17:10:30 +0100Codaraxis(~Codaraxis@user/codaraxis)
2022-01-27 17:10:32 +0100Gurkenglas(~Gurkengla@dslb-090-186-104-244.090.186.pools.vodafone-ip.de) (Ping timeout: 240 seconds)
2022-01-27 17:10:33 +0100raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net)
2022-01-27 17:11:30 +0100xff0x(~xff0x@2001:1a81:523c:5300:707e:bf72:dc84:30f7) (Ping timeout: 268 seconds)
2022-01-27 17:11:54 +0100szkl(uid110435@id-110435.uxbridge.irccloud.com)
2022-01-27 17:13:14 +0100nek0(~nek0@nek0.eu) (Quit: The Lounge - https://thelounge.chat)
2022-01-27 17:15:33 +0100yauhsien(~yauhsien@61-231-17-3.dynamic-ip.hinet.net)
2022-01-27 17:18:17 +0100mon_aaraj(~MonAaraj@user/mon-aaraj/x-4416475)
2022-01-27 17:18:50 +0100[itchyjunk](~itchyjunk@user/itchyjunk/x-7353470)
2022-01-27 17:19:04 +0100romesrf(~romes@44.190.189.46.rev.vodafone.pt)
2022-01-27 17:19:24 +0100kmein(~weechat@user/kmein) (Quit: ciao kakao)
2022-01-27 17:19:45 +0100kmein(~weechat@user/kmein)
2022-01-27 17:19:50 +0100yauhsien(~yauhsien@61-231-17-3.dynamic-ip.hinet.net) (Ping timeout: 252 seconds)
2022-01-27 17:19:57 +0100CHUD(~CHUD@host-80-41-89-108.as13285.net) (Ping timeout: 256 seconds)
2022-01-27 17:21:48 +0100kmein(~weechat@user/kmein) (Client Quit)
2022-01-27 17:22:07 +0100kmein(~weechat@user/kmein)
2022-01-27 17:22:40 +0100lortabac(~lortabac@2a01:e0a:541:b8f0:2912:7d04:4a3c:64d7) (Quit: WeeChat 2.8)
2022-01-27 17:24:19 +0100cosimone(~user@93-44-184-251.ip98.fastwebnet.it) (Remote host closed the connection)
2022-01-27 17:24:47 +0100mon_aaraj(~MonAaraj@user/mon-aaraj/x-4416475) (Ping timeout: 252 seconds)
2022-01-27 17:24:51 +0100nek0(~nek0@nek0.eu)
2022-01-27 17:24:58 +0100CHUD(~CHUD@host-80-41-89-108.as13285.net)
2022-01-27 17:25:14 +0100cosimone(~user@2001:b07:ae5:db26:c24a:d20:4d91:1e20)
2022-01-27 17:25:39 +0100jgeerds(~jgeerds@55d4a547.access.ecotel.net)
2022-01-27 17:25:41 +0100intersect(~ivoolivei@a109-50-190-38.cpe.netcabo.pt)
2022-01-27 17:26:20 +0100geekosaur(~geekosaur@xmonad/geekosaur) (Remote host closed the connection)
2022-01-27 17:26:35 +0100mon_aaraj(~MonAaraj@user/mon-aaraj/x-4416475)
2022-01-27 17:26:42 +0100max22-(~maxime@2a01cb0883359800f8f9901a67fcc4eb.ipv6.abo.wanadoo.fr)
2022-01-27 17:27:15 +0100eggplantade(~Eggplanta@2600:1700:bef1:5e10:41be:eda7:26bd:771e)
2022-01-27 17:27:38 +0100ptrcmd(~ptrcmd@user/ptrcmd) (Remote host closed the connection)
2022-01-27 17:28:02 +0100geekosaur(~geekosaur@xmonad/geekosaur)
2022-01-27 17:28:17 +0100intersec1(~ivoolivei@a109-50-190-38.cpe.netcabo.pt) (Ping timeout: 240 seconds)
2022-01-27 17:29:00 +0100kanin(~kanin@2409:8a14:10e7:52d0:e868:e5f3:fdc5:9fd) (Ping timeout: 250 seconds)
2022-01-27 17:29:36 +0100CHUD(~CHUD@host-80-41-89-108.as13285.net) (Ping timeout: 256 seconds)
2022-01-27 17:30:45 +0100little_mac(~little_ma@2601:410:4300:3ce0:4184:bb26:81f2:501e)
2022-01-27 17:33:29 +0100xff0x(~xff0x@2001:1a81:523c:5300:707e:bf72:dc84:30f7)
2022-01-27 17:34:39 +0100 <segfaultfizzbuzz> this question is well beyond what i understand of programming (probably)... but is threading fairly equivalent to labeling of type linearity?
2022-01-27 17:35:37 +0100 <romesrf> what is 'threading'?
2022-01-27 17:35:42 +0100 <segfaultfizzbuzz> meaning, if i had a program with linear types, would the compiler be able to infer how to multithread the application and how to divide work amongst the threads
2022-01-27 17:35:56 +0100doyougnu(~doyougnu@cpe-67-249-83-190.twcny.res.rr.com) (Ping timeout: 250 seconds)
2022-01-27 17:36:07 +0100sha296(~shakil@2409:4060:2e16:5922:8869:e019:69d0:c4b8)
2022-01-27 17:36:21 +0100 <segfaultfizzbuzz> this program would not explicitly create or destroy threads, the compiler or runtime would handle all of that
2022-01-27 17:36:46 +0100 <romesrf> at the moment, linear types are a construct purely on the type system, there are no automatic compiler optimizations - not meaning there couldn't be
2022-01-27 17:36:58 +0100 <segfaultfizzbuzz> my question is theoretical, not practical
2022-01-27 17:38:07 +0100 <romesrf> (just linking to what i said above: https://gitlab.haskell.org/ghc/ghc/-/wikis/linear-types)
2022-01-27 17:38:32 +0100mon_aaraj(~MonAaraj@user/mon-aaraj/x-4416475) (Ping timeout: 240 seconds)
2022-01-27 17:38:34 +0100 <merijn> segfaultfizzbuzz: Realistically, auto-parallelisation is still a pipe dream
2022-01-27 17:38:44 +0100 <merijn> Even in languages where the compiler has the knowledge to do it
2022-01-27 17:39:04 +0100 <merijn> Most projects attempting it turn out to perform fairly badly, compared to hand done stuff
2022-01-27 17:39:15 +0100 <segfaultfizzbuzz> my question is slightly more practical than that, i think--if i am threading things, what am i doing beyond annotating linearity
2022-01-27 17:39:27 +0100 <segfaultfizzbuzz> i suppose there is some kind of task chunking/granularization annotation
2022-01-27 17:39:52 +0100 <segfaultfizzbuzz> merijn: sounds like a great research topic, then ;-)
2022-01-27 17:40:09 +0100 <romesrf> ^^ahaha
2022-01-27 17:40:10 +0100 <segfaultfizzbuzz> unless you think people will defeat computers at go ;-)
2022-01-27 17:40:54 +0100mon_aaraj(~MonAaraj@user/mon-aaraj/x-4416475)
2022-01-27 17:43:09 +0100 <romesrf> segfaultfizzbuzz: so i'm giving what you said some thought. first I would put things on different terms:
2022-01-27 17:43:09 +0100dyeplexer(~dyeplexer@user/dyeplexer)
2022-01-27 17:43:37 +0100 <geekosaur> it's been a great research topic for a couple decades now, I think
2022-01-27 17:44:20 +0100 <romesrf> is threading "fairly equivalent" to lableing linearity: I would think in terms of can we create threaded programs based on linear types
2022-01-27 17:44:46 +0100 <romesrf> because one thing is a type level concept, and the other is a well... "hardware" level concept
2022-01-27 17:44:49 +0100 <segfaultfizzbuzz> because it seems like a thread is an annotation of like locality and flow of data read/write ...?
2022-01-27 17:44:51 +0100 <romesrf> geekosaur: linear types?
2022-01-27 17:44:58 +0100 <geekosaur> autothreading
2022-01-27 17:45:01 +0100 <romesrf> i see
2022-01-27 17:45:07 +0100sha296(~shakil@2409:4060:2e16:5922:8869:e019:69d0:c4b8) (Quit: Leaving)
2022-01-27 17:45:42 +0100 <romesrf> i wrote some research on linear types so i thought you meant that :P
2022-01-27 17:45:54 +0100 <romesrf> autothreading does sound cool
2022-01-27 17:46:04 +0100kmein_(~weechat@user/kmein)
2022-01-27 17:46:51 +0100 <romesrf> but stuff like the parallell library with the `using` parallel strategy isn't some sort of autothreading? (even though it's (i assume) written specifically in the library?)
2022-01-27 17:47:01 +0100 <romesrf> manually*
2022-01-27 17:47:38 +0100 <geekosaur> you still need manual annotations with it, plus you need to know which sparks will compute and which will fizzle
2022-01-27 17:47:46 +0100 <geekosaur> which generally requires experimentation
2022-01-27 17:49:32 +0100jgeerds(~jgeerds@55d4a547.access.ecotel.net) (Ping timeout: 240 seconds)
2022-01-27 17:49:32 +0100kmein(~weechat@user/kmein) (Ping timeout: 252 seconds)
2022-01-27 17:50:28 +0100 <romesrf> segfaultfizzbuzz: a thread as an annotation of locality and flow of data read/write--could you elaborate?
2022-01-27 17:50:40 +0100 <romesrf> i'm trying to create some thoughts on it
2022-01-27 17:50:57 +0100flipchan(~filip@user/flipchan) (Ping timeout: 240 seconds)
2022-01-27 17:51:26 +0100SummerSonw(~The_viole@203.77.49.232) (Read error: Connection reset by peer)
2022-01-27 17:52:05 +0100 <geekosaur> seems to me that linearity tells you which parts *can't* thread, but gives you no help in the hard part which is which parts *can* productively be threaded
2022-01-27 17:52:19 +0100 <geekosaur> "productively" being the key word
2022-01-27 17:54:43 +0100chexum(~quassel@gateway/tor-sasl/chexum)
2022-01-27 17:55:15 +0100wroathe(~wroathe@206-55-188-8.fttp.usinternet.com)
2022-01-27 17:55:15 +0100wroathe(~wroathe@206-55-188-8.fttp.usinternet.com) (Changing host)
2022-01-27 17:55:15 +0100wroathe(~wroathe@user/wroathe)
2022-01-27 17:55:24 +0100kanin(~kanin@2409:8a14:10e7:fa80:94e5:9c21:2378:713)
2022-01-27 17:55:26 +0100Null_A(~null_a@2601:645:8700:2290:8935:4edf:b32:6553)
2022-01-27 17:55:26 +0100wombat875(~wombat875@pool-72-89-24-154.nycmny.fios.verizon.net) (Ping timeout: 250 seconds)
2022-01-27 17:55:26 +0100kanin(~kanin@2409:8a14:10e7:fa80:94e5:9c21:2378:713) (Remote host closed the connection)
2022-01-27 17:57:25 +0100wombat875(~wombat875@pool-72-89-24-154.nycmny.fios.verizon.net)
2022-01-27 17:59:39 +0100Erutuon(~Erutuon@user/erutuon)
2022-01-27 18:00:01 +0100eggplantade(~Eggplanta@2600:1700:bef1:5e10:41be:eda7:26bd:771e) (Remote host closed the connection)
2022-01-27 18:02:57 +0100ph88(~ph88@95.90.247.31) (Ping timeout: 240 seconds)
2022-01-27 18:03:28 +0100CHUD(~CHUD@edu7879.kent.ac.uk)
2022-01-27 18:05:06 +0100Null_A(~null_a@2601:645:8700:2290:8935:4edf:b32:6553) (Remote host closed the connection)
2022-01-27 18:07:31 +0100Jing(~hedgehog@240e:390:7c53:a7e1:54bc:3778:6db0:347c) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2022-01-27 18:07:48 +0100pretty_dumm_guy(trottel@gateway/vpn/protonvpn/prettydummguy/x-88029655)
2022-01-27 18:09:06 +0100jao(~jao@static-68-235-44-73.cust.tzulo.com)
2022-01-27 18:09:22 +0100tzh(~tzh@c-24-21-73-154.hsd1.wa.comcast.net)
2022-01-27 18:09:26 +0100lbseale(~ep1ctetus@user/ep1ctetus)
2022-01-27 18:12:52 +0100haskellberryfinn(~nut@roc37-h01-176-170-197-243.dsl.sta.abo.bbox.fr) (Ping timeout: 256 seconds)
2022-01-27 18:13:57 +0100mon_aaraj(~MonAaraj@user/mon-aaraj/x-4416475) (Ping timeout: 240 seconds)
2022-01-27 18:15:44 +0100 <monochrom> I thought programming since day one was already annotation of locality and sequentiality (sometimes "linear" just means "sequential").
2022-01-27 18:16:19 +0100mon_aaraj(~MonAaraj@user/mon-aaraj/x-4416475)
2022-01-27 18:16:52 +0100 <segfaultfizzbuzz> romesf: i mean, if we know how information flows through a program then you know where to localize things right?
2022-01-27 18:16:55 +0100 <monochrom> Talking about threads (and all parallelism and concurrency constructs) instead acknowledges that reality is more sophisticated than sequential PDP-11.
2022-01-27 18:17:44 +0100 <segfaultfizzbuzz> monochrom: that's deep, programming is annotation of locality and sequentiality.
2022-01-27 18:18:08 +0100 <monochrom> Alternatively, it's tautological.
2022-01-27 18:18:30 +0100ptrcmd(~ptrcmd@user/ptrcmd)
2022-01-27 18:18:32 +0100d0ku(~d0ku@178.43.12.98.ipv4.supernova.orange.pl) (Ping timeout: 256 seconds)
2022-01-27 18:18:50 +0100Major_Biscuit(~MajorBisc@wlan-145-94-218-48.wlan.tudelft.nl) (Ping timeout: 250 seconds)
2022-01-27 18:19:01 +0100 <geekosaur> sometimes the tautologies sound really deep :)
2022-01-27 18:19:40 +0100wroathe(~wroathe@user/wroathe) (Ping timeout: 256 seconds)
2022-01-27 18:20:48 +0100 <monochrom> I might have to credit my observation to Hoare actually.
2022-01-27 18:21:34 +0100 <monochrom> When Hoare worked on parallelism and concurrency, he named his system "communicating sequential processes" (CSP).
2022-01-27 18:22:14 +0100 <monochrom> The idea is that maybe thinking about and using unlimited unstructured concurrency is too hard.
2022-01-27 18:22:22 +0100wroathe(~wroathe@206-55-188-8.fttp.usinternet.com)
2022-01-27 18:22:22 +0100wroathe(~wroathe@206-55-188-8.fttp.usinternet.com) (Changing host)
2022-01-27 18:22:22 +0100wroathe(~wroathe@user/wroathe)
2022-01-27 18:23:07 +0100 <geekosaur> that fails to surprise me
2022-01-27 18:23:40 +0100thomas_(~thomas@2a02:a03f:666e:c500:92eb:d341:15bc:3f3d)
2022-01-27 18:23:44 +0100 <geekosaur> humans have far too little working memory for such tasks
2022-01-27 18:23:52 +0100 <monochrom> So how about limiting to this structure: you have many sequential programs. In each program you can still think sequentially, as in the 1960s. You just now acknowledge that there are other sequential programs too, and that once in a while they have to talk or synchronize.
2022-01-27 18:24:09 +0100 <geekosaur> (I run into limits on mine regularly — and from observation I think I have a bit more working memory than usual)
2022-01-27 18:24:44 +0100 <monochrom> The biggest irony and wisdom is that the name of a concurrent system contains the word "sequential" and no mention of "parallel" or "concurrent" or "side by side" or whatever.
2022-01-27 18:25:10 +0100 <geekosaur> "communicating" does imply it though
2022-01-27 18:25:17 +0100 <monochrom> Yes, but it's very indirect.
2022-01-27 18:25:25 +0100 <geekosaur> although I guess it could mean sequential coprocesses
2022-01-27 18:25:35 +0100 <monochrom> You show this name to an English major, they will never guess.
2022-01-27 18:27:32 +0100wroathe(~wroathe@user/wroathe) (Ping timeout: 240 seconds)
2022-01-27 18:27:48 +0100wyrd(~wyrd@gateway/tor-sasl/wyrd) (Ping timeout: 276 seconds)
2022-01-27 18:28:45 +0100justsomeguy(~justsomeg@user/justsomeguy)
2022-01-27 18:28:47 +0100thevishy(~Nishant@2405:201:f005:c007:4ce:a391:7558:6be8) (Quit: Leaving)
2022-01-27 18:29:32 +0100wyrd(~wyrd@gateway/tor-sasl/wyrd)
2022-01-27 18:29:48 +0100 <monochrom> It is also very appealing algebraically. You now have two monoids. The old monoid (since day one) of sequential composition. The new monoid of parallel composition.
2022-01-27 18:31:19 +0100max22-(~maxime@2a01cb0883359800f8f9901a67fcc4eb.ipv6.abo.wanadoo.fr) (Remote host closed the connection)
2022-01-27 18:32:13 +0100max22-(~maxime@lfbn-ren-1-1026-62.w92-139.abo.wanadoo.fr)
2022-01-27 18:32:32 +0100kuribas(~user@ip-188-118-57-242.reverse.destiny.be) (Remote host closed the connection)
2022-01-27 18:32:49 +0100 <segfaultfizzbuzz> why is it "too hard" to have unlimited unstructured concurrency?
2022-01-27 18:33:04 +0100 <EvanR> try to interpret quantum mechanics
2022-01-27 18:33:11 +0100 <EvanR> just kidding, don't try
2022-01-27 18:33:14 +0100 <segfaultfizzbuzz> in other words why not make the minimum assertions about what you need to do and let the computer/compiler figure out how to do everything
2022-01-27 18:33:51 +0100fef(~thedawn@user/thedawn) (Remote host closed the connection)
2022-01-27 18:34:39 +0100 <EvanR> (actually a model of the real world would be more structured and limited than unlimited unstructed concurrency)
2022-01-27 18:34:40 +0100 <segfaultfizzbuzz> i can barely do one floating point calculation. in fact, i'm not sure i could do a single floating point calculation without error in less than like an hour
2022-01-27 18:35:13 +0100 <segfaultfizzbuzz> we are starting to talk about machines which can do petaflops
2022-01-27 18:35:17 +0100Inst(~delicacie@2601:6c4:4080:3f80:9d39:f8e3:aac8:5b1b) (Ping timeout: 240 seconds)
2022-01-27 18:35:18 +0100myShoggoth(~myShoggot@97-120-67-120.ptld.qwest.net) (Ping timeout: 250 seconds)
2022-01-27 18:35:31 +0100 <EvanR> yeah they really doubled down on the things they can do fast
2022-01-27 18:35:59 +0100 <EvanR> it's unfortunate that's floats xD
2022-01-27 18:36:09 +0100 <segfaultfizzbuzz> haha okay, then int64 multiplication if you like
2022-01-27 18:37:32 +0100 <EvanR> complexity theory is all about what you could hope to get done doing some simple task over and over as fast as you can
2022-01-27 18:37:51 +0100RFV(~Thunderbi@49.red-88-12-220.dynamicip.rima-tde.net)
2022-01-27 18:38:20 +0100ph88(~ph88@2a02:8109:9e00:71d0:211a:2c49:de73:b7e4)
2022-01-27 18:38:25 +0100 <segfaultfizzbuzz> anyway sorry to distract: so it is true then that threads are locality and sequentiality annotations (and that's either it, or pretty much it)?
2022-01-27 18:38:30 +0100zeenk(~zeenk@2a02:2f04:a208:c500:649e:b5e2:d15c:7960) (Quit: Konversation terminated!)
2022-01-27 18:38:38 +0100 <EvanR> if the idea is to have the computer do some exponentially complex task it doesn't matter how fast you can multiply
2022-01-27 18:38:58 +0100 <segfaultfizzbuzz> i mostly don't like complexity theory, it is obsessed with perfectly correct results
2022-01-27 18:39:11 +0100 <segfaultfizzbuzz> and doesn't incorporate the realities of distributions and knowledge about distributions
2022-01-27 18:39:33 +0100 <segfaultfizzbuzz> sometimes perfectly correct results are necessary but frequently they are not in order to perform some kind of reasoning
2022-01-27 18:39:35 +0100ph88(~ph88@2a02:8109:9e00:71d0:211a:2c49:de73:b7e4) (Client Quit)
2022-01-27 18:39:59 +0100 <segfaultfizzbuzz> i would say more often than not perfect reasoning is unnecessary. that's probably why our minds reason imperfectly
2022-01-27 18:40:08 +0100 <EvanR> targeted controlled incorrectness? xD like interval analysis or something
2022-01-27 18:40:42 +0100 <segfaultfizzbuzz> probably the reverse, correctness annotation or something
2022-01-27 18:41:56 +0100ph88(~ph88@2a02:8109:9e00:71d0:f12b:1b26:c11c:e722)
2022-01-27 18:44:40 +0100fef(~thedawn@user/thedawn)
2022-01-27 18:46:21 +0100chele(~chele@user/chele) (Remote host closed the connection)
2022-01-27 18:47:44 +0100RFV(~Thunderbi@49.red-88-12-220.dynamicip.rima-tde.net) (Quit: RFV)
2022-01-27 18:50:38 +0100Akiva(~Akiva@user/Akiva)
2022-01-27 18:51:49 +0100justsomeguy(~justsomeg@user/justsomeguy) (Quit: WeeChat 3.4)
2022-01-27 18:53:32 +0100pottsy(~pottsy@129.227.183.244) (Ping timeout: 250 seconds)
2022-01-27 18:54:18 +0100pottsy(~pottsy@129.227.183.244)
2022-01-27 18:54:51 +0100eggplantade(~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net)
2022-01-27 18:58:28 +0100Tuplanolla(~Tuplanoll@91-159-68-166.elisa-laajakaista.fi)
2022-01-27 18:58:57 +0100thomas_(~thomas@2a02:a03f:666e:c500:92eb:d341:15bc:3f3d) (Ping timeout: 240 seconds)
2022-01-27 19:00:12 +0100geekosaur(~geekosaur@xmonad/geekosaur) (Remote host closed the connection)
2022-01-27 19:02:07 +0100geekosaur(~geekosaur@xmonad/geekosaur)
2022-01-27 19:03:06 +0100fef(~thedawn@user/thedawn) (Remote host closed the connection)
2022-01-27 19:04:40 +0100myShoggoth(~myShoggot@97-120-67-120.ptld.qwest.net)
2022-01-27 19:05:05 +0100dsrt^(~dsrt@50.231.5.242) (Remote host closed the connection)
2022-01-27 19:05:22 +0100wroathe(~wroathe@206-55-188-8.fttp.usinternet.com)
2022-01-27 19:05:22 +0100wroathe(~wroathe@206-55-188-8.fttp.usinternet.com) (Changing host)
2022-01-27 19:05:22 +0100wroathe(~wroathe@user/wroathe)
2022-01-27 19:06:39 +0100WhateverRabbit(~rabbit@206.81.18.26)
2022-01-27 19:07:04 +0100CHUD(~CHUD@edu7879.kent.ac.uk) (Ping timeout: 256 seconds)
2022-01-27 19:07:23 +0100eggplantade(~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Remote host closed the connection)
2022-01-27 19:08:28 +0100intersect(~ivoolivei@a109-50-190-38.cpe.netcabo.pt) (Quit: Lost terminal)
2022-01-27 19:09:57 +0100lbseale(~ep1ctetus@user/ep1ctetus) (Ping timeout: 240 seconds)
2022-01-27 19:10:31 +0100wroathe(~wroathe@user/wroathe) (Ping timeout: 268 seconds)
2022-01-27 19:12:05 +0100thomas_(~thomas@2a02:a03f:666e:c500:92eb:d341:15bc:3f3d)
2022-01-27 19:12:06 +0100haskellberryfinn(~nut@roc37-h01-176-170-197-243.dsl.sta.abo.bbox.fr)
2022-01-27 19:12:24 +0100ravella(~ravella@user/ryanavella)
2022-01-27 19:13:26 +0100Akiva(~Akiva@user/Akiva) (Ping timeout: 250 seconds)
2022-01-27 19:13:39 +0100thomas_(~thomas@2a02:a03f:666e:c500:92eb:d341:15bc:3f3d) (Client Quit)
2022-01-27 19:15:30 +0100[_](~itchyjunk@user/itchyjunk/x-7353470)
2022-01-27 19:15:40 +0100[_](~itchyjunk@user/itchyjunk/x-7353470) (Remote host closed the connection)
2022-01-27 19:15:53 +0100haask(~askham@user/haask)
2022-01-27 19:16:35 +0100Gurkenglas(~Gurkengla@dslb-090-186-104-244.090.186.pools.vodafone-ip.de)
2022-01-27 19:16:54 +0100dyeplexer(~dyeplexer@user/dyeplexer) (Ping timeout: 250 seconds)
2022-01-27 19:20:59 +0100alp(~alp@user/alp) (Ping timeout: 250 seconds)
2022-01-27 19:23:29 +0100Null_A(~null_a@2601:645:8700:2290:8935:4edf:b32:6553)
2022-01-27 19:28:09 +0100CHUD(~CHUD@host-80-41-89-108.as13285.net)
2022-01-27 19:28:10 +0100Null_A(~null_a@2601:645:8700:2290:8935:4edf:b32:6553) (Ping timeout: 250 seconds)
2022-01-27 19:28:48 +0100merijn(~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl) (Ping timeout: 256 seconds)
2022-01-27 19:28:52 +0100eggplantade(~Eggplanta@2600:1700:bef1:5e10:41be:eda7:26bd:771e)
2022-01-27 19:32:34 +0100CHUD(~CHUD@host-80-41-89-108.as13285.net) (Ping timeout: 256 seconds)
2022-01-27 19:32:35 +0100burnsidesLlama(~burnsides@dhcp168-030.wadham.ox.ac.uk)
2022-01-27 19:33:04 +0100dyeplexer(~dyeplexer@user/dyeplexer)
2022-01-27 19:34:57 +0100dyeplexer(~dyeplexer@user/dyeplexer) (Remote host closed the connection)
2022-01-27 19:39:53 +0100cosimone(~user@2001:b07:ae5:db26:c24a:d20:4d91:1e20) (Remote host closed the connection)
2022-01-27 19:41:43 +0100econo(uid147250@user/econo)
2022-01-27 19:42:40 +0100cosimone(~user@2001:b07:ae5:db26:c24a:d20:4d91:1e20)
2022-01-27 19:43:07 +0100ProfSimm(~ProfSimm@176-12-60-137.pon.spectrumnet.bg)
2022-01-27 19:46:05 +0100haask(~askham@user/haask) (Remote host closed the connection)
2022-01-27 19:46:31 +0100doyougnu(~doyougnu@cpe-67-249-83-190.twcny.res.rr.com)
2022-01-27 19:48:52 +0100Null_A(~null_a@2601:645:8700:2290:8935:4edf:b32:6553)
2022-01-27 19:51:08 +0100lionhairdino(~jacoo@121.131.39.82) (Ping timeout: 250 seconds)
2022-01-27 19:51:20 +0100mason0(~bc8147f2@cerf.good1.com) (Quit: CGI:IRC (Session timeout))
2022-01-27 19:51:42 +0100coot(~coot@213.134.190.95) (Quit: coot)
2022-01-27 19:52:08 +0100coot(~coot@213.134.190.95)
2022-01-27 19:52:51 +0100neceve(~quassel@2.26.93.228)
2022-01-27 19:52:52 +0100coot(~coot@213.134.190.95) (Read error: Connection reset by peer)
2022-01-27 19:53:06 +0100coot(~coot@213.134.190.95)
2022-01-27 19:55:03 +0100alp(~alp@user/alp)
2022-01-27 19:59:46 +0100Akiva(~Akiva@user/Akiva)
2022-01-27 20:04:00 +0100jpds(~jpds@gateway/tor-sasl/jpds) (Ping timeout: 276 seconds)
2022-01-27 20:04:32 +0100Null_A(~null_a@2601:645:8700:2290:8935:4edf:b32:6553) (Remote host closed the connection)
2022-01-27 20:05:50 +0100jpds(~jpds@gateway/tor-sasl/jpds)
2022-01-27 20:07:58 +0100whatsupdoc(uid509081@id-509081.hampstead.irccloud.com)
2022-01-27 20:08:14 +0100alp(~alp@user/alp) (Read error: Connection reset by peer)
2022-01-27 20:08:34 +0100alp(~alp@user/alp)
2022-01-27 20:09:55 +0100jkaye(~jkaye@2601:281:8300:7530:ca78:9af1:544b:8917) (Quit: Leaving)
2022-01-27 20:21:13 +0100dsrt^(~dsrt@50.231.5.242)
2022-01-27 20:22:47 +0100vicfred(~vicfred@user/vicfred)
2022-01-27 20:26:37 +0100doyougnu(~doyougnu@cpe-67-249-83-190.twcny.res.rr.com) (Ping timeout: 240 seconds)
2022-01-27 20:31:55 +0100notzmv(~zmv@user/notzmv) (Ping timeout: 268 seconds)
2022-01-27 20:38:48 +0100dsrt^(~dsrt@50.231.5.242) (Ping timeout: 250 seconds)
2022-01-27 20:39:18 +0100dsrt^(~dsrt@50.231.5.242)
2022-01-27 20:40:16 +0100eggplantade(~Eggplanta@2600:1700:bef1:5e10:41be:eda7:26bd:771e) (Remote host closed the connection)
2022-01-27 20:40:25 +0100briandaed(~root@185.234.208.208.r.toneticgroup.pl)
2022-01-27 20:43:04 +0100ymirhotfoot(~ymirhotfo@user/ymirhotfoot)
2022-01-27 20:44:35 +0100ProfSimm(~ProfSimm@176-12-60-137.pon.spectrumnet.bg) (Remote host closed the connection)
2022-01-27 20:44:56 +0100ProfSimm(~ProfSimm@176-12-60-137.pon.spectrumnet.bg)
2022-01-27 20:47:17 +0100mon_aaraj(~MonAaraj@user/mon-aaraj/x-4416475) (Ping timeout: 240 seconds)
2022-01-27 20:49:10 +0100ProfSimm(~ProfSimm@176-12-60-137.pon.spectrumnet.bg) (Remote host closed the connection)
2022-01-27 20:49:30 +0100ProfSimm(~ProfSimm@176-12-60-137.pon.spectrumnet.bg)
2022-01-27 20:49:39 +0100mon_aaraj(~MonAaraj@user/mon-aaraj/x-4416475)
2022-01-27 20:52:37 +0100raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) (Ping timeout: 240 seconds)
2022-01-27 20:54:08 +0100neurocyte0917090(~neurocyte@IP-195080053136.dynamic.medianet-world.de)
2022-01-27 20:54:08 +0100neurocyte0917090(~neurocyte@IP-195080053136.dynamic.medianet-world.de) (Changing host)
2022-01-27 20:54:08 +0100neurocyte0917090(~neurocyte@user/neurocyte)
2022-01-27 20:54:10 +0100ProfSimm(~ProfSimm@176-12-60-137.pon.spectrumnet.bg) (Ping timeout: 256 seconds)
2022-01-27 20:54:54 +0100raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net)
2022-01-27 21:02:19 +0100ymirhotfoot(~ymirhotfo@user/ymirhotfoot) ()
2022-01-27 21:02:35 +0100MoC(~moc@user/moc)
2022-01-27 21:02:40 +0100haskellb1(~nut@roc37-h01-176-170-197-243.dsl.sta.abo.bbox.fr)
2022-01-27 21:04:46 +0100ProfSimm(~ProfSimm@176-12-60-137.pon.spectrumnet.bg)
2022-01-27 21:04:57 +0100juhp(~juhp@128.106.188.82) (Ping timeout: 240 seconds)
2022-01-27 21:05:51 +0100leibniz(~leibniz@cpc101088-sgyl37-2-0-cust22.18-2.cable.virginm.net)
2022-01-27 21:07:19 +0100juhp(~juhp@128.106.188.82)
2022-01-27 21:09:28 +0100ProfSimm(~ProfSimm@176-12-60-137.pon.spectrumnet.bg) (Ping timeout: 256 seconds)
2022-01-27 21:13:41 +0100coot(~coot@213.134.190.95) (Quit: coot)
2022-01-27 21:14:10 +0100coot(~coot@213.134.190.95)
2022-01-27 21:16:31 +0100dextaa_(~dextaa@217.61.225.120)
2022-01-27 21:17:26 +0100myShoggoth(~myShoggot@97-120-67-120.ptld.qwest.net) (Ping timeout: 260 seconds)
2022-01-27 21:18:37 +0100coot(~coot@213.134.190.95) (Ping timeout: 240 seconds)
2022-01-27 21:18:57 +0100Null_A(~null_a@2601:645:8700:2290:8935:4edf:b32:6553)
2022-01-27 21:21:36 +0100mon_aaraj(~MonAaraj@user/mon-aaraj/x-4416475) (Quit: WeeChat 3.4)
2022-01-27 21:22:20 +0100kjak(~kjak@pool-108-45-56-21.washdc.fios.verizon.net)
2022-01-27 21:28:32 +0100Null_A(~null_a@2601:645:8700:2290:8935:4edf:b32:6553) (Remote host closed the connection)
2022-01-27 21:28:42 +0100wombat875(~wombat875@pool-72-89-24-154.nycmny.fios.verizon.net) (Quit: WeeChat 2.2-dev)
2022-01-27 21:32:50 +0100eggplantade(~Eggplanta@2600:1700:bef1:5e10:41be:eda7:26bd:771e)
2022-01-27 21:32:52 +0100mon_aaraj(~MonAaraj@user/mon-aaraj/x-4416475)
2022-01-27 21:32:54 +0100leibniz(~leibniz@cpc101088-sgyl37-2-0-cust22.18-2.cable.virginm.net) (Quit: Connection closed)
2022-01-27 21:33:21 +0100mbomba(~mbomba@bras-base-toroon2719w-grc-37-142-114-121-181.dsl.bell.ca)
2022-01-27 21:33:58 +0100vysn(~vysn@user/vysn)
2022-01-27 21:34:38 +0100jgeerds(~jgeerds@55d4a547.access.ecotel.net)
2022-01-27 21:35:04 +0100mbomba(~mbomba@bras-base-toroon2719w-grc-37-142-114-121-181.dsl.bell.ca) (Client Quit)
2022-01-27 21:43:42 +0100arjun(~arjun@user/arjun)
2022-01-27 21:44:41 +0100alp(~alp@user/alp) (Ping timeout: 268 seconds)
2022-01-27 21:47:18 +0100zer0bitz(~zer0bitz@2001:2003:f444:a000:a9ef:8cb1:3f34:9694) (Read error: Connection reset by peer)
2022-01-27 21:47:21 +0100nunggu(~q@user/nunggu) (Ping timeout: 276 seconds)
2022-01-27 21:48:14 +0100FroskyArr(~froskyarr@120.239.9.162) (Quit: Leaving)
2022-01-27 21:48:55 +0100nunggu(~q@user/nunggu)
2022-01-27 21:49:56 +0100Midjak(~Midjak@may53-1-78-226-116-92.fbx.proxad.net)
2022-01-27 21:53:12 +0100coot(~coot@213.134.190.95)
2022-01-27 21:54:11 +0100haskellb1(~nut@roc37-h01-176-170-197-243.dsl.sta.abo.bbox.fr) (Read error: Connection reset by peer)
2022-01-27 21:54:43 +0100 <maerwald> why does '-Wno-endif-labels' not work?
2022-01-27 21:55:58 +0100 <geekosaur> ?
2022-01-27 21:56:12 +0100myShoggoth(~myShoggot@97-120-67-120.ptld.qwest.net)
2022-01-27 21:56:17 +0100 <maerwald> maybe that's the preprocessor
2022-01-27 21:56:48 +0100bontaq(~user@ool-45779fe5.dyn.optonline.net) (Ping timeout: 250 seconds)
2022-01-27 21:57:00 +0100notzmv(~zmv@user/notzmv)
2022-01-27 21:57:05 +0100myShoggoth(~myShoggot@97-120-67-120.ptld.qwest.net) (Client Quit)
2022-01-27 22:00:40 +0100 <geekosaur> you'd probably have to use an option to pass it to cpp. maybe -WP,-Wno-endif-labels but I can't find the list of those options right off the top of my head
2022-01-27 22:01:22 +0100 <geekosaur> worry it's -optP -Wno-endif-labels
2022-01-27 22:01:27 +0100 <geekosaur> wrong program…
2022-01-27 22:02:02 +0100zincy(~zincy@2a00:23c8:970c:4801:f0bc:c4cb:1665:1c67)
2022-01-27 22:02:49 +0100 <geekosaur> may require an explicit -cpp, not just -XCPP
2022-01-27 22:03:00 +0100 <geekosaur> *sorry
2022-01-27 22:03:59 +0100 <maerwald> yeah, I gave up on that
2022-01-27 22:04:03 +0100 <maerwald> :D
2022-01-27 22:05:58 +0100Erutuon(~Erutuon@user/erutuon) (Ping timeout: 260 seconds)
2022-01-27 22:07:50 +0100ProfSimm(~ProfSimm@87.227.196.109)
2022-01-27 22:07:54 +0100coot(~coot@213.134.190.95) (Quit: coot)
2022-01-27 22:09:04 +0100_ht(~quassel@2a02:a468:b619:1:fb02:7b89:e577:dc30) (Remote host closed the connection)
2022-01-27 22:11:57 +0100raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) (Ping timeout: 240 seconds)
2022-01-27 22:14:12 +0100raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net)
2022-01-27 22:14:43 +0100eggplantade(~Eggplanta@2600:1700:bef1:5e10:41be:eda7:26bd:771e) (Remote host closed the connection)
2022-01-27 22:16:26 +0100Topsi(~Tobias@dyndsl-091-249-083-234.ewe-ip-backbone.de) (Read error: Connection reset by peer)
2022-01-27 22:16:37 +0100romesrf(~romes@44.190.189.46.rev.vodafone.pt) (Quit: WeeChat 3.4)
2022-01-27 22:18:13 +0100dhouthoo(~dhouthoo@178-117-36-167.access.telenet.be) (Quit: WeeChat 3.4)
2022-01-27 22:24:22 +0100cosimone(~user@2001:b07:ae5:db26:c24a:d20:4d91:1e20) (Quit: ERC (IRC client for Emacs 27.1))
2022-01-27 22:26:35 +0100merijn(~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl)
2022-01-27 22:28:09 +0100coot(~coot@213.134.190.95)
2022-01-27 22:28:28 +0100pottsy(~pottsy@129.227.183.244) (Ping timeout: 250 seconds)
2022-01-27 22:30:57 +0100mon_aaraj(~MonAaraj@user/mon-aaraj/x-4416475) (Ping timeout: 240 seconds)
2022-01-27 22:33:11 +0100mon_aaraj(~MonAaraj@user/mon-aaraj/x-4416475)
2022-01-27 22:34:56 +0100jao(~jao@static-68-235-44-73.cust.tzulo.com) (Ping timeout: 250 seconds)
2022-01-27 22:36:36 +0100alx741(~alx741@157.100.197.240)
2022-01-27 22:37:09 +0100jao(~jao@static-68-235-44-10.cust.tzulo.com)
2022-01-27 22:39:30 +0100alx741(~alx741@157.100.197.240) (Read error: Connection reset by peer)
2022-01-27 22:40:45 +0100alMalsamo(~alMalsamo@gateway/tor-sasl/almalsamo)
2022-01-27 22:41:15 +0100doyougnu(~doyougnu@cpe-67-249-83-190.twcny.res.rr.com)
2022-01-27 22:42:47 +0100fendor_(~fendor@77.119.199.145.wireless.dyn.drei.com) (Remote host closed the connection)
2022-01-27 22:42:53 +0100coot(~coot@213.134.190.95) (Quit: coot)
2022-01-27 22:43:10 +0100max22-(~maxime@lfbn-ren-1-1026-62.w92-139.abo.wanadoo.fr) (Remote host closed the connection)
2022-01-27 22:44:01 +0100max22-(~maxime@lfbn-ren-1-1026-62.w92-139.abo.wanadoo.fr)
2022-01-27 22:44:58 +0100alx741(~alx741@157.100.197.240)
2022-01-27 22:46:32 +0100ardell(~ardell@user/ardell) (Quit: Konversation terminated!)
2022-01-27 22:47:12 +0100MoC(~moc@user/moc) (Quit: Konversation terminated!)
2022-01-27 22:47:18 +0100alx741(~alx741@157.100.197.240) (Client Quit)
2022-01-27 22:48:04 +0100 <tomsmeding> maerwald: dealing with some esoteric code?
2022-01-27 22:48:28 +0100 <maerwald> no, just wanted to tell myself where the ifdef ends
2022-01-27 22:48:43 +0100 <maerwald> #endif // Foo
2022-01-27 22:48:50 +0100 <maerwald> it starts throwing warnings
2022-01-27 22:48:52 +0100 <tomsmeding> gcc manpage says that they "should be in comments"
2022-01-27 22:48:54 +0100 <tomsmeding> really?
2022-01-27 22:49:13 +0100 <tomsmeding> the manpage claims that it warns if it's _not_ in a comment, and that it should be in a comment
2022-01-27 22:49:19 +0100 <geekosaur> you do realize // is not a C comment? (unless you declare a recent enough C standard I think)
2022-01-27 22:49:20 +0100 <tomsmeding> or is this not gcc
2022-01-27 22:49:51 +0100 <geekosaur> it's a C++ comment. /* ... */ is a C comment
2022-01-27 22:50:46 +0100arjun(~arjun@user/arjun) (Remote host closed the connection)
2022-01-27 22:50:55 +0100 <tomsmeding> geekosaur: gcc accepts it starting with -std=c99; -std=c90 rejects it
2022-01-27 22:52:25 +0100 <geekosaur> right but I think we run cpp in -traditional so it doesn't mess things up
2022-01-27 22:52:37 +0100 <geekosaur> which means no -std
2022-01-27 22:53:04 +0100wroathe(~wroathe@206-55-188-8.fttp.usinternet.com)
2022-01-27 22:53:05 +0100wroathe(~wroathe@206-55-188-8.fttp.usinternet.com) (Changing host)
2022-01-27 22:53:05 +0100wroathe(~wroathe@user/wroathe)
2022-01-27 22:53:12 +0100 <geekosaur> (being unable to do this with clang is why you have to be careful with CPP on Macs)
2022-01-27 22:55:39 +0100takuan(~takuan@178-116-218-225.access.telenet.be) (Remote host closed the connection)
2022-01-27 22:56:36 +0100merijn(~merijn@c-001-001-018.client.esciencecenter.eduvpn.nl) (Ping timeout: 250 seconds)
2022-01-27 23:01:26 +0100gehmehgeh(~user@user/gehmehgeh) (Quit: Leaving)
2022-01-27 23:03:17 +0100mon_aaraj(~MonAaraj@user/mon-aaraj/x-4416475) (Ping timeout: 240 seconds)
2022-01-27 23:05:18 +0100briandaed(~root@185.234.208.208.r.toneticgroup.pl) (Remote host closed the connection)
2022-01-27 23:05:28 +0100Erutuon(~Erutuon@user/erutuon)
2022-01-27 23:05:30 +0100mon_aaraj(~MonAaraj@user/mon-aaraj/x-4416475)
2022-01-27 23:06:02 +0100haskellberryfinn(~nut@roc37-h01-176-170-197-243.dsl.sta.abo.bbox.fr) (Quit: WeeChat 2.8)
2022-01-27 23:09:00 +0100 <ProfSimm> What's the difference between an imperative program and the IO monad / do notation
2022-01-27 23:09:37 +0100mon_aaraj(~MonAaraj@user/mon-aaraj/x-4416475) (Ping timeout: 240 seconds)
2022-01-27 23:09:44 +0100Guest76(~Guest76@a109-50-190-38.cpe.netcabo.pt)
2022-01-27 23:11:00 +0100 <Guest76> is someone willing to discuss some curry/uncurry laws?
2022-01-27 23:11:28 +0100 <monochrom> I may be able to discuss some curry and uncurry laws.
2022-01-27 23:11:38 +0100 <monochrom> Depends on what you really mean.
2022-01-27 23:11:49 +0100mon_aaraj(~MonAaraj@user/mon-aaraj/x-4416475)
2022-01-27 23:12:40 +0100 <polyphem> ProfSimm: main :: IO () is a pure value wheras void main is actuall code
2022-01-27 23:13:01 +0100 <Guest76> first, i was looking for some information about applying curry function to a 3 variable scenario, like: function a b c
2022-01-27 23:13:54 +0100 <Guest76> but i ended up applying it 2 times so it becomes, curry(curry( function((a,b),c) ))
2022-01-27 23:14:28 +0100 <monochrom> Sure, the standard library "curry" function handles 2 only.
2022-01-27 23:15:07 +0100eggplantade(~Eggplanta@2600:1700:bef1:5e10:41be:eda7:26bd:771e)
2022-01-27 23:15:07 +0100 <monochrom> Haskell type system is not flexible at all about "n-ary for arbitrary n".
2022-01-27 23:15:39 +0100alp(~alp@user/alp)
2022-01-27 23:15:44 +0100 <Guest76> the goal of this exercise was to make some pointwise function into point free
2022-01-27 23:15:45 +0100 <ProfSimm> polyphem: it's a pure value but I mean it's technically the source code to an imperative program.
2022-01-27 23:16:13 +0100 <maerwald> what is an imperative program?
2022-01-27 23:16:39 +0100 <Guest76> if i have uncurry(function1 . function2 . function3) . swap = curry(curry( function((a,b),c) ))
2022-01-27 23:16:44 +0100 <monochrom> I recommend working on one specific concrete exercise rather than premature idle wondering about gross generality.
2022-01-27 23:17:30 +0100 <Guest76> could i apply something  to cut  some curry/uncurry
2022-01-27 23:18:02 +0100 <Guest76> could i pm you?
2022-01-27 23:18:07 +0100 <monochrom> No.
2022-01-27 23:18:24 +0100 <maerwald> :'(
2022-01-27 23:18:40 +0100 <monochrom> I don't understand "uncurry(function1 . function2 . function3) . swap = curry(curry( function((a,b),c) ))".
2022-01-27 23:19:01 +0100 <Guest76> i see, i see
2022-01-27 23:19:07 +0100 <monochrom> I understand the RHS. I think I understand the LHS. I don't understand why you get to assume they are equal.
2022-01-27 23:19:32 +0100eggplantade(~Eggplanta@2600:1700:bef1:5e10:41be:eda7:26bd:771e) (Ping timeout: 240 seconds)
2022-01-27 23:19:35 +0100 <monochrom> I am not even convinced they have compatible types.
2022-01-27 23:19:50 +0100 <Guest76> hum... i see what you are saying
2022-01-27 23:20:00 +0100deadmarshal(~deadmarsh@95.38.119.169) (Ping timeout: 256 seconds)
2022-01-27 23:20:06 +0100eggplantade(~Eggplanta@2600:1700:bef1:5e10:41be:eda7:26bd:771e)
2022-01-27 23:20:34 +0100neceve(~quassel@2.26.93.228) (Ping timeout: 256 seconds)
2022-01-27 23:21:37 +0100 <monochrom> If you want to bridge the gap between "f (a,b,c)" and "g a b c", the simplest way is to define your own 3-ary version of curry3 and uncurry3, rather than trying to shoehorn into curry and uncurry.
2022-01-27 23:22:11 +0100 <Guest76> that was my inicial idea
2022-01-27 23:22:25 +0100 <polyphem> ProfSimm: if you understand that an imperative programming style results from an abstraction away from hardware , haskells IO monad is still based on lamda calculus i.e term rewriting , even if do notation "emulates" the feeling of imerativity
2022-01-27 23:22:26 +0100 <Guest76> but for the sake of this academic exercise i don't think is the point
2022-01-27 23:22:51 +0100 <monochrom> Where can I see "this exercise"?
2022-01-27 23:23:44 +0100 <ProfSimm> polyphem: well it not only emulates the feeling of it, but the operation of it, doesn't it
2022-01-27 23:24:23 +0100 <Gurkenglas> :k (->) -- should be *^op -> * -> * :(
2022-01-27 23:24:24 +0100 <lambdabot> * -> * -> *
2022-01-27 23:24:47 +0100 <polyphem> ProfSimm: that's why some say haskell is the "best" imperative language :)
2022-01-27 23:25:54 +0100coot(~coot@213.134.190.95)
2022-01-27 23:26:42 +0100chomwitt(~chomwitt@2a02:587:dc16:6e00:12c3:7bff:fe6d:d374) (Remote host closed the connection)
2022-01-27 23:26:43 +0100 <polyphem> ProfSimm: Monads in haskell give you sequencing of actions , i.e a timeline on wich you can chain your actions, whereas pure code has no timly order of execution
2022-01-27 23:27:32 +0100 <monochrom> I agree with maerwald about "which kind of imperative do you have in mind?"
2022-01-27 23:27:53 +0100coot(~coot@213.134.190.95) (Client Quit)
2022-01-27 23:28:06 +0100zincy(~zincy@2a00:23c8:970c:4801:f0bc:c4cb:1665:1c67) (Remote host closed the connection)
2022-01-27 23:28:10 +0100 <monochrom> Because sometimes it just means mutable state, some other times it just means I/O, and some other times it means both, and some other times something else entirely.
2022-01-27 23:28:54 +0100coot(~coot@213.134.190.95)
2022-01-27 23:29:01 +0100 <ProfSimm> monochrom: well it means "time" first, as you noted. Order of cause and effect, and change. Hence mutability. This then allows side-effects as... a side-effect.
2022-01-27 23:29:02 +0100 <Guest76> monochrom it's a rather lengthy page written in portuguese, but its basically a function written in point-wise notation that i have to "translate" in to point-free
2022-01-27 23:29:07 +0100 <Guest76> ty for the help anyways
2022-01-27 23:29:16 +0100 <tomsmeding> @pl \x y z -> f z x y
2022-01-27 23:29:16 +0100 <lambdabot> flip . flip f
2022-01-27 23:29:53 +0100 <polyphem> i guess ProfSimm means imperative in sense of tickyticky execution , telleing the computer what steps to take , step by step , right ProfSimm ?
2022-01-27 23:29:56 +0100 <monochrom> I won't play along with talking in the generality void.
2022-01-27 23:30:25 +0100 <monochrom> And I won't play along with the querent providing zero information and expecting me to give an infinitely informative lecture.
2022-01-27 23:31:00 +0100 <geekosaur> I do not see what pointfree has to do with currying
2022-01-27 23:31:08 +0100 <geekosaur> in this instance
2022-01-27 23:31:47 +0100 <tomsmeding> @pl \a b c d e -> f (a, (b, (c, (d, e))))
2022-01-27 23:31:47 +0100 <lambdabot> ((((f .) .) .) .) . (. ((. ((. (,)) . (.) . (,))) . (.) . (.) . (,))) . (.) . (.) . (.) . (,)
2022-01-27 23:32:08 +0100 <monochrom> I know someone here who used to do that. But that's when they were unemployed.
2022-01-27 23:32:32 +0100vglfr(~vglfr@46.96.142.183) (Ping timeout: 240 seconds)
2022-01-27 23:33:26 +0100 <Guest76> just a student here, probably don't know what i should be asking, sorry y'all
2022-01-27 23:33:51 +0100 <monochrom> You could actually post an actual exercise.
2022-01-27 23:34:41 +0100 <monochrom> "I have f x y = x, how to rewrite it in pointfree form" is not hard to type in.
2022-01-27 23:35:41 +0100 <maerwald> polyphem: well, *execution* is all imperative, even in Haskell
2022-01-27 23:36:33 +0100 <Guest76> it goes like this:
2022-01-27 23:36:33 +0100 <Guest76> data X u i = XLeaf u | Node i (X u i) (X u i) deriving Show
2022-01-27 23:36:34 +0100 <Guest76> x2html :: X (Unit String String) (Mode Double) -> (Double, Double) -> String
2022-01-27 23:36:35 +0100 <Guest76> x2html (Node (Vt i) x1 x2) (w,h) = htab w h (
2022-01-27 23:36:36 +0100 <Guest76>                                      tr( td w (h*i) (x2html x1 (w, h*i))) ++
2022-01-27 23:36:36 +0100 <Guest76>                                      tr( td w (h*(1-i)) (x2html x2 (w, h*(1-i))))
2022-01-27 23:36:36 +0100 <Guest76>                                    )
2022-01-27 23:36:37 +0100 <Guest76> x2html (Node (Hl i) x1 x2) (w,h) = htab w h (
2022-01-27 23:36:37 +0100 <Guest76>                                      tr( td (w*i) h (x2html x1 (w*i, h)) ++
2022-01-27 23:36:38 +0100 <Guest76>                                          td (w*(1-i)) h (x2html x2 (w*(1-i), h)))
2022-01-27 23:36:38 +0100 <Guest76>                                    )
2022-01-27 23:36:39 +0100 <Guest76> x2html (Node (Vb i) x1 x2) m = x2html (Node (Vt (1 - i)) x1 x2) m
2022-01-27 23:36:40 +0100 <Guest76> x2html (Node (Hr i) x1 x2) m = x2html (Node (Hl (1 - i)) x1 x2) m
2022-01-27 23:36:47 +0100 <tomsmeding> pff
2022-01-27 23:37:13 +0100 <tomsmeding> also
2022-01-27 23:37:14 +0100 <tomsmeding> @where paste
2022-01-27 23:37:14 +0100 <lambdabot> Help us help you: please paste full code, input and/or output at e.g. https://paste.tomsmeding.com
2022-01-27 23:37:23 +0100 <EvanR> the sense of time is still there in non-IO computations, when there is unavoidable data dependency on some other thing of the thing you actually want
2022-01-27 23:37:40 +0100LiaoTao_(~LiaoTao@gateway/tor-sasl/liaotao) (Remote host closed the connection)
2022-01-27 23:37:40 +0100 <EvanR> one thing must be computed before the other
2022-01-27 23:37:57 +0100 <EvanR> which is why Tardis can only go so far
2022-01-27 23:37:57 +0100LiaoTao(~LiaoTao@gateway/tor-sasl/liaotao)
2022-01-27 23:38:49 +0100 <EvanR> laziness is good because when the data dependency isn't there, you aren't limited to an artificial ordering
2022-01-27 23:38:52 +0100 <monochrom> That one is very difficult to convert to pointfree.
2022-01-27 23:39:32 +0100 <tomsmeding> impossible without a helper function that gets the field from an XLeaf, in fact
2022-01-27 23:39:52 +0100 <EvanR> similarly, in IO code, you aren't always limited to an artificial ordering either, see that applicative interface for doing web requests in parallel and operating on the result when / if the components are ready
2022-01-27 23:39:58 +0100 <polyphem> EvanR: yes implicit data dependencies order the evaluation also in pure code, but monad the data dependency is made explicit with >>=
2022-01-27 23:39:58 +0100 <monochrom> I have trouble believing that any reasonable teacher actually wants it.
2022-01-27 23:40:17 +0100 <Guest76> we have one of the best in the field, i belive
2022-01-27 23:40:42 +0100 <EvanR> I guess here we are again forgetting that IO's monadness is tangential esp when considering IO Applicative xD
2022-01-27 23:41:49 +0100LiaoTao(~LiaoTao@gateway/tor-sasl/liaotao) (Remote host closed the connection)
2022-01-27 23:42:13 +0100 <monochrom> Well, the alternative hypothesis is that the student completely misunderstands the homework question.
2022-01-27 23:42:15 +0100LiaoTao(~LiaoTao@gateway/tor-sasl/liaotao)
2022-01-27 23:42:37 +0100 <monochrom> Actually extremely high probability given the selection bias.
2022-01-27 23:42:46 +0100 <maerwald> I feel like I'm in a monad tutorial again
2022-01-27 23:42:51 +0100 <maerwald> please NO
2022-01-27 23:42:54 +0100 <ephemient> a perspective: https://conal.net/blog/posts/the-c-language-is-purely-functional - CPP produces C that can be executed sequentially. Haskell produces IO () that can be executed sequentially.
2022-01-27 23:43:13 +0100 <EvanR> I love that post
2022-01-27 23:43:36 +0100 <Guest76> monochrom very  high probability indeed, i can assure you ahah
2022-01-27 23:45:59 +0100 <polyphem> ephemient: is the conal.net post down ?
2022-01-27 23:46:16 +0100 <EvanR> conal.net is down : (
2022-01-27 23:46:18 +0100 <Guest76> i could link the hashlab page, but like i said it is in Portuguese
2022-01-27 23:46:36 +0100michalz(~michalz@185.246.204.61) (Remote host closed the connection)
2022-01-27 23:46:46 +0100 <Guest76> monochrom ty for your time, sorry to waste it
2022-01-27 23:46:48 +0100 <ephemient> hmm. www.conal.net is up, but my browser "helpfully" copied conal.net without www
2022-01-27 23:47:17 +0100 <ephemient> also http works I guess?
2022-01-27 23:47:38 +0100 <monochrom> Also s/https/http/
2022-01-27 23:47:41 +0100 <polyphem> http://conal.net/blog/posts/the-c-language-is-purely-functional
2022-01-27 23:47:58 +0100 <EvanR> ah
2022-01-27 23:48:12 +0100 <monochrom> I know some people or software that "helpfully" replace http by https as if I needed it.
2022-01-27 23:49:01 +0100eggplantade(~Eggplanta@2600:1700:bef1:5e10:41be:eda7:26bd:771e) (Remote host closed the connection)
2022-01-27 23:50:32 +0100 <ProfSimm> polyphem: we're talking about time and change and causality and effect, but actually imperial code doens't strictly run sequentially.
2022-01-27 23:50:35 +0100 <codolio> Note that from the summary, you can tell that the headline is completely false.
2022-01-27 23:50:49 +0100 <maerwald> imperial code?
2022-01-27 23:50:50 +0100 <ProfSimm> polyphem: so actually representing it as a monad which can only apply it sequentially is detrimental
2022-01-27 23:50:52 +0100codoliodolio
2022-01-27 23:51:09 +0100 <ProfSimm> maerwald: also imperative *
2022-01-27 23:51:14 +0100 <ProfSimm> :P
2022-01-27 23:51:24 +0100 <monochrom> I won't mind "imperial". "emperor" used to begin as "imperator". :)
2022-01-27 23:51:27 +0100 <EvanR> but Applicative potentially supports parallel
2022-01-27 23:51:34 +0100 <ProfSimm> nais
2022-01-27 23:51:50 +0100 <EvanR> a plus 1 over monads in that sense
2022-01-27 23:52:25 +0100 <maerwald> that's just an old facebook hack that probably is not even a good idea
2022-01-27 23:52:50 +0100 <EvanR> applicative is one way to express a parallel composition in e.g. a hardware circuit
2022-01-27 23:53:05 +0100 <EvanR> compiling to categories
2022-01-27 23:53:14 +0100 <monochrom> Haskell is a republic programming language >:)
2022-01-27 23:54:00 +0100 <Benzi-Junior> hey, I'm having a little problem with xmobar under debian,
2022-01-27 23:54:51 +0100 <Benzi-Junior> when I try to build with a xmobar.hs config it doesnt find the module xmobar
2022-01-27 23:57:35 +0100Tuplanolla(~Tuplanoll@91-159-68-166.elisa-laajakaista.fi) (Quit: Leaving.)
2022-01-27 23:58:17 +0100 <EvanR> I too would like to come up with a joke pertaining to "imperial code" but just can't
2022-01-27 23:59:19 +0100 <monochrom> Try to make a Star Wars joke/reference :)