Home liberachat/#haskell: Logs Calendar

Logs on 2023-01-08 (liberachat/#haskell)

00:01:21 × myxokephale quits (~max@cpe-65-28-251-121.cinci.res.rr.com) (Quit: leaving)
00:04:09 <geekosaur> energizer, you asked earlier what the inverse of <> was. inverses are not relevant to all monoids, only those which comprise rings. and iirc it's proven that the * operator in a ring can only have an inverse if the ring is trivial (the set it applies to has only one element)?
00:04:24 <geekosaur> (I may well be misremembering, I'm still a bit weak on this stuff)
00:04:29 myxokephale joins (~max@cpe-65-28-251-121.cinci.res.rr.com)
00:05:04 <geekosaur> anyway there are arguments for either monoid comprising a ring to be primary, and you can't really pick one without losing something
00:05:21 <energizer> i think the answer I was looking for was the </> operator that jackdk linked
00:05:50 × Kaipei quits (~Kaiepi@nwcsnbsc03w-47-55-159-86.dhcp-dynamic.fibreop.nb.bellaliant.net) (Ping timeout: 260 seconds)
00:06:48 <monochrom> OK do you mean your original question was where to find stripPrefix in Data.List and you XY-problem it to the 10th power and decided to ask instead why <> doesn't do multiplication for Integer.
00:08:52 <energizer> i dont think this needs to be so aggressive does it
00:13:25 × thongpv87 quits (~thongpv87@2402:9d80:34d:fde9:8a11:e98e:b8b0:cf04) (Ping timeout: 260 seconds)
00:16:28 hgolden joins (~hgolden@cpe-172-251-233-141.socal.res.rr.com)
00:16:30 <ncf> in the denotational semantics of haskell, is ⊥ supposed to be equal to const ⊥? it certainly seems like it shouldn't, since const ⊥ `seq` x is not ⊥, but if i understand correctly we should have ⊥ = const ⊥ in a dcpo
00:16:41 <ncf> so what actually models haskell, if not dcpos?
00:17:31 <geekosaur> iirc seq complicates every such model…
00:18:23 <ncf> is there a reference that goes into this stuff?
00:19:44 <geekosaur> someone who understands better should probably answer that. (I'm not aware of any but that proves little.)
00:20:01 <dolio> I think game semantics distinguishes those, while being kind of similar.
00:21:03 <dolio> Actually, I'm not 100% sure about game semantics of partial functions. But it seems like the kind of thing it could distinguish.
00:21:30 <ncf> hmm
00:21:44 <ncf> it feels like there should be a slight modification to dcpos that makes this work
00:22:00 <ncf> i.e. add a distinguished ⊥ to function spaces and adapt the closed structure
00:22:09 <dolio> Yeah, you might be able to define a lifted function space DCPO.
00:22:53 <dolio> Actually, it probably is just that.
00:27:12 <ncf> cool
00:35:37 eggplantade joins (~Eggplanta@2600:1700:38c5:d800:cc20:d690:f22b:cb00)
00:36:04 <dolio> The same thing happens with products in Haskell. They have more lifting than the cartesian product of DCPOs.
00:38:06 × coderpath quits (~coderpath@d66-183-126-83.bchsia.telus.net) (Quit: ZNC 1.8.2 - https://znc.in)
00:41:43 × Tuplanolla quits (~Tuplanoll@91-159-68-152.elisa-laajakaista.fi) (Quit: Leaving.)
00:43:08 × xff0x quits (~xff0x@2405:6580:b080:900:c792:9a92:2632:4781) (Ping timeout: 255 seconds)
00:43:22 <ncf> indeed. i think all data types are lifted
00:43:32 xff0x joins (~xff0x@178.255.149.135)
00:43:42 <ncf> (but not newtypes)
00:44:12 wroathe joins (~wroathe@207-153-38-140.fttp.usinternet.com)
00:44:12 × wroathe quits (~wroathe@207-153-38-140.fttp.usinternet.com) (Changing host)
00:44:12 wroathe joins (~wroathe@user/wroathe)
00:46:37 <dolio> Yeah.
00:46:55 slac38021 joins (~slack1256@186.11.40.220)
00:49:27 × slack1256 quits (~slack1256@191.126.99.79) (Ping timeout: 260 seconds)
00:49:52 <monochrom> In a haskell-cafe post today from Eisenberg: "There is much eagerness to use unboxed types." I can't help but perceive the pun there. :)
00:50:17 <monochrom> Context: He's describing his job at Jane Street of adding unboxed types to OCaml.
00:50:28 <mniip> unboxed closures when
00:51:25 <monochrom> (And this being an opportunity of doing levity polymorphism for both Haskell and OCaml.)
00:52:30 <mniip> I've given the "KnownRep" typeclass some thought before, but it's not clear to me if it's possible to represent the "calling convention instructions" as haskell code
00:53:35 × mizlan quits (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net) (Ping timeout: 264 seconds)
00:54:33 <mniip> for example part of the behavior that is determined by the representation is how to do an stg-level let binding
00:54:50 <mniip> and whether something is let-bound or not, is not reflected in the types at the core/haskell level
00:57:48 mizlan joins (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net)
01:00:19 × xff0x quits (~xff0x@178.255.149.135) (Ping timeout: 260 seconds)
01:01:45 xff0x joins (~xff0x@2405:6580:b080:900:c792:9a92:2632:4781)
01:01:56 × mizlan quits (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net) (Ping timeout: 246 seconds)
01:07:18 × L29Ah quits (~L29Ah@wikipedia/L29Ah) (Read error: Connection reset by peer)
01:10:25 × albet70 quits (~xxx@2400:8902::f03c:92ff:fe60:98d8) (Remote host closed the connection)
01:16:32 albet70 joins (~xxx@2400:8902::f03c:92ff:fe60:98d8)
01:23:45 × wroathe quits (~wroathe@user/wroathe) (Quit: leaving)
01:24:07 wroathe joins (~wroathe@207-153-38-140.fttp.usinternet.com)
01:24:07 × wroathe quits (~wroathe@207-153-38-140.fttp.usinternet.com) (Changing host)
01:24:07 wroathe joins (~wroathe@user/wroathe)
01:30:34 mizlan joins (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net)
01:35:16 × mizlan quits (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net) (Ping timeout: 268 seconds)
01:39:35 mizlan joins (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net)
01:42:32 talismanick joins (~talismani@5.187.27.20)
01:42:45 v0id_ptr joins (~adrift@user/ptr-frac7al/x-0038398)
01:47:14 × talismanick quits (~talismani@5.187.27.20) (Ping timeout: 272 seconds)
01:47:36 L29Ah joins (~L29Ah@wikipedia/L29Ah)
01:50:34 <slac38021> mniip: I don't know much about the subject, but why would be unboxed closures great?
01:52:14 × freeside quits (~mengwong@103.252.202.159) (Ping timeout: 260 seconds)
01:53:16 <mniip> much like with any other unboxed thing, they live off the heap and you could have more precise control over heap allocation
01:53:26 slac38021 is now known as slack1256
02:03:17 myxokephale_ joins (~myxokepha@cpe-65-28-251-121.cinci.res.rr.com)
02:04:15 × [itchyjunk] quits (~itchyjunk@user/itchyjunk/x-7353470) (Ping timeout: 260 seconds)
02:04:34 freeside joins (~mengwong@103.252.202.159)
02:05:39 × myxokephale_ quits (~myxokepha@cpe-65-28-251-121.cinci.res.rr.com) (Client Quit)
02:05:53 myxokephale_ joins (~myxokepha@cpe-65-28-251-121.cinci.res.rr.com)
02:05:56 talismanick joins (~talismani@5.187.27.20)
02:06:40 × myxokephale_ quits (~myxokepha@cpe-65-28-251-121.cinci.res.rr.com) (Client Quit)
02:06:54 myxokephale_ joins (~myxokepha@cpe-65-28-251-121.cinci.res.rr.com)
02:08:11 [itchyjunk] joins (~itchyjunk@user/itchyjunk/x-7353470)
02:08:20 × waleee quits (~waleee@2001:9b0:213:7200:cc36:a556:b1e8:b340) (Ping timeout: 252 seconds)
02:09:05 × myxokephale quits (~max@cpe-65-28-251-121.cinci.res.rr.com) (Quit: leaving)
02:09:10 × myxokephale_ quits (~myxokepha@cpe-65-28-251-121.cinci.res.rr.com) (Client Quit)
02:09:24 × freeside quits (~mengwong@103.252.202.159) (Ping timeout: 272 seconds)
02:09:24 myxokephale joins (~myxokepha@cpe-65-28-251-121.cinci.res.rr.com)
02:10:13 × talismanick quits (~talismani@5.187.27.20) (Ping timeout: 252 seconds)
02:10:29 × myxokephale quits (~myxokepha@cpe-65-28-251-121.cinci.res.rr.com) (Client Quit)
02:10:44 myxokephale joins (~myxokepha@cpe-65-28-251-121.cinci.res.rr.com)
02:11:21 × myxokephale quits (~myxokepha@cpe-65-28-251-121.cinci.res.rr.com) (Client Quit)
02:11:34 myxokephale joins (~myxokepha@cpe-65-28-251-121.cinci.res.rr.com)
02:11:56 × myxokephale quits (~myxokepha@cpe-65-28-251-121.cinci.res.rr.com) (Client Quit)
02:12:10 myxokephale joins (~myxokepha@cpe-65-28-251-121.cinci.res.rr.com)
02:12:16 × myxokephale quits (~myxokepha@cpe-65-28-251-121.cinci.res.rr.com) (Client Quit)
02:13:05 myxokephale joins (~myxokepha@cpe-65-28-251-121.cinci.res.rr.com)
02:14:38 × L29Ah quits (~L29Ah@wikipedia/L29Ah) (Read error: Connection reset by peer)
02:24:15 × harveypwca quits (~harveypwc@2601:246:c180:a570:3828:d8:e523:3f67) (Quit: Leaving)
02:25:40 freeside joins (~mengwong@103.252.202.159)
02:28:29 thongpv joins (~thongpv87@2402:9d80:34d:fde9:8a11:e98e:b8b0:cf04)
02:34:19 × beteigeuze quits (~Thunderbi@bl14-81-220.dsl.telepac.pt) (Ping timeout: 248 seconds)
02:34:33 thongpv87 joins (~thongpv87@14.160.124.248)
02:37:12 accord joins (uid568320@id-568320.hampstead.irccloud.com)
02:37:30 × thongpv quits (~thongpv87@2402:9d80:34d:fde9:8a11:e98e:b8b0:cf04) (Ping timeout: 260 seconds)
02:41:13 × eggplantade quits (~Eggplanta@2600:1700:38c5:d800:cc20:d690:f22b:cb00) (Remote host closed the connection)
02:42:02 eggplantade joins (~Eggplanta@104-55-37-220.lightspeed.sntcca.sbcglobal.net)
02:44:26 ddellacosta joins (~ddellacos@89.45.224.152)
02:45:30 × mizlan quits (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net) (Ping timeout: 272 seconds)
02:47:34 × Umeaboy quits (~Umeaboy@94-255-145-133.cust.bredband2.com) (Quit: Leaving)
03:00:32 L29Ah joins (~L29Ah@wikipedia/L29Ah)
03:02:27 × L29Ah quits (~L29Ah@wikipedia/L29Ah) (Read error: Connection reset by peer)
03:04:21 <DigitalKiwi> mniip: *wave*
03:06:35 mizlan joins (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net)
03:08:56 × td_ quits (~td@83.135.9.51) (Ping timeout: 255 seconds)
03:10:42 td_ joins (~td@83.135.9.53)
03:14:53 × caef^ quits (~caef@76.145.190.81) (Remote host closed the connection)
03:31:05 × azimut quits (~azimut@gateway/tor-sasl/azimut) (Ping timeout: 255 seconds)
03:31:30 × freeside quits (~mengwong@103.252.202.159) (Ping timeout: 265 seconds)
03:42:18 freeside joins (~mengwong@103.252.202.159)
03:47:41 slac39102 joins (~slack1256@191.126.227.209)
03:48:14 sus joins (~sus@user/zeromomentum)
03:49:06 <sus> hello all, does anyone have experience with stack? when running stack build, i get this error https://paste.tomsmeding.com/4zIwXgI1
03:49:18 <sus> this is like my 2nd time using haskell so i have no clue what's going on
03:50:19 × slack1256 quits (~slack1256@186.11.40.220) (Ping timeout: 268 seconds)
03:52:27 jinsun is now known as Guest1763
03:52:27 jinsun__ joins (~jinsun@user/jinsun)
03:52:27 × Guest1763 quits (~jinsun@user/jinsun) (Killed (molybdenum.libera.chat (Nickname regained by services)))
03:52:27 jinsun__ is now known as jinsun
03:52:59 × thongpv87 quits (~thongpv87@14.160.124.248) (Ping timeout: 260 seconds)
03:57:26 × sus quits (~sus@user/zeromomentum) (Quit: Client closed)
03:58:56 finn_elija joins (~finn_elij@user/finn-elija/x-0085643)
03:58:56 × FinnElija quits (~finn_elij@user/finn-elija/x-0085643) (Killed (NickServ (Forcing logout FinnElija -> finn_elija)))
03:58:56 finn_elija is now known as FinnElija
04:04:37 sus joins (1b7af6299f@user/zeromomentum)
04:08:06 sayola joins (~sayola@ipservice-092-213-087-211.092.213.pools.vodafone-ip.de)
04:08:07 <davean> So I know nothing about stack, don't use it, but that seems like a clear error message?
04:08:15 × CiaoSen quits (~Jura@p200300c9572e35002a3a4dfffe84dbd5.dip0.t-ipconnect.de) (Ping timeout: 260 seconds)
04:08:16 <davean> Do you have LLVM installed in that version range sus?
04:10:40 × mizlan quits (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net) (Ping timeout: 268 seconds)
04:16:49 haritz joins (~hrtz@82-69-11-11.dsl.in-addr.zen.co.uk)
04:16:49 × haritz quits (~hrtz@82-69-11-11.dsl.in-addr.zen.co.uk) (Changing host)
04:16:49 haritz joins (~hrtz@user/haritz)
04:16:51 × slac39102 quits (~slack1256@191.126.227.209) (Read error: Connection reset by peer)
04:17:11 × haritz quits (~hrtz@user/haritz) (Remote host closed the connection)
04:22:42 mizlan joins (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net)
04:23:21 nehsou^ joins (~nehsou@76.145.190.81)
04:29:18 tromp joins (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
04:29:52 × tromp quits (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Client Quit)
04:31:26 thongpv87 joins (~thongpv87@2402:9d80:34d:fde9:bc1f:46cc:53a7:ee8b)
04:42:18 haritz joins (~hrtz@2a02:8010:65b5:0:6009:6384:e3cb:2220)
04:42:18 × haritz quits (~hrtz@2a02:8010:65b5:0:6009:6384:e3cb:2220) (Changing host)
04:42:18 haritz joins (~hrtz@user/haritz)
04:43:41 × haritz quits (~hrtz@user/haritz) (Remote host closed the connection)
04:44:19 haritz joins (~hrtz@2a02:8010:65b5:0:6009:6384:e3cb:2220)
04:44:19 × haritz quits (~hrtz@2a02:8010:65b5:0:6009:6384:e3cb:2220) (Changing host)
04:44:19 haritz joins (~hrtz@user/haritz)
04:45:12 × jao quits (~jao@cpc103048-sgyl39-2-0-cust502.18-2.cable.virginm.net) (Ping timeout: 268 seconds)
04:53:45 × EvanR quits (~EvanR@user/evanr) (Remote host closed the connection)
04:54:04 EvanR joins (~EvanR@user/evanr)
04:55:39 × machinedgod quits (~machinedg@d198-53-218-113.abhsia.telus.net) (Ping timeout: 248 seconds)
04:55:55 × wroathe quits (~wroathe@user/wroathe) (Quit: leaving)
04:56:36 × scoopahdoopah quits (~quassel@050-089-109-059.res.spectrum.com) (Remote host closed the connection)
05:06:14 × [Leary] quits (~Leary]@user/Leary/x-0910699) (Remote host closed the connection)
05:06:34 [Leary] joins (~Leary]@user/Leary/x-0910699)
05:09:23 slack1256 joins (~slack1256@186.11.40.220)
05:18:57 × [itchyjunk] quits (~itchyjunk@user/itchyjunk/x-7353470) (Remote host closed the connection)
05:28:32 × mizlan quits (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net) (Ping timeout: 252 seconds)
05:30:13 × johnjaye quits (~pi@173.209.64.74) (Ping timeout: 268 seconds)
05:30:13 mizlan joins (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net)
05:31:11 × haritz quits (~hrtz@user/haritz) (Quit: ZNC 1.8.2+deb2 - https://znc.in)
05:31:52 johnjaye joins (~pi@173.209.64.74)
05:34:35 × mizlan quits (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net) (Ping timeout: 260 seconds)
05:36:54 × accord quits (uid568320@id-568320.hampstead.irccloud.com) (Quit: Connection closed for inactivity)
05:40:25 fizbin joins (~fizbin@user/fizbin)
05:43:27 mizlan joins (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net)
05:44:03 instantaphex joins (~jb@c-73-171-252-84.hsd1.fl.comcast.net)
05:46:38 × fizbin quits (~fizbin@user/fizbin) (Ping timeout: 272 seconds)
05:48:16 × monochrom quits (trebla@216.138.220.146) (Quit: NO CARRIER)
05:53:13 <jackdk> My experience is that stack seems to cause a lot of frustration and no longer provides much of an advantage over cabal. But if that's what your tutorial is using then feel free to stay with it, I guess.
05:53:26 <jackdk> sus: What OS are you on, and how did you install stack?
05:54:11 <jackdk> The recommended method for the "big three" OSes these days is https://www.haskell.org/ghcup/ , FWIW, and I would be very surprised if it didn't at least prompt you to install LLVM
05:58:06 monochrom joins (trebla@216.138.220.146)
06:00:51 × irrgit__ quits (~irrgit@146.70.27.250) (Read error: Connection reset by peer)
06:04:32 × bitdex quits (~bitdex@gateway/tor-sasl/bitdex) (Ping timeout: 255 seconds)
06:08:04 <maerwald[m]> sus: darwin M1?
06:09:21 jinsun__ joins (~jinsun@user/jinsun)
06:09:21 × jinsun quits (~jinsun@user/jinsun) (Killed (zinc.libera.chat (Nickname regained by services)))
06:09:21 jinsun__ is now known as jinsun
06:22:36 bitdex joins (~bitdex@gateway/tor-sasl/bitdex)
06:28:48 × werneta quits (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net) (Ping timeout: 268 seconds)
06:29:27 werneta joins (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net)
06:44:49 thongpv joins (~thongpv87@2001:ee0:54ae:93a0:55a8:a4c7:8b73:21a9)
06:46:28 × thongpv87 quits (~thongpv87@2402:9d80:34d:fde9:bc1f:46cc:53a7:ee8b) (Ping timeout: 260 seconds)
06:51:14 × freeside quits (~mengwong@103.252.202.159) (Ping timeout: 272 seconds)
06:55:57 tromp joins (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
06:56:06 freeside joins (~mengwong@103.252.202.159)
07:06:04 <sm> is the fix to install a newer llvm with brew ? or, don't try to use ghc versions before 9.x on arm mac ? I don't remember
07:06:11 × tromp quits (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
07:09:58 <maerwald> sm: you install the llvm version it demands
07:23:12 tromp joins (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
07:27:42 <freeside> i vaguely remember having a similar problem ... for a while nix had the better option, then the native xcode "command line tools" pulled ahead, and i had to get rid of the nix version of llvm/clang
07:29:42 opticblast joins (~Thunderbi@secure-165.caltech.edu)
07:47:02 × johnw quits (~johnw@2600:1700:cf00:db0:d050:b87f:5cc2:4cc8) (Ping timeout: 255 seconds)
07:47:15 × jwiegley quits (~jwiegley@2600:1700:cf00:db0:d050:b87f:5cc2:4cc8) (Ping timeout: 260 seconds)
07:50:00 johnw joins (~johnw@2600:1700:cf00:db0:1:83a7:8879:1baf)
08:02:48 × instantaphex quits (~jb@c-73-171-252-84.hsd1.fl.comcast.net) (Ping timeout: 272 seconds)
08:04:42 × Batzy quits (~quassel@user/batzy) (Ping timeout: 272 seconds)
08:10:02 gmg joins (~user@user/gehmehgeh)
08:10:05 Kaipei joins (~Kaiepi@nwcsnbsc03w-47-55-159-86.dhcp-dynamic.fibreop.nb.bellaliant.net)
08:14:19 instantaphex joins (~jb@c-73-171-252-84.hsd1.fl.comcast.net)
08:19:16 × instantaphex quits (~jb@c-73-171-252-84.hsd1.fl.comcast.net) (Ping timeout: 272 seconds)
08:26:25 × opticblast quits (~Thunderbi@secure-165.caltech.edu) (Ping timeout: 252 seconds)
08:26:46 × eggplantade quits (~Eggplanta@104-55-37-220.lightspeed.sntcca.sbcglobal.net) (Remote host closed the connection)
08:35:11 × tromp quits (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
08:39:45 opticblast joins (~Thunderbi@secure-165.caltech.edu)
08:44:04 × opticblast quits (~Thunderbi@secure-165.caltech.edu) (Ping timeout: 260 seconds)
08:46:59 × gmg quits (~user@user/gehmehgeh) (Ping timeout: 255 seconds)
08:47:39 instantaphex joins (~jb@c-73-171-252-84.hsd1.fl.comcast.net)
08:51:39 gmg joins (~user@user/gehmehgeh)
08:51:45 × jinsun quits (~jinsun@user/jinsun) (Ping timeout: 252 seconds)
08:52:14 × instantaphex quits (~jb@c-73-171-252-84.hsd1.fl.comcast.net) (Ping timeout: 260 seconds)
08:56:26 × gmg quits (~user@user/gehmehgeh) (Ping timeout: 255 seconds)
08:58:16 trev_ joins (~trev@109.252.35.99)
08:59:51 gmg joins (~user@user/gehmehgeh)
09:00:02 × mizlan quits (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net) (Ping timeout: 246 seconds)
09:00:07 × mrkun[m] quits (~mrkunmatr@2001:470:69fc:105::2:2a39) (Quit: You have been kicked for being idle)
09:00:38 jargon joins (~jargon@174-22-197-118.phnx.qwest.net)
09:04:25 × Alex_test quits (~al_test@178.34.160.164) (Quit: ;-)
09:04:47 × AlexZenon quits (~alzenon@178.34.160.164) (Quit: ;-)
09:05:37 × AlexNoo quits (~AlexNoo@178.34.160.164) (Quit: Leaving)
09:12:32 × califax quits (~califax@user/califx) (Remote host closed the connection)
09:13:02 AlexNoo joins (~AlexNoo@178.34.160.164)
09:13:49 califax joins (~califax@user/califx)
09:16:29 acidjnk joins (~acidjnk@p200300d6e715c403d4287cbb3fd10346.dip0.t-ipconnect.de)
09:16:36 bgs joins (~bgs@212-85-160-171.dynamic.telemach.net)
09:19:50 mc47 joins (~mc47@xmonad/TheMC47)
09:19:50 Feuermagier joins (~Feuermagi@user/feuermagier)
09:20:34 AlexZenon joins (~alzenon@178.34.160.164)
09:20:55 instantaphex joins (~jb@c-73-171-252-84.hsd1.fl.comcast.net)
09:22:22 Alex_test joins (~al_test@178.34.160.164)
09:23:29 × Unicorn_Princess quits (~Unicorn_P@user/Unicorn-Princess/x-3540542) (Remote host closed the connection)
09:23:35 mizlan joins (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net)
09:25:35 × instantaphex quits (~jb@c-73-171-252-84.hsd1.fl.comcast.net) (Ping timeout: 260 seconds)
09:26:08 × califax quits (~califax@user/califx) (Ping timeout: 255 seconds)
09:27:15 eggplantade joins (~Eggplanta@2600:1700:38c5:d800:9c06:575b:efcb:5bf)
09:27:20 califax joins (~califax@user/califx)
09:30:06 mcglk joins (~mcglk@131.191.49.120)
09:30:08 mei joins (~mei@user/mei)
09:32:38 × eggplantade quits (~Eggplanta@2600:1700:38c5:d800:9c06:575b:efcb:5bf) (Ping timeout: 246 seconds)
09:33:24 cheater_ joins (~Username@user/cheater)
09:34:08 gnalzo joins (~gnalzo@2a01:e0a:498:fd50:fcc6:bb5d:489a:ce8c)
09:35:04 takuan joins (~takuan@178-116-218-225.access.telenet.be)
09:36:16 × cheater quits (~Username@user/cheater) (Ping timeout: 252 seconds)
09:36:20 cheater_ is now known as cheater
09:50:32 arjun joins (~arjun@user/arjun)
09:51:19 Tuplanolla joins (~Tuplanoll@91-159-68-152.elisa-laajakaista.fi)
09:53:20 acidjnk_new joins (~acidjnk@p200300d6e715c40369f7e4f04255c339.dip0.t-ipconnect.de)
09:57:19 × acidjnk quits (~acidjnk@p200300d6e715c403d4287cbb3fd10346.dip0.t-ipconnect.de) (Ping timeout: 260 seconds)
10:05:46 <mechap> jackdk: while stack is really frustrating, I think it is better regarding package management than cabal which does not even provide an option to uninstall package
10:06:26 <jackdk> When using cabal, I just delete the store every now and than. But most of the time I use Nix, so GCs take care of that.
10:09:09 <maerwald> mechap: what?
10:09:16 <maerwald> stack can uninstall packages?
10:09:18 <maerwald> show me
10:12:14 tromp joins (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
10:13:20 instantaphex joins (~jb@c-73-171-252-84.hsd1.fl.comcast.net)
10:17:47 × instantaphex quits (~jb@c-73-171-252-84.hsd1.fl.comcast.net) (Ping timeout: 246 seconds)
10:18:15 <mechap> nevermind, I thought it was different with stack. Anyway, stack has never worked correctly in my desktop.
10:18:34 × arjun quits (~arjun@user/arjun) (Ping timeout: 260 seconds)
10:22:29 <maerwald> stack puts all your packages into an sqlite database to do some insane "caching" though
10:24:15 <mechap> so neither stack nor cabal has a clean solution for uninstalling ?
10:27:56 × mizlan quits (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net) (Ping timeout: 246 seconds)
10:30:06 freeside_ joins (~mengwong@103.252.202.159)
10:31:31 × tzh quits (~tzh@c-24-21-73-154.hsd1.wa.comcast.net) (Quit: zzz)
10:31:36 <maerwald> correct
10:31:39 × chexum quits (~quassel@gateway/tor-sasl/chexum) (Quit: No Ping reply in 180 seconds.)
10:32:00 <maerwald> people are stuck in their current ways and workarounds that it's hard to consider what workflows actually make sense
10:32:16 × freeside quits (~mengwong@103.252.202.159) (Ping timeout: 272 seconds)
10:32:39 <maerwald> that's what gave rise to stack
10:32:54 <maerwald> so maybe cabal needs competition again
10:33:00 chexum joins (~quassel@gateway/tor-sasl/chexum)
10:33:08 <maerwald> I'd do it if I had more time
10:33:33 <maerwald> there were a few other attempts that died out
10:34:11 <maerwald> and if you "just" improve usability, that's not enough for anyone to get excited to do some funding
10:34:17 × econo quits (uid147250@user/econo) (Quit: Connection closed for inactivity)
10:35:04 <[exa]> maerwald: btw any specific ideas on what to do differently? (we're applying for very specific funding for this kind of stuff, might add it to the list)
10:35:04 <maerwald> given that cabal is becoming somewhat more modular, it may be more feasible though
10:35:40 <maerwald> [exa]: the first thing is to have a reasonable cli interface that's intuitive and where --help is not ludicrous
10:35:56 <maerwald> but the problem afair is that some of those flags come from Cabal (the library)
10:36:10 <maerwald> which can't add fancy dependencies
10:36:14 <maerwald> so it's a mush
10:36:36 <[exa]> that kinda implies making the API sane and then just expose it to cli, right?
10:36:48 <maerwald> yeah, more separated phases that make sense
10:36:50 <[exa]> "sane" as in "complete and well structured"
10:36:53 harveypwca joins (~harveypwc@2601:246:c180:a570:3828:d8:e523:3f67)
10:36:56 <maerwald> 'cabal configure' has weird semantics
10:37:14 <maerwald> then have consistent shell hooks for all phases
10:39:23 azimut joins (~azimut@gateway/tor-sasl/azimut)
10:39:31 <maerwald> https://github.com/haskell-mafia/mafia is one
10:39:34 <maerwald> there was another
10:40:11 <maerwald> (a more interesting one)
10:41:03 <[exa]> oh that's lovely
10:41:15 <[exa]> except yeah, last commit 3 years ago
10:41:23 <maerwald> none of them are usable
10:41:26 <[exa]> :(
10:42:17 mizlan joins (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net)
10:43:10 <freeside_> it would be fascinating to consider the *.hs and hackageas the only inputs to a build system, which then tries to solve package constraints based on import statements, and keeps trying to build until the build works
10:44:18 <[exa]> 10: "keep trying to build" 20: goto 10
10:45:38 <maerwald> ah
10:45:40 <maerwald> found it
10:45:42 <maerwald> https://github.com/judah/pier
10:46:19 <maerwald> "Pier invokes tools such as ghc directly, implementing the fine-grained Haskell build logic from (nearly) scratch. In contrast, Stack relies on a separate framework to implement most of its build steps (i.e., Cabal/Distribution.Simple), giving it mostly coarse control over the build"
10:46:35 <maerwald> this is true
10:46:44 <maerwald> the way cabal orders includes etc an be a nightmare
10:47:13 opticblast joins (~Thunderbi@secure-165.caltech.edu)
10:47:26 × Sgeo quits (~Sgeo@user/sgeo) (Read error: Connection reset by peer)
10:49:31 <maerwald> so most of the improvements won't really be "here's another feature"
10:51:33 <maerwald> and then pay duncan to implement that constraint algebra (he's been saying it's very easy...)
10:51:37 <maerwald> lol
10:52:03 <maerwald> except no one else knows exactly how easy
10:52:22 boxscape_ joins (~boxscape_@81.191.27.107)
10:55:42 × trev_ quits (~trev@109.252.35.99) (Quit: trev_)
10:55:55 trev_ joins (~trev@109.252.35.99)
10:56:22 trev_ is now known as trev
10:56:33 <freeside_> it's this easy: https://aphyr.com/posts/354-unifying-the-technical-interview
10:56:34 × trev quits (~trev@109.252.35.99) (Changing host)
10:56:34 trev joins (~trev@user/trev)
10:57:50 mncheckm joins (~mncheck@193.224.205.254)
10:58:31 × opticblast quits (~Thunderbi@secure-165.caltech.edu) (Remote host closed the connection)
10:59:54 arjun joins (~arjun@103.57.87.47)
11:00:45 instantaphex joins (~jb@c-73-171-252-84.hsd1.fl.comcast.net)
11:01:17 × Vajb quits (~Vajb@2001:999:405:5eb2:8d39:b832:a9ee:9bdf) (Ping timeout: 256 seconds)
11:01:33 Vajb joins (~Vajb@2001:999:78d:d7:457c:7773:573e:6903)
11:05:35 × instantaphex quits (~jb@c-73-171-252-84.hsd1.fl.comcast.net) (Ping timeout: 264 seconds)
11:15:04 × gnalzo quits (~gnalzo@2a01:e0a:498:fd50:fcc6:bb5d:489a:ce8c) (Quit: WeeChat 3.7.1)
11:17:14 × acidjnk_new quits (~acidjnk@p200300d6e715c40369f7e4f04255c339.dip0.t-ipconnect.de) (Ping timeout: 246 seconds)
11:19:32 vaibhavsagar[m] joins (~vaibhavsa@2001:470:69fc:105::ffe)
11:22:18 × azimut quits (~azimut@gateway/tor-sasl/azimut) (Remote host closed the connection)
11:22:44 azimut joins (~azimut@gateway/tor-sasl/azimut)
11:26:02 × arjun quits (~arjun@103.57.87.47) (Ping timeout: 268 seconds)
11:28:46 cheater_ joins (~Username@user/cheater)
11:30:36 MajorBiscuit joins (~MajorBisc@2001:1c00:2402:2d00:9eeb:34cf:63b3:9e5b)
11:31:32 × cheater quits (~Username@user/cheater) (Ping timeout: 252 seconds)
11:31:32 arjun joins (~arjun@103.57.87.47)
11:31:42 cheater_ is now known as cheater
11:34:37 × shriekingnoise quits (~shrieking@186.137.175.87) (Quit: Quit)
11:35:52 emmanuelux joins (~emmanuelu@user/emmanuelux)
11:42:34 instantaphex joins (~jb@c-73-171-252-84.hsd1.fl.comcast.net)
11:44:28 × mizlan quits (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net) (Ping timeout: 272 seconds)
11:44:32 × Kaipei quits (~Kaiepi@nwcsnbsc03w-47-55-159-86.dhcp-dynamic.fibreop.nb.bellaliant.net) (Ping timeout: 246 seconds)
11:45:00 accord joins (uid568320@id-568320.hampstead.irccloud.com)
11:47:00 × instantaphex quits (~jb@c-73-171-252-84.hsd1.fl.comcast.net) (Ping timeout: 268 seconds)
11:50:11 thyriaen joins (~thyriaen@2a01:aea0:dd4:4bae:6245:cbff:fe9f:48b1)
11:52:37 × emmanuelux quits (~emmanuelu@user/emmanuelux) (Quit: au revoir)
11:53:37 × hgolden quits (~hgolden@cpe-172-251-233-141.socal.res.rr.com) (Remote host closed the connection)
11:54:00 Kaipei joins (~Kaiepi@nwcsnbsc03w-47-55-159-86.dhcp-dynamic.fibreop.nb.bellaliant.net)
11:57:19 hgolden joins (~hgolden@cpe-172-251-233-141.socal.res.rr.com)
12:00:28 tremon joins (~tremon@83-85-213-108.cable.dynamic.v4.ziggo.nl)
12:04:10 beteigeuze joins (~Thunderbi@bl14-81-220.dsl.telepac.pt)
12:05:01 jakalx parts (~jakalx@base.jakalx.net) ()
12:07:16 <Athas> I need a parametric Void, that is the empty type 'data Void2 a'. Does this have a standard name.
12:07:35 <Athas> A void functor.
12:07:48 <tomsmeding> Isn't that Const Void
12:08:03 <tomsmeding> Well, not quite maybe
12:08:18 <Athas> I need something of kind * -> *. Const Void has kind *.
12:08:42 <Athas> Or wait, maybe you're right.
12:09:02 <Athas> Where is the Const type defined?
12:09:10 <tomsmeding> Data.Functor.Const from base
12:09:39 <tomsmeding> It has a constructor though -- just one with, in this case, a void field
12:09:55 <tomsmeding> Not sure if that makes it unsuitable for your usecase
12:10:15 <Athas> Hm, and I guess that values of that constructor could exist, since all nonstrict types are inhabited.
12:10:32 <tomsmeding> Isn't it a newtype?
12:10:46 <Athas> Oh yes. Is the exhaustiveness checker smart enough to deal with this?
12:11:00 <tomsmeding> 🤷‍♂️ :p
12:12:30 <jackdk> There's a `Void1` in generic-lens-core` but I don't think there's a canonical one anywhere
12:13:37 mizlan joins (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net)
12:14:10 dcoutts joins (~duncan@host213-122-143-153.range213-122.btcentralplus.com)
12:16:24 × dcoutts_ quits (~duncan@host86-151-44-212.range86-151.btcentralplus.com) (Ping timeout: 260 seconds)
12:16:35 titibandit1 joins (~titibandi@xdsl-87-78-235-220.nc.de)
12:18:20 × mizlan quits (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net) (Ping timeout: 265 seconds)
12:20:09 alfonsox joins (~quassel@103.87.57.65)
12:27:00 jakalx joins (~jakalx@base.jakalx.net)
12:27:29 × hgolden quits (~hgolden@cpe-172-251-233-141.socal.res.rr.com) (Ping timeout: 260 seconds)
12:28:43 jinsun joins (~jinsun@user/jinsun)
12:32:03 mizlan joins (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net)
12:33:28 <[exa]> Athas: btw what's the usecase? (just curions; in all I can see I'd probably just go with Proxy)
12:34:41 <Athas> [exa]: a type is parameterised on multiple functors, and sometimes I want some of them to produce Void (indicating that certain branches of a sum type are invalid).
12:35:06 <Athas> It's for a compiler AST; somewhat similar to the Trees That Grow idea, if you're familiar with that.
12:36:01 <[exa]> aaaah yes so you basically need both the emptiness and the functorish argument at once. At that point yeah, it's Void1.
12:36:31 instantaphex joins (~jb@c-73-171-252-84.hsd1.fl.comcast.net)
12:37:51 <MangoIV[m]> <Athas> "Oh yes. Is the exhaustiveness..." <- The exhaustive mess checker is smart enough to deal with strict voids, yes.
12:38:06 <MangoIV[m]> Doesn’t even need to be a new type, strict data is enough.
12:42:06 × instantaphex quits (~jb@c-73-171-252-84.hsd1.fl.comcast.net) (Ping timeout: 272 seconds)
12:42:44 <MangoIV[m]> There’s a good blogpost on this topic. It’s called “to void or to Void?”
12:48:50 × boxscape_ quits (~boxscape_@81.191.27.107) (Ping timeout: 260 seconds)
12:49:47 × troydm quits (~troydm@user/troydm) (Quit: What is Hope? That all of your wishes and all of your dreams come true? To turn back time because things were not supposed to happen like that (C) Rau Le Creuset)
12:50:17 troydm joins (~troydm@user/troydm)
12:54:25 instantaphex joins (~jb@c-73-171-252-84.hsd1.fl.comcast.net)
12:54:59 thongpv87 joins (~thongpv87@2402:9d80:384:79a2:a6b7:db5b:a5f5:6571)
12:57:20 × thongpv quits (~thongpv87@2001:ee0:54ae:93a0:55a8:a4c7:8b73:21a9) (Ping timeout: 252 seconds)
12:59:12 × instantaphex quits (~jb@c-73-171-252-84.hsd1.fl.comcast.net) (Ping timeout: 272 seconds)
13:01:09 × MajorBiscuit quits (~MajorBisc@2001:1c00:2402:2d00:9eeb:34cf:63b3:9e5b) (Quit: WeeChat 3.6)
13:04:31 __monty__ joins (~toonn@user/toonn)
13:12:53 × __monty__ quits (~toonn@user/toonn) (Quit: leaving)
13:13:17 × gmg quits (~user@user/gehmehgeh) (Quit: Leaving)
13:15:35 __monty__ joins (~toonn@user/toonn)
13:17:17 × arjun quits (~arjun@103.57.87.47) (Ping timeout: 256 seconds)
13:28:24 machinedgod joins (~machinedg@d198-53-218-113.abhsia.telus.net)
13:29:08 merijn joins (~merijn@86-86-29-250.fixed.kpn.net)
13:31:50 arjun joins (~arjun@103.57.87.47)
13:34:20 × mizlan quits (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net) (Ping timeout: 260 seconds)
13:40:24 cheater_ joins (~Username@user/cheater)
13:41:04 fizbin joins (~fizbin@user/fizbin)
13:41:18 × bitdex quits (~bitdex@gateway/tor-sasl/bitdex) (Remote host closed the connection)
13:41:21 bitdex_ joins (~bitdex@gateway/tor-sasl/bitdex)
13:42:53 × cheater quits (~Username@user/cheater) (Ping timeout: 252 seconds)
13:42:59 cheater_ is now known as cheater
13:43:10 <arjun> :kind Int shows "*" even after switching on -StarIsType ext.
13:43:44 <arjun> do we need to do more to make "*" a "Type" ?
13:43:52 <tomsmeding> arjun: you need the opposite, -XNoStarIsType
13:44:27 <tomsmeding> to GHC, Type is the actual thing, * is just a convenient representation that it uses when -XStarIsType is set (which it is by default)
13:44:47 <tomsmeding> ("convenient" is subjective, of course)
13:45:15 <arjun> tomsmeding, SMH, thanks!
13:45:56 <arjun> also, if i have typeOperators enabled, i can't do (1 + 3) Type 4, (using Type as a *, multiplication) ?
13:46:15 <tomsmeding> :') no
13:46:45 <tomsmeding> it's more the other way round: with -XStarIsType, using * as multiplication can give trouble (I forget exactly how much trouble)
13:46:46 <arjun> but i need -XNoStarIsType to do a type level multiplication ( * ) using a star, i see.
13:46:52 <tomsmeding> right
13:49:17 × fizbin quits (~fizbin@user/fizbin) (Ping timeout: 255 seconds)
13:49:55 <arjun> thanks for clearing that up tomsmeding : )
13:51:08 × merijn quits (~merijn@86-86-29-250.fixed.kpn.net) (Ping timeout: 272 seconds)
13:51:46 <Benzi-Junior> Ok I'm getting the following error when using 'get' from the Control.Monad.StateT.Strict "Couldn't match type ‘StateT TodoList m0’ with ‘StateT TodoList IO Ind’"
13:54:06 <arjun> Benzi-Junior, did you use a IO function? that fixes m to IO but your type signature probably has "m". try using a liftIO before the IO action ?
13:54:12 gnalzo joins (~gnalzo@2a01:e0a:498:fd50:fcc6:bb5d:489a:ce8c)
13:59:02 <Benzi-Junior> arjun, the call is simply "l <- get" it is made in a do block for a function with the signature "StateT TodoList IO Ind
13:59:38 × jmdaemon quits (~jmdaemon@user/jmdaemon) (Ping timeout: 255 seconds)
13:59:50 <Axman6> we'd need to see more code to have any idea what's going on
14:00:30 <Axman6> those two types mentioned have different kinds, so something quite strange is going on
14:02:31 × slack1256 quits (~slack1256@186.11.40.220) (Remote host closed the connection)
14:02:35 merijn joins (~merijn@c-001-001-016.client.esciencecenter.eduvpn.nl)
14:04:29 mizlan joins (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net)
14:07:44 jao joins (~jao@cpc103048-sgyl39-2-0-cust502.18-2.cable.virginm.net)
14:08:13 × merijn quits (~merijn@c-001-001-016.client.esciencecenter.eduvpn.nl) (Ping timeout: 268 seconds)
14:09:13 × mizlan quits (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net) (Ping timeout: 260 seconds)
14:10:13 merijn joins (~merijn@c-001-001-016.client.esciencecenter.eduvpn.nl)
14:11:09 × mechap quits (~mechap@user/mechap) (Quit: WeeChat 3.7.1)
14:18:41 × Ranhir quits (~Ranhir@157.97.53.139) (Read error: Connection reset by peer)
14:22:13 mizlan joins (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net)
14:22:55 Ranhir joins (~Ranhir@157.97.53.139)
14:29:02 <Benzi-Junior> Axman6, sounds like I'm barking up the wrong tree
14:29:14 razetime joins (~Thunderbi@49.207.222.244)
14:30:25 × merijn quits (~merijn@c-001-001-016.client.esciencecenter.eduvpn.nl) (Ping timeout: 268 seconds)
14:31:45 × tromp quits (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
14:32:32 eggplantade joins (~Eggplanta@2600:1700:38c5:d800:9c06:575b:efcb:5bf)
14:33:07 thongpv joins (~thongpv87@2001:ee0:54ae:93a0:9660:d17:ac3f:e790)
14:34:29 cheater_ joins (~Username@user/cheater)
14:34:31 × thongpv87 quits (~thongpv87@2402:9d80:384:79a2:a6b7:db5b:a5f5:6571) (Ping timeout: 260 seconds)
14:34:48 <Axman6> Benzi-Junior: well, like I said, we have no idea what's wrong because you haven't given us enough information to help
14:35:07 dsfdfs joins (~dsfdfs@2405:201:c039:9062:68fa:1064:6d2b:6df)
14:35:32 thongpv87 joins (~thongpv87@14.160.124.248)
14:35:37 × dsfdfs quits (~dsfdfs@2405:201:c039:9062:68fa:1064:6d2b:6df) (Client Quit)
14:36:44 × eggplantade quits (~Eggplanta@2600:1700:38c5:d800:9c06:575b:efcb:5bf) (Ping timeout: 246 seconds)
14:37:53 × cheater quits (~Username@user/cheater) (Ping timeout: 255 seconds)
14:37:54 cheater_ is now known as cheater
14:38:03 × thongpv quits (~thongpv87@2001:ee0:54ae:93a0:9660:d17:ac3f:e790) (Ping timeout: 248 seconds)
14:38:13 mechap joins (~mechap@user/mechap)
14:39:29 × titibandit1 quits (~titibandi@xdsl-87-78-235-220.nc.de) (Quit: Leaving.)
14:40:03 <Benzi-Junior> Axman6, this is something I'm being assessed on so I want to avoid uploading the code in its entierty, I'll be in touch again if my position changes
14:41:18 × harveypwca quits (~harveypwc@2601:246:c180:a570:3828:d8:e523:3f67) (Quit: Leaving)
14:48:34 Sciencentistguy9 joins (~sciencent@hacksoc/ordinary-member)
14:50:35 × Sciencentistguy quits (~sciencent@hacksoc/ordinary-member) (Ping timeout: 264 seconds)
14:52:44 × ddellacosta quits (~ddellacos@89.45.224.152) (Ping timeout: 260 seconds)
14:53:38 × Sciencentistguy9 quits (~sciencent@hacksoc/ordinary-member) (Ping timeout: 255 seconds)
14:58:58 × leah2 quits (~leah@vuxu.org) (Remote host closed the connection)
15:01:18 leah2 joins (~leah@vuxu.org)
15:10:38 merijn joins (~merijn@c-001-001-016.client.esciencecenter.eduvpn.nl)
15:17:55 × sammelweis quits (~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10) (Quit: No Ping reply in 180 seconds.)
15:19:04 sammelweis joins (~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10)
15:23:23 × mizlan quits (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net) (Ping timeout: 248 seconds)
15:34:09 × merijn quits (~merijn@c-001-001-016.client.esciencecenter.eduvpn.nl) (Ping timeout: 260 seconds)
15:44:59 wroathe joins (~wroathe@207-153-38-140.fttp.usinternet.com)
15:44:59 × wroathe quits (~wroathe@207-153-38-140.fttp.usinternet.com) (Changing host)
15:44:59 wroathe joins (~wroathe@user/wroathe)
15:47:39 ddellacosta joins (~ddellacos@89.45.224.152)
15:48:16 <Benzi-Junior> ok here is my code -> https://pastebin.com/65J3Tzmd
15:48:31 <Benzi-Junior> I suspect the isse to be simple and fundamental
15:50:46 <c_wraith> Benzi-Junior: the type is wrong
15:51:12 <c_wraith> Benzi-Junior: you're treating TLM as if it was a type synonym, but it isn't. It's a newtype
15:52:37 mizlan joins (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net)
15:52:40 <Benzi-Junior> I suspected as much, could you elaborate briefly what the difference is ?
15:53:22 <c_wraith> Benzi-Junior: and after that, you're using both gets and putStrLn in the same do block, which won't work. putStrLn returns an IO value, and gets returns a StateT value, and the two aren't compatible
15:53:23 tromp joins (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
15:54:01 <c_wraith> Benzi-Junior: at a first level, think of a newtype as a special case data declaration with exactly one constructor.
15:54:45 <Benzi-Junior> c_wraith, ye just looked it up, the putStrLn was just there to force it to be an IO,
15:55:11 <Benzi-Junior> c_wraith, so I guess I need to unwrap the TLM constructor to get this to work ?
15:55:31 <c_wraith> Other way around. You need to wrap the result in a TLM constructor.
15:56:21 <c_wraith> and to use putStrLn, you need to make its result line up with `StateT something IO ()`
15:56:36 <c_wraith> for that, look at the `liftIO' function
15:59:19 thongpv joins (~thongpv87@2402:9d80:34a:6d5:496e:abe7:cc2:fa15)
15:59:21 <Benzi-Junior> c_wraith, I had looked into liftIO, itdidn't seem to be included in the setup and I suspect I'm not supposed to add it, but also printing wasn't part of the specification (or rather it's supposed to happen elsewhere in code)
16:00:23 <c_wraith> Well, it's part of MonadIO. So it's definitely in there.
16:01:02 × thongpv87 quits (~thongpv87@14.160.124.248) (Ping timeout: 252 seconds)
16:01:33 <c_wraith> It's definitely in scope and you're supposed to be aware of it. But if you don't need to do the output there, the TLM constructor should still force inference of IO
16:02:39 × panovia quits (~user@user/siracusa) (Quit: Bye!)
16:05:48 × mizlan quits (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net) (Remote host closed the connection)
16:06:33 mizlan joins (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net)
16:08:02 <Benzi-Junior> c_wraith, I'll keep it in mind
16:15:55 merijn joins (~merijn@c-001-001-016.client.esciencecenter.eduvpn.nl)
16:19:13 <Benzi-Junior> umm there must be something I'm not getting, unless I'm supposed to put the constructor around the entire do block
16:20:20 × merijn quits (~merijn@c-001-001-016.client.esciencecenter.eduvpn.nl) (Ping timeout: 246 seconds)
16:20:29 <c_wraith> where else would it go?
16:20:40 <tomsmeding> or around the 'gets nextIndex', right?
16:21:55 <c_wraith> the argument to TLM is a `StateT TL IO I' value. And in this case, that whole do block happens to be one of those.
16:22:10 × ddellacosta quits (~ddellacos@89.45.224.152) (Ping timeout: 252 seconds)
16:22:21 <c_wraith> (remember, do blocks are expressions)
16:22:22 <Benzi-Junior> huh, ok
16:22:40 <Benzi-Junior> ye it just seemed ... wrong to do
16:23:33 <tomsmeding> Benzi-Junior: you can also put TLM around the 'gets nextIndex'
16:23:53 <tomsmeding> if you put TLM around the entire do block, you're working in the StateT monad, and wrapping the computation in TLM
16:24:14 <Benzi-Junior> tomsmeding, I tried that first but it didn't work
16:24:17 <tomsmeding> if you put TLM around just the gets call, you're working in the TLM monad, where `TLM (gets nextIndex)` is an operation in the TLM monad (constructed from an operation in the StateT monad)
16:24:22 <Benzi-Junior> tomsmeding, but you are correct
16:24:32 <tomsmeding> Benzi-Junior: https://play-haskell.tomsmeding.com/saved/QgIGNqFK
16:24:33 <tomsmeding> works :p
16:24:37 <tomsmeding> as in, compiles
16:24:55 <Benzi-Junior> I retried it and now it works, I must havemade some other error when I first tried it
16:25:50 <Benzi-Junior> tomsmeding, but what would be the dissadvantage of wrapping up the whole block ?
16:26:08 <tomsmeding> Benzi-Junior: in this case none
16:26:20 <tomsmeding> though I'd assume that in a larger application, you have other methods that also run im the TLM monad
16:26:45 <tomsmeding> you can't use TLM methods inside a StateT do block, but you can use StateT methods inside a TLM do block (by wrapping the TLM constructor around them)
16:27:13 <c_wraith> Or ideally by adding a MonadState instance for TLM, but that might be out of scope for the project
16:27:28 <tomsmeding> (now, technically you can, because you can write `case x of TLM m -> m` and extract the StateT computation, but that's typically not the intent if you're writing the newtype in the first place)
16:27:45 <tomsmeding> and what c_wraith says, then the gets call would get lifted automatically
16:28:13 <c_wraith> though I suspect it might be importing StateT directly from transformers, instead of using mtl
16:28:19 <c_wraith> just to prevent that sort of thing
16:28:29 <tomsmeding> hm true
16:28:46 wootehfoot joins (~wootehfoo@user/wootehfoot)
16:31:54 × Kaipei quits (~Kaiepi@nwcsnbsc03w-47-55-159-86.dhcp-dynamic.fibreop.nb.bellaliant.net) (Ping timeout: 268 seconds)
16:33:22 <Benzi-Junior> also, I've asked this before but forgot the answer, what is the signifcance of the '!' preceding the types in the declaration of TItem
16:33:35 <tomsmeding> they are strict fields
16:33:56 <tomsmeding> % data A = A Int ; data B = B !Int
16:33:56 <yahb2> <no output>
16:34:03 <tomsmeding> % A undefined `seq` ()
16:34:03 <yahb2> ()
16:34:05 eggplantade joins (~Eggplanta@2600:1700:38c5:d800:9c06:575b:efcb:5bf)
16:34:06 <tomsmeding> % B undefined `seq` ()
16:34:06 <yahb2> *** Exception: Prelude.undefined ; CallStack (from HasCallStack): ; error, called at libraries/base/GHC/Err.hs:74:14 in base:GHC.Err ; undefined, called at <interactive>:24:3 in interactive:Ghci5
16:34:45 <c_wraith> when the constructor is evaluated, those fields will also be evaluated (to WHNF). Note the first clause there. They don't magically cause evaluation when the constructor is applied, only when it's evaluated.
16:34:45 × eggplantade quits (~Eggplanta@2600:1700:38c5:d800:9c06:575b:efcb:5bf) (Remote host closed the connection)
16:35:01 eggplantade joins (~Eggplanta@2600:1700:38c5:d800:9c06:575b:efcb:5bf)
16:37:17 pagnol joins (~user@213-205-209-87.ftth.glasoperator.nl)
16:37:19 pagnol parts (~user@213-205-209-87.ftth.glasoperator.nl) (ERC (IRC client for Emacs 27.1))
16:37:57 <tomsmeding> % let x = B undefined in ()
16:37:57 <yahb2> ()
16:41:00 × mechap quits (~mechap@user/mechap) (Ping timeout: 260 seconds)
16:42:42 mechap joins (~mechap@user/mechap)
16:44:24 ddellacosta joins (~ddellacos@86.106.143.243)
16:49:40 <monochrom> My http://www.vex.net/~trebla/haskell/strict-field.xhtml explains it.
16:55:49 jinsun__ joins (~jinsun@user/jinsun)
16:55:49 × jinsun quits (~jinsun@user/jinsun) (Killed (zinc.libera.chat (Nickname regained by services)))
16:55:49 jinsun__ is now known as jinsun
16:56:02 × mizlan quits (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net) (Ping timeout: 246 seconds)
17:08:00 jil joins (~user@vps-15050500.vps.ovh.net)
17:08:07 <jil> Hi
17:08:11 <Benzi-Junior> hullo
17:08:26 <[exa]> good evening
17:09:45 <jil> I'm trying to lean Haskell from the Hutton's Book Programming in Haskell. I started 2 years ago. It went well up to chapter 11
17:10:31 <jil> where he illustrate the first half of the book by developping an interactive tic-tac-toe program.
17:11:09 × thongpv quits (~thongpv87@2402:9d80:34a:6d5:496e:abe7:cc2:fa15) (Ping timeout: 252 seconds)
17:11:10 <jil> He always give some exercices to do I up to now I did all of them even those not corrected
17:12:05 <jil> But for several month now, I don't see how I can introduce some randomness in the selection of the tictactoe grid without poluting all the code with IO
17:12:30 <jil> the author suggest to use RandomRIO
17:13:01 <[exa]> jil: you will generally need to carry _some_ random generator state to places where you want to generate random numbers, but there are certainly far better options that with IO
17:13:56 <[exa]> jil: at the bare minimum you can use a State to pass the random seed around instead of IO
17:13:56 L29Ah joins (~L29Ah@wikipedia/L29Ah)
17:14:16 × wootehfoot quits (~wootehfoo@user/wootehfoot) (Read error: Connection reset by peer)
17:14:43 <monochrom> You can use newStdGen in IO and then randomRs without IO, the latter gives you an infinite stream.
17:15:00 <jil> we use the minmax algorithm to tag the tree of possible grid position. At some point we generate a list a all the wining move and take the first one.
17:15:21 <jil> What I need is "just" take a random one from the list
17:15:50 <jil> I would like to do it with the suggested function randomRIO
17:16:17 × L29Ah quits (~L29Ah@wikipedia/L29Ah) (Read error: Connection reset by peer)
17:16:41 <jil> what you are suggesting [exa] is to use some other random function right ?
17:17:09 merijn joins (~merijn@c-001-001-016.client.esciencecenter.eduvpn.nl)
17:17:28 <jil> Maybe someone knows the book or the author and could tell me why he suggested to use randomRIO if there are other simpler solution ?
17:17:49 <jil> Can I show my code ?
17:19:23 × mechap quits (~mechap@user/mechap) (Ping timeout: 260 seconds)
17:19:47 hgolden joins (~hgolden@cpe-172-251-233-141.socal.res.rr.com)
17:20:22 <[exa]> jil: pastebin link in /topic :]
17:21:05 mechap joins (~mechap@user/mechap)
17:22:10 <monochrom> I wouldn't say "simpler". The other approaches aim at minimizing dependence on IO. That does not mean simpler.
17:23:39 <monochrom> I believe that Hutton chose to stay in IO with randomRIO because considering the context of what the book has taught so far and where randomness is needed in this particular program, randomRIO causes the least distraction.
17:27:50 × alfonsox quits (~quassel@103.87.57.65) (Quit: https://quassel-irc.org - Chat comfortably. Anywhere.)
17:28:08 × ddellacosta quits (~ddellacos@86.106.143.243) (Ping timeout: 260 seconds)
17:28:17 boxscape_ joins (~boxscape_@81.191.27.107)
17:28:47 <jil> I need to do something starting in function best_rnd_move : 126 https://paste.tomsmeding.com/GQwM69T2
17:28:50 <monochrom> You can also get a glimpse from the preface or introduction that he is going to embrace IO rather than obsess over purity.
17:28:51 <boxscape_> I just published a plugin to bring Idris's !-notation into Haskell, curious what people think https://hackage.haskell.org/package/monadic-bang-0.1.0.0
17:29:55 <jil> monochrom: so I should go with putting a lot of IO in the code. I don't really mind as it's probably for a didactical purpose
17:30:36 <jil> If I'm correct I'll have to change all my Grid type in 'IO Grid'
17:30:56 <[exa]> jil: in your case you're using the best_rnd_move only in 1 function
17:31:50 <[exa]> ...in play', which is already IO. So you can just change the best_rnd_move to type `best_rnd_move :: Grid -> Player -> IO Grid`, add the return, bind the result correctly in play', and that should be it, you can rng there :]
17:32:37 <[exa]> re "all my Grid types to `IO Grid`" -- no, only the "return" ones, as above
17:33:08 boxscape_14 joins (~boxscape_@81.191.27.107)
17:33:13 boxscape_14 is now known as boxscape__
17:33:32 × razetime quits (~Thunderbi@49.207.222.244) (Remote host closed the connection)
17:35:16 × tromp quits (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
17:36:14 <jil> What I tried to do was something like list !! (Rnd.RandomRIO (0, lenght list) :: IO Int) but soon found that will not work because of the IO, So I tried without success to use a `do index <- (Rnd.RandomRIO (0, lenght list) :: IO Int)` somewhere in the best_rnd_move.
17:36:39 × boxscape_ quits (~boxscape_@81.191.27.107) (Ping timeout: 268 seconds)
17:37:34 tromp joins (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
17:37:36 <[exa]> yes, you need to "bind" the results of IO actions to be able to access the value they return
17:37:54 <jil> bind is using the do and the <- right ?
17:37:57 <[exa]> (either using <- in `do` notation or the >>= outside of it)
17:37:58 <[exa]> yes
17:38:30 <jil> I've not ssen the >>=.
17:39:57 <[exa]> <- in `do` internally rewrites to >>=, which is the actual operator that powers the binding of the values
17:41:31 mizlan joins (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net)
17:42:35 × merijn quits (~merijn@c-001-001-016.client.esciencecenter.eduvpn.nl) (Ping timeout: 260 seconds)
17:43:02 instantaphex joins (~jb@c-73-171-252-84.hsd1.fl.comcast.net)
17:44:17 <jil> I don't quite get it, because if I don't understand how the state of the world is tracked in this code https://paste.tomsmeding.com/bhnjk44F#file-2
17:44:30 <jil> Also the syntaxe is probably incorrect
17:44:34 boxscape__ is now known as boxscape_
17:45:05 × arjun quits (~arjun@103.57.87.47) (Ping timeout: 255 seconds)
17:47:02 <[exa]> jil: okay, the best_rnd_move needs to return an IO action (that produces a Grid), but you return a grid. You will need `return`
17:47:49 <[exa]> btw, do you know some of the intuition behind monads and how they compose to form bigger programs?
17:48:07 <[exa]> :t return -- <- jil
17:48:08 <lambdabot> Monad m => a -> m a
17:48:42 <jil> there like carrying the state of the world around ?
17:48:53 <jil> they are like...
17:51:07 <[exa]> yes, IO does precisely that (there are other monads that do other things but let's ignore that now)
17:51:28 merijn joins (~merijn@c-001-001-016.client.esciencecenter.eduvpn.nl)
17:51:48 econo joins (uid147250@user/econo)
17:54:52 × tromp quits (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
17:55:51 <[exa]> jil: I made an illustration here https://paste.tomsmeding.com/Cg940cSU hopefully it shows all the necessary steps
17:56:02 <[exa]> (didn't try it though, pls report if it fails to compile or so :D )
17:56:13 × merijn quits (~merijn@c-001-001-016.client.esciencecenter.eduvpn.nl) (Ping timeout: 252 seconds)
17:56:31 <freeside_> "Beware of bugs in the above code; I have only proved it correct, not tried it." -- Knuth
18:00:10 <[exa]> jil: notably, `do` takes multiple descriptions of IO actions and joins them into one (while handling some of the other things correctly, like the result of one action getting collected with <- and being usable in other actions). Also, integers are not IO (thus they can't be easily used in `do`), but you can construct a trivial IO that's just going to have the integer you give it as a result, using `return`.
18:01:45 <[exa]> This way, you basically build a yuge IO out of all small IOs in your program, which becomes your `main`. Haskell runtime then reads and runs all of these to get the whole thing moving.
18:04:27 × accord quits (uid568320@id-568320.hampstead.irccloud.com) (Quit: Connection closed for inactivity)
18:04:30 <[exa]> (it technically doesn't "read and run" them because the program gets compiled to very efficient machine code, but this "interpret the IO description" logic is moreless retained)
18:04:53 fizbin joins (~fizbin@user/fizbin)
18:06:22 coot joins (~coot@2a02:a310:e241:1b00:ec1a:e9df:79ac:66ba)
18:06:50 arjun joins (~arjun@103.57.87.47)
18:07:06 <jil> I'm reading you again... :)
18:10:12 <[exa]> btw try to make sense of the types of things in the small example, that's probably the best way
18:11:00 <[exa]> also also, just to clarify `do` notation: it rewrites to >> and >>=, where `do {a; b}` is basically equivalent to `a>>b`:
18:11:29 <[exa]> :t print 123
18:11:31 <lambdabot> IO ()
18:11:43 <[exa]> :t do {print 123; print 123; }
18:11:45 <lambdabot> IO ()
18:12:00 <iqubic> Hackage's new dark mode is super amazing!
18:12:04 <[exa]> :t print 123 >> print 123 -- >> is kinda like a semicolon here
18:12:06 <lambdabot> IO ()
18:12:16 <jil> ok... I'm trying this `ghci>let x = 0` `ghci>:t x` Num a => a
18:12:45 <jil> vs `x <- return 0` `:t x` x :: Integer
18:12:53 <[exa]> jil: ...and binding translates to >>=, `do {result <- a; b result;}` becomes `a >>= (\result -> b result)`
18:13:17 emmanuelux joins (~emmanuelu@user/emmanuelux)
18:13:26 <jil> you are loosing me [exa]
18:13:33 × emmanuelux quits (~emmanuelu@user/emmanuelux) (Remote host closed the connection)
18:13:45 <[exa]> in your case, you may assume that `<-` temporarily strips the IO from the computations so that you can access the actual value, but the whole result must again be an IO
18:13:59 <jil> I'm trying to keep to my objective, drawing a random element from the list of wining grids
18:14:07 <[exa]> ah ok :]
18:15:09 × perrierjouet quits (~perrier-j@modemcable048.127-56-74.mc.videotron.ca) (Ping timeout: 260 seconds)
18:15:11 <jil> I think I go that .. <- temprarily strips the IO but I need to add it to my whole result
18:15:54 <[exa]> anyway, regarding your attempt, the main problem there was probably that the `do` in best_rnd_move was misplaced, you want to have the `do` as the top element in the funtion so that it can connect the randomRIO to the rest of the function
18:16:04 <jil> why the different type in `x <- return 0` and `let x = 0` ?
18:17:21 <[exa]> ah, the type actually _should_ be the same but you got hit by defaulting
18:17:30 <boxscape_> I'd argue that's a quirk of ghci more so than a property of Haskell
18:17:41 <jil> [exa]: yes, I got that I had made another attemp like this, but still not perfect https://paste.tomsmeding.com/V3c8r3YB#file-1
18:17:53 <[exa]> ...you can try with `x <- return 'a'` -- Char's typically do not suffer from Num problems.
18:17:57 <jil> ok thank you
18:18:13 <jil> yes, I checked for the Char and it was ok
18:18:15 tzh joins (~tzh@c-24-21-73-154.hsd1.wa.comcast.net)
18:18:45 caryhartline joins (~caryhartl@2600:1700:2d0:8d30:31be:b9b2:d1e5:a2dd)
18:18:46 <jil> I don't know where to place the return in my code
18:18:50 <[exa]> jil: one hint, with `do` you can have inline `let` instead of the `where`
18:19:03 <[exa]> other than that it looks correct to me
18:19:08 <[exa]> what's the compiler complaining about?
18:19:30 <boxscape_> looks like the where is indented too far
18:19:37 <[exa]> likely
18:19:55 <freeside_> wherefar art thou, helper function
18:21:06 <[exa]> no idea how to type this nicely to IRC so I just fixed it: https://paste.tomsmeding.com/8sjFkf5k
18:21:26 <[exa]> this form of `let` in do-notation is quite convenient (notice there's no `in`)
18:22:23 <[exa]> also also, I guess that at this point the compiler should be able to see that `indice` needs to be an Int, so the `:: IO Int` annotation is probably redundant
18:24:52 <jil> ok, I had repeated the let three times. your code is clearer. When I compile I get error of miss matching Grid (actual) with expected IO Grid.
18:25:44 <[exa]> jil: is the error pointing at this function or into play' ?
18:25:50 <jil> When I folow the thread I going to find myself having to build Tree of IO Grid
18:26:27 <[exa]> ah no, you shouldn't put IO into data structures
18:26:35 perrierjouet joins (~perrier-j@modemcable048.127-56-74.mc.videotron.ca)
18:26:38 <[exa]> (well you can, but it doesn't make much sense usually)
18:26:39 <jil> play, then play' then my empty type then best_rnd_move
18:27:25 <freeside_> if you ever find yourself holding a Container of IO Something, when you really want an IO of Container Something, use `sequence` to get yourself out of that jam
18:27:54 <[exa]> the way to "carry" the IO into functions is to allow them to return their result with the "extra IO description", usually by putting the IO before the return type
18:28:24 <jil> ok, we have seen sequence in precending chapter.
18:28:26 <[exa]> jil: can you quickly paste the current code + the error message?
18:28:48 × arjun quits (~arjun@103.57.87.47) (Quit: Quit!)
18:30:19 × mizlan quits (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net) (Ping timeout: 260 seconds)
18:32:57 emmanuelux joins (~emmanuelu@user/emmanuelux)
18:33:32 epolanski joins (uid312403@id-312403.helmsley.irccloud.com)
18:33:44 <jil> https://paste.tomsmeding.com/ed6loKNo
18:34:39 waleee joins (~waleee@2001:9b0:213:7200:cc36:a556:b1e8:b340)
18:34:57 <jil> if I change the input Grid to IO Grid in best_rnd_move I'll have to change it in my tree.
18:35:08 <jil> right ?
18:35:31 mizlan joins (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net)
18:35:32 <jil> unless I find a way to use sequence as freeside_ suggested.
18:35:36 <[exa]> jil: but why would you do that?
18:36:01 <monochrom> Forget sequence. Bland overgeneralized distracting suggestion.
18:36:12 <freeside_> sorry
18:36:41 haritz joins (~hrtz@82-69-11-11.dsl.in-addr.zen.co.uk)
18:36:42 × haritz quits (~hrtz@82-69-11-11.dsl.in-addr.zen.co.uk) (Changing host)
18:36:42 haritz joins (~hrtz@user/haritz)
18:36:42 <[exa]> jil: first, `empty` doesn't need to be IO Grid, just Grid. There's no reason it would use IO actions (unless you want to randomize it later, which we can do later)
18:37:05 <[exa]> there's no more problems with best_rnd_move now!
18:37:12 <monochrom> best_rnd_move is not wrong. But it has changed. Change how play' uses it.
18:37:21 merijn joins (~merijn@c-001-001-016.client.esciencecenter.eduvpn.nl)
18:37:25 <[exa]> +1 ^
18:37:33 <jil> but play need an IO Grid and I call play empty
18:37:53 <monochrom> Basically it's the equivalent of "putChar $! getChar" (which is wrong) vs "c <- getChar" then "putChar c".
18:38:09 <[exa]> jil: that's okay, the argument of `play` should not be IO too
18:38:40 <[exa]> jil: generally, IO as an argument means that you're making some kind of IO transformers (IO actions that modify other IO actions), and we're really not there. :]
18:38:47 <jil> ok, so I need to extract the Grid from the IO Grid returned by best_rnd_move
18:39:04 <[exa]> yes, which is done by running the best_rnd_move "alone" and getting a IO-less result by <-
18:39:10 <jil> ok
18:39:59 × mizlan quits (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net) (Ping timeout: 255 seconds)
18:40:09 <jil> hurray !! :)
18:40:13 <jil> Thank you
18:40:18 <[exa]> (note about IO in arguments: it may be tempting to "help" it by taking the string of IO actions there, but that's not the case here -- you really just produce "descriptions" of what the program should do)
18:40:30 <monochrom> Personally I would start by addressing the elephant in the room.
18:40:51 <[exa]> Int = an integer, IO Int = a description of some IO to do to eventually produce an Integer
18:40:51 [itchyjunk] joins (~itchyjunk@user/itchyjunk/x-7353470)
18:40:55 <[exa]> *Int
18:40:58 <monochrom> Hutton had "bestmove = head <the list here>" and I would just delete "head". Then it's tirivally the full list.
18:41:42 <monochrom> Then in play' I can do whatever I want to the full list, including "!! i" where i came from "i <- randomRIO (0, ???)".
18:42:07 mizlan joins (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net)
18:42:10 <[exa]> ( jil: one extra example where IO is used as an argument. `twice :: IO a -> IO a; twice action = do { action; action; }` )
18:42:28 <[exa]> (try as: `twice (print 5)`)
18:42:37 <jil> ok monochrom I get that
18:43:14 × gnalzo quits (~gnalzo@2a01:e0a:498:fd50:fcc6:bb5d:489a:ce8c) (Quit: WeeChat 3.7.1)
18:43:33 × emmanuelux quits (~emmanuelu@user/emmanuelux) (Quit: au revoir)
18:44:02 × merijn quits (~merijn@c-001-001-016.client.esciencecenter.eduvpn.nl) (Ping timeout: 255 seconds)
18:44:11 tromp joins (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
18:46:59 anon joins (~anon@77-161-12-199.fixed.kpn.net)
18:47:21 emmanuelux joins (~emmanuelu@user/emmanuelux)
18:52:43 × freeside_ quits (~mengwong@103.252.202.159) (Ping timeout: 252 seconds)
18:57:17 <jil> Thank you [exa] for your time and your support. Thank you monochrom.
18:57:47 <jil> I feel like you've made me do a huge step :) in understanding how to handle IO
18:58:06 × coot quits (~coot@2a02:a310:e241:1b00:ec1a:e9df:79ac:66ba) (Quit: coot)
18:58:39 coot joins (~coot@2a02:a310:e241:1b00:ec1a:e9df:79ac:66ba)
18:58:45 <[exa]> oh np
18:59:52 <[exa]> you might like to quickly run through some function->applicative->monad tutorial just to make sure this is systematized (even Learn You a Haskell should work, since you now have a piece of code to try this on)
19:00:05 <[exa]> s/function/functor ayayya
19:01:49 × mncheckm quits (~mncheck@193.224.205.254) (Ping timeout: 260 seconds)
19:04:46 Sciencentistguy joins (~sciencent@hacksoc/ordinary-member)
19:04:46 × emmanuelux quits (~emmanuelu@user/emmanuelux) (Quit: au revoir)
19:04:47 <jil> Thank you
19:09:58 <[exa]> jil: well, feel free to drop by for examples. :D
19:10:08 × beteigeuze quits (~Thunderbi@bl14-81-220.dsl.telepac.pt) (Ping timeout: 246 seconds)
19:10:23 × mizlan quits (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net) (Ping timeout: 268 seconds)
19:11:37 × tromp quits (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
19:11:42 <anon> Hi! I have this code: `f = \x -> mod x 2 == 0 || mod x 3 == 0 || mod x 5 == 0` where I want to optimise it such that the repeated code doesn't exist, and I'm not too sure how I'd approach this. Any ideas?
19:12:37 <c_wraith> anon: write a helper function like `divisible x y = x `mod` y == 0'
19:12:42 freeside joins (~mengwong@103.252.202.159)
19:12:46 <tomsmeding> or use 'any'
19:12:49 <opqdonut> or use something like any
19:12:53 <opqdonut> heh
19:12:56 <tomsmeding> :)
19:13:08 <anon> Thanks; I'll look into it!
19:13:08 <tomsmeding> :t any
19:13:10 <lambdabot> Foldable t => (a -> Bool) -> t a -> Bool
19:13:27 <tomsmeding> which simplifies to: (a -> Bool) -> [a] -> Bool
19:14:43 <mauke> :t \x -> or [mod x d == 0 | d <- [2, 3, 5]]
19:14:45 <lambdabot> Integral a => a -> Bool
19:15:26 <tomsmeding> :t \x -> any (\n -> mod x n == 0) [2, 3, 5]
19:15:28 <lambdabot> Integral a => a -> Bool
19:16:24 <[exa]> @pl \x -> any (\n -> mod x n == 0) [2, 3, 5] --can't resist trying, sorry
19:16:24 <lambdabot> flip any [2, 3, 5] . flip flip 0 . ((==) .) . mod
19:16:35 <tomsmeding> chef's kiss
19:16:47 <tomsmeding> :t flip flip 0
19:16:48 <lambdabot> Num b => (a -> b -> c) -> a -> c
19:17:07 <[exa]> it's not that good as I hoped but `flip flip 0` was worth it
19:17:39 <opqdonut> nice
19:17:44 <tomsmeding> @pl any (\n -> mod x n == 0) [2, 3, 5]
19:17:44 <lambdabot> any ((0 ==) . mod x) [2, 3, 5]
19:17:51 jakalx parts (~jakalx@base.jakalx.net) (Error from remote client)
19:17:54 <tomsmeding> letting it keep the 'x' makes it significantly nicer :p
19:18:03 <[exa]> yes
19:19:15 <tomsmeding> wat does @pl even do with list comprehensions, it clearly doesn't understand them but it butchers them even more badly than I expected?
19:19:22 × califax quits (~califax@user/califx) (Remote host closed the connection)
19:19:22 <tomsmeding> @pl \x -> or [mod x n == 0 | n <- [2,3,5]]
19:19:23 <lambdabot> or . return . (0 | n <- [2, 3, 5] ==) . flip mod n
19:19:32 <tomsmeding> that is _very_ far from valid syntax
19:19:45 <boxscape_> | as infix operator I suppose
19:19:51 <tomsmeding> and <- as well
19:19:52 <boxscape_> hm no
19:19:55 jakalx joins (~jakalx@base.jakalx.net)
19:20:05 <boxscape_> that's not enough
19:20:13 <boxscape_> you'd still need additional parentheses for the section
19:20:28 mizlan joins (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net)
19:20:44 <tomsmeding> not if you assume that | and <- have higher precedence than ==, which it probably assumes because default precedence for a newly-defined operator is 9, higher than ==
19:20:56 <boxscape_> % (4 * 5 +) 0
19:20:57 <yahb2> 20
19:20:59 <boxscape_> oh
19:21:01 <boxscape_> TIL
19:21:02 <mauke> @. pl undo \x -> or [mod x n == 0 | n <- [2,3,5]]
19:21:02 <lambdabot> or . ([2, 3, 5] >>=) . flip flip [] . ((:) .) . flip flip 0 . ((==) .) . mod
19:21:20 <tomsmeding> nice
19:21:24 <anon> is that even readable?
19:21:26 <tomsmeding> no
19:21:32 <tomsmeding> none of the @pl things is readable
19:21:40 <tomsmeding> we're just messing around
19:21:51 <anon> I see
19:22:05 tromp joins (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
19:22:21 <mauke> very, very occasionally @pl provides some insight or nice simplification. most of the time it's more like a train crash
19:22:32 califax joins (~califax@user/califx)
19:22:41 <tomsmeding> mauke++
19:22:51 <anon> Is @pl using the `pointfree` appication or something?
19:22:53 <hpc> pl doesn't stand for pointfree, it stands for pointless
19:23:06 <tomsmeding> but yes
19:23:46 <[exa]> I use it to convince myself that I can stop making stuff look nice
19:23:46 <boxscape_> ugh kiwiirc is making it really hard to use lambdabot because it wants to complete everything to a username as soon as you press space
19:24:05 <boxscape_> (if there's an @ I mean)
19:24:28 <[exa]> who ever used @ on irc?
19:24:31 <tomsmeding> boxscape_: type 'pl <home>@<end>' and then your stuff
19:24:47 × mizlan quits (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net) (Ping timeout: 246 seconds)
19:24:53 <tomsmeding> but also that, though I guess kiwiirc would remove the @ after autocompletion?
19:25:00 <tomsmeding> i.e. it's just an autocomplete trigger
19:25:01 <tomsmeding> I hope
19:25:15 <boxscape_> yes it removes the @
19:25:21 <[exa]> at that point you can [tab] without the @ right?
19:25:30 <boxscape_> you can always use tab for autocomplete yeah
19:25:33 <[exa]> je suis confuse
19:25:37 <boxscape_> it's a completely useless and counterproductive feature
19:25:42 <tomsmeding> yay
19:25:50 × abhixec quits (~abhinav@c-67-169-139-16.hsd1.ca.comcast.net) (Ping timeout: 246 seconds)
19:26:04 <[exa]> it helps the discord immigrants cope I guess
19:26:41 <monochrom> [exa]: The chapter right after tic-tac-toe is functor applicative monad. :)
19:27:02 <[exa]> ah. useful. jil ^
19:30:09 FurudeRika[m] joins (~chitandae@2001:470:69fc:105::1:6039)
19:30:12 <tomsmeding> [exa]: apparently kiwiirc autocompletes commands, channels and nicks on tab, and you can autocomplete a specific kind of thing by prefixing / # @
19:30:14 <tomsmeding> https://github.com/kiwiirc/kiwiirc/blob/213ba5333690a901c8d28436110ecc1ae9a230a1/src/res/configTemplates.js#L107
19:30:23 <tomsmeding> but it's a config option!
19:30:36 emmanuelux joins (~emmanuelu@user/emmanuelux)
19:30:44 × avpx quits (~nick@ec2-54-214-223-1.us-west-2.compute.amazonaws.com) (Ping timeout: 268 seconds)
19:30:46 <tomsmeding> also https://github.com/kiwiirc/kiwiirc/wiki/Configuration-Options#showautocomplete
19:31:33 <boxscape_> I've been looking through the GUI config but cannot find a way to turn off @ autocomplete without turning off *all* autocomplete
19:31:47 avpx joins (~nick@ec2-54-214-223-1.us-west-2.compute.amazonaws.com)
19:31:57 × wroathe quits (~wroathe@user/wroathe) (Quit: leaving)
19:32:02 <boxscape_> which probably means I should just be using a proper IRC client
19:32:05 × califax quits (~califax@user/califx) (Remote host closed the connection)
19:32:11 <tomsmeding> yeah one would probably need to change some config file
19:33:35 mizlan joins (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net)
19:33:39 Kaipei joins (~Kaiepi@nwcsnbsc03w-47-55-159-86.dhcp-dynamic.fibreop.nb.bellaliant.net)
19:33:59 <tomsmeding> boxscape_: if you were really desperate you could probably write a userscript to make one of these things use your config instead of the server config :p https://github.com/kiwiirc/kiwiirc/wiki/Configuration
19:34:21 <boxscape_> hmm I think I'll just use a different client :D
19:34:24 <tomsmeding> :p
19:34:59 <boxscape_> tomsmeding but actually I managed to disable it! It's hidden in advanced settings
19:35:11 califax joins (~califax@user/califx)
19:36:19 L29Ah joins (~L29Ah@wikipedia/L29Ah)
19:36:26 <tomsmeding> boxscape_: does it not even add a : when autocompleting nicks at the start of a line?
19:36:35 <boxscape_> no :(
19:36:53 <tomsmeding> weechat > kiwiirc
19:37:03 <tomsmeding> takes a bit more setup, granted :p
19:38:07 <boxscape_> I have used it in the past yeah
19:39:08 scoopahdoopah joins (~quassel@050-089-109-059.res.spectrum.com)
19:41:20 × L29Ah quits (~L29Ah@wikipedia/L29Ah) (Read error: Connection reset by peer)
19:41:56 L29Ah joins (~L29Ah@wikipedia/L29Ah)
19:44:12 accord joins (uid568320@id-568320.hampstead.irccloud.com)
19:45:59 boxscape joins (~boxscape@81.191.27.107)
19:46:03 × boxscape quits (~boxscape@81.191.27.107) (Remote host closed the connection)
19:51:28 × anon quits (~anon@77-161-12-199.fixed.kpn.net) (Quit: leaving)
19:53:24 × mizlan quits (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net) (Ping timeout: 272 seconds)
19:53:59 × boxscape_ quits (~boxscape_@81.191.27.107) (Quit: Connection closed)
19:54:08 mizlan joins (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net)
19:54:45 boxscape_ joins (~boxscape_@81.191.27.107)
19:55:24 × califax quits (~califax@user/califx) (Remote host closed the connection)
19:56:32 califax joins (~califax@user/califx)
19:59:27 × sammelweis quits (~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10) (Quit: No Ping reply in 180 seconds.)
20:01:08 sammelweis joins (~quassel@2601:401:8200:2d4c:bd9:d04c:7f69:eb10)
20:01:54 × instantaphex quits (~jb@c-73-171-252-84.hsd1.fl.comcast.net) (Ping timeout: 260 seconds)
20:02:02 × gabriel_sevecek quits (~gabriel@188-167-229-200.dynamic.chello.sk) (Quit: WeeChat 3.7.1)
20:05:14 × mizlan quits (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net) (Ping timeout: 265 seconds)
20:07:34 Sgeo joins (~Sgeo@user/sgeo)
20:07:42 mizlan joins (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net)
20:13:19 talismanick joins (~talismani@45-23-184-231.lightspeed.frokca.sbcglobal.net)
20:15:26 gmg joins (~user@user/gehmehgeh)
20:19:03 × freeside quits (~mengwong@103.252.202.159) (Ping timeout: 260 seconds)
20:19:54 × mizlan quits (~mizlan@c-67-169-7-31.hsd1.ca.comcast.net) (Ping timeout: 255 seconds)
20:20:04 gnalzo joins (~gnalzo@2a01:e0a:498:fd50:fcc6:bb5d:489a:ce8c)
20:24:38 × nehsou^ quits (~nehsou@76.145.190.81) (Remote host closed the connection)
20:26:48 × hashn3rd quits (~hashn3rd@ip72-221-42-80.ks.ks.cox.net) (Quit: Leaving.)
20:27:30 freeside joins (~mengwong@103.252.202.159)
20:32:24 × freeside quits (~mengwong@103.252.202.159) (Ping timeout: 268 seconds)
20:32:43 × califax quits (~califax@user/califx) (Remote host closed the connection)
20:36:15 califax joins (~califax@user/califx)
20:41:32 × eggplantade quits (~Eggplanta@2600:1700:38c5:d800:9c06:575b:efcb:5bf) (Remote host closed the connection)
20:45:11 dextaa6 joins (~DV@user/dextaa)
20:47:24 × dextaa quits (~DV@user/dextaa) (Ping timeout: 260 seconds)
20:47:24 dextaa6 is now known as dextaa
20:55:50 × trev quits (~trev@user/trev) (Remote host closed the connection)
20:57:54 freeside joins (~mengwong@103.252.202.159)
20:58:04 titibandit1 joins (~titibandi@xdsl-87-78-235-220.nc.de)
20:59:16 eggplantade joins (~Eggplanta@2600:1700:38c5:d800:9c06:575b:efcb:5bf)
21:00:04 <Inst_> tbh, i just realized this, and this is sort of a troll, but is it true that every Haskell function is technically a one-liner?
21:00:11 <Inst_> expression-based language
21:00:14 lewisje joins (~lewisje@2001:470:1f11:14e:1753:f4c6:e607:e65f)
21:00:41 <Inst_> well, not true
21:00:45 <Inst_> where clauses, let clauses
21:00:48 <Inst_> erm, let expressions
21:01:11 <geekosaur> those are one-liners too. use braces instead of layout
21:01:15 wroathe joins (~wroathe@50.205.197.50)
21:01:15 × wroathe quits (~wroathe@50.205.197.50) (Changing host)
21:01:15 wroathe joins (~wroathe@user/wroathe)
21:01:54 <geekosaur> also they're mostly optional conveniences
21:02:37 × freeside quits (~mengwong@103.252.202.159) (Ping timeout: 268 seconds)
21:03:10 × epolanski quits (uid312403@id-312403.helmsley.irccloud.com) (Quit: Connection closed for inactivity)
21:05:48 <[exa]> unless you go for something unwieldy like C preprocessor or python, most reasonable languages can be smashed into a single line
21:06:18 <[exa]> that said, haskell functions really tend to be oneline much more often by default, so I guess we still win
21:06:53 <dolio> You can put an entire module on one line, I think. But I wouldn't recommend it.
21:06:55 <geekosaur> I think Inst_ meant conceptually, i.e. not counting continuation lines
21:07:29 Inst_ is now known as Inst
21:07:46 <Inst> Yeah, I know one-liner is derisive in production circles
21:07:54 <Inst> "looks cool, impossible to understand and unmaintainable"
21:09:26 <[exa]> depends on whether oneliners are a result of good engineering or just golfing
21:09:57 <[exa]> also if the type counts, we actually have twoliners
21:12:04 <Inst> just trying to understand why Haskell is so different
21:12:11 <Inst> i just had a talk with someone, maybe he was drunk
21:12:31 <Inst> he's working at an educational firm in Sub-Saharan Africa
21:12:36 <geekosaur> I think a lot of it is abstraction
21:12:46 <Inst> they're actually very successful and have shown meteoric expansion
21:12:52 <Inst> he's thinking about doing a Haskell project
21:13:11 <Inst> he's like incredibly confident his team will have 0 problems with Haskell
21:13:12 <hpc> there's two different types of one-liners people talk about, that both are called the same thing
21:13:21 <hpc> there's "one line of code" one-liners
21:13:30 <hpc> and "one line of communicating with the programmer reading your code" one-liners
21:13:54 <[exa]> one-thoughts
21:13:59 <hpc> the output of @pl doesn't tell anyone anything most of the time, but...
21:14:05 <hpc> hah, that's a good way to put it
21:14:06 kenaryn joins (~aurele@cre71-h03-89-88-44-27.dsl.sta.abo.bbox.fr)
21:14:36 <hpc> but yeah, haskell is good at those one-thought one-liners
21:14:50 <Inst> maybe it's the wrong way to think of Haskell code as one-liners, i.e, a line is usually a statement in a traditional, imperative language
21:15:14 <hpc> and it's sort of where "a monad is just a monoid in the category of endofunctors" stops being a joke, if you say it in a university math department
21:15:15 freeside joins (~mengwong@103.252.202.159)
21:15:34 <hpc> as long as you stick to the "language" of who is going to read your code, you can say a lot in very few words or function calls
21:15:53 <Inst> atomically, all languages have as their fundamental unit the lexeme
21:15:58 <Inst> that's sort of by definition
21:16:10 <[exa]> it's like math, you know how stuff works in nature but it takes years to extract a rememberable concept that fits a space for 1 non-scary formula
21:16:16 <mauke> well ...
21:16:25 <Inst> but in an imperative language, the basic composition of lexemes would be a statement, in Haskell, it'd be a function or operator application, no?
21:17:05 <Inst> so then the 1 liner comparison fails
21:17:39 <mauke> I can think of an imperative language without statements
21:17:51 <Inst> assembly? machine code?
21:18:04 <[exa]> c++ `;` isn't an operator??? /me disappoint
21:18:12 <mauke> that was my first thought, but you still have instructions there
21:18:16 <mauke> but then I remembered False
21:18:43 <mauke> (named after the language author's favorite boolean value)
21:19:31 <mauke> it's stack based, so I guess you could say each character is its own statement
21:19:52 <[exa]> re formal systems without statements&lexemes: Scratch, finite state machine diagrams, flowcharts, LaTeX
21:19:57 × kenaryn quits (~aurele@cre71-h03-89-88-44-27.dsl.sta.abo.bbox.fr) (Quit: leaving)
21:20:09 <mauke> ... Piet?
21:20:37 <[exa]> (and there is something that interprets literal freakin bitmaps)
21:20:47 <mauke> yeah, Piet
21:20:55 <[exa]> ah, nice
21:21:56 <[exa]> (wasn't it called differently some years ago?)
21:22:07 <mauke> I've personally written a language/interpreter that has statements (kind of), but I have no idea where I'd even start writing a formal grammar for it
21:22:08 <mauke> because it has no syntax errors
21:22:17 × talismanick quits (~talismani@45-23-184-231.lightspeed.frokca.sbcglobal.net) (Read error: Connection reset by peer)
21:22:35 × gmg quits (~user@user/gehmehgeh) (Quit: Leaving)
21:22:38 <geekosaur> there's two of them that take their names from the same place: Piet and Mondrian
21:23:25 <monochrom> In practice my functions are multi-line but not too many lines.
21:23:26 <mauke> similarly, there are three languages that share a common name: Haskell, B, Curry
21:24:01 <hpc> mauke: by that standard tolkien has 3 languages named after him too
21:24:30 <geekosaur> someone missed a chance to name a language Brooks
21:24:59 × boxscape_ quits (~boxscape_@81.191.27.107) (Ping timeout: 248 seconds)
21:25:11 <mauke> JRPG Torkelson? https://www.youtube.com/watch?v=HHoJSgq6mqc
21:26:14 <hpc> geekosaur: someone did, but it's hard to find references to it now
21:26:53 <Inst> is a function application analogous to a statement?
21:27:03 <Inst> as a unit of thinking?
21:27:27 <[exa]> probably a repost here but the Pi program here is absolute pure gold: https://www.dangermouse.net/esoteric/piet/samples.html
21:28:34 <monochrom> You will find that in programming there are tons of units of thinking, some large some small some recursive.
21:28:52 <monochrom> In other words the answer is "yes but tautological".
21:29:47 <[exa]> Inst: you're thinking about what things _are_. Things are not, unless something interprets them, and it depends a lot on who interprets the statements and function applications. Are things in a `do` statements, or applications of >> and >>= ? Are applications still applications if interpreted in a completely statementy RTS?
21:30:10 <Inst> Haskell2010 says they're statements :)
21:30:44 <monochrom> [exa], in real conversations there is always a chosen interpretation by context or consensus.
21:30:48 <Inst> sorry, i won't waste your time, illness acting up a bit, that's all
21:31:29 Lord_of_Life_ joins (~Lord@user/lord-of-life/x-2819915)
21:31:53 <monochrom> So for example in #haskell it's usually Haskel2010 or GHC or GHC2021
21:31:53 × Lord_of_Life quits (~Lord@user/lord-of-life/x-2819915) (Ping timeout: 246 seconds)
21:31:58 <[exa]> (np I was trying to highlight the relativeness of all existence :] )
21:31:59 johnw_ joins (~johnw@2600:1700:cf00:db0:c9ed:4d36:cb4c:4c99)
21:32:08 × tromp quits (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
21:32:26 <monochrom> Sure! You also find me harping "social construct" more often lately :D
21:32:48 Lord_of_Life_ is now known as Lord_of_Life
21:32:52 × johnw quits (~johnw@2600:1700:cf00:db0:1:83a7:8879:1baf) (Ping timeout: 252 seconds)
21:33:06 <Inst> i'm just trying to figure out why people find it so hard to grok Haskell, or specifically, why it's hard for them to grok an expression-styled mode of programming, the initial guess was because Haskell code, as expression-based, is often like a one-liner, and they don't know how to read such a language
21:33:08 <monochrom> I gave a talk on intuitionistic logic and why the Kripke semantics makes sense for it. That corrupted me greatly.
21:33:24 tromp joins (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
21:33:26 <[exa]> :]
21:34:11 <Inst> then the next guess was that expression-based programming is terser than what they're used to, or that they have no idea how to break up and parse an expression
21:35:05 <mauke> ah, yes: "Naturally, a more accurate value can be obtained by using a bigger program."
21:35:22 <monochrom> Inst, you are looking at a self-selection bias. Your "people" should be corrected to "people who self-chose to be programmers" and then suddenly you realize that this demography chose programming precisely because they hate math.
21:35:56 × Ram-Z quits (~Ram-Z@li1814-254.members.linode.com) (Ping timeout: 255 seconds)
21:36:03 <[exa]> Inst: I often think that it's something like a command indirection, normally in programming languages you give a command and you see a result; in haskell you describe the way the commands will get given and only after some indirection (what does lazily trigger later? how does IO evaluate to this point?) you observe the result. Same applies to people learning to manage other people to do work.
21:36:12 <monochrom> Just look at how many of them ask "how to get rid of parentheses".
21:36:13 <dolio> I think you'll find that people have trouble understanding programming.
21:36:20 <Inst> and somehow weren't weeded out by 4 semesters of calculus in uni
21:36:27 <Inst> + discrete mathematics
21:36:49 <dolio> Haskell is just a special case.
21:37:02 <[exa]> dolio: lol +1
21:37:17 ddellacosta joins (~ddellacos@static-198-44-136-50.cust.tzulo.com)
21:37:37 <monochrom> Well yes I teach a 3rd year course and I use Haskell heavily. My students survived all that calculus and discrete math, so now I'm looking at the survival bias that my students grok Haskell just fine, some of them even report that they like it.
21:38:23 <dolio> And the ones that complain the most about Haskell are those that already learned to program using something else, but their understanding of that isn't helping them as much as they think it ought to. And they forgot how hard it was to originally learn programming.
21:39:04 <monochrom> In fact those students who had trouble with the State monad explicitly asked me "could you show me expanding the expressions" and so I did and they were like "that helps".
21:39:28 <mauke> [exa]: https://www.ioccc.org/1988/westley.fix.c
21:39:29 Ram-Z joins (~Ram-Z@li1814-254.members.linode.com)
21:39:37 <Inst> i guess the subsaharan african guy should be fine
21:39:46 <Inst> the place where he gets his uni grads from, i'm told
21:39:51 <monochrom> But like I said, I don't expect to replicate this success outside my niche demography.
21:39:58 <Inst> their CS program is a combination of mathematics and business, and they refuse to teach python / java etc as a waste of time
21:40:18 <Inst> presumably under the assumption that python / java etc can be learned on your own
21:41:13 <monochrom> Just look at discourse.haskell.org, there is a learner klequis, he usually understands other people's wordy drawn-out explanations better than my cut-to-the-mustard algebra explanations.
21:41:55 × Ram-Z quits (~Ram-Z@li1814-254.members.linode.com) (Client Quit)
21:41:58 <monochrom> Oh management? That makes sense.
21:42:20 <monochrom> A manager hires a programmer. A manager doesn't learn a programming language; that would be dumb.
21:42:50 <[exa]> mauke: oh my that's so cute
21:43:30 <Inst> nah, his description was national
21:43:37 <Inst> maybe C? he was talking South Africa
21:46:06 <monochrom> Alternatively you're just looking at another interpretation of "CS"---that there are a lot of intellectual topics so programming is only a very small part.
21:46:10 Ram-Z joins (Ram-Z@2a01:7e01::f03c:91ff:fe57:d2df)
21:46:21 <monochrom> For example Dijkstra would (did) think that.
21:47:41 <monochrom> Today most universities are job-oriented, but once upon a time people were more ideal, "CS" was not vocational training.
21:48:11 <geekosaur> depends on the university though
21:48:32 <monochrom> (And the "most universities are job-oriented" applies to many more areas than CS, too.)
21:48:38 × johnw_ quits (~johnw@2600:1700:cf00:db0:c9ed:4d36:cb4c:4c99) (Ping timeout: 246 seconds)
21:48:39 <geekosaur> in 1983 my "CS" choices were Fortran (engineering track) or COBOL (business track)
21:49:42 <monochrom> Yeah, "once upon a time" was even older than that :)
21:49:44 <monochrom> or :(
21:50:27 <monochrom> Don't despair! Knuth says: the best theory is inspired by practice, the best practice is inspired by theory. :)
21:50:58 × biberu quits (~biberu@user/biberu) (Read error: Connection reset by peer)
21:51:05 <[exa]> still, much more people is now doing actual CS than in ye olden days
21:51:30 <[exa]> labeling pop programming courses as CS I don't like either, but what can we do, that's the nature of names
21:52:15 × titibandit1 quits (~titibandi@xdsl-87-78-235-220.nc.de) (Remote host closed the connection)
21:55:42 biberu joins (~biberu@user/biberu)
21:58:07 <Inst> What's the tradeoff between HTTP and http-client?
21:59:20 <monochrom> I am more optimistic, I'm happy that people learn the basics of programming, and even FIFO vs LIFO vs linked lists vs tress (at which point it counts as CS, even though very small and very beginner).
22:00:32 <Inst> ah, HTTP doesn't support HTTPS
22:05:41 <mauke> [exa]++ # made me think and actually understand westley.c for the first time
22:09:23 × mc47 quits (~mc47@xmonad/TheMC47) (Remote host closed the connection)
22:18:46 × wroathe quits (~wroathe@user/wroathe) (Quit: leaving)
22:21:40 × freeside quits (~mengwong@103.252.202.159) (Ping timeout: 260 seconds)
22:22:48 jinsun__ joins (~jinsun@user/jinsun)
22:22:48 × jinsun quits (~jinsun@user/jinsun) (Killed (mercury.libera.chat (Nickname regained by services)))
22:22:48 jinsun__ is now known as jinsun
22:32:38 wroathe joins (~wroathe@50.205.197.50)
22:32:38 × wroathe quits (~wroathe@50.205.197.50) (Changing host)
22:32:38 wroathe joins (~wroathe@user/wroathe)
22:34:17 × takuan quits (~takuan@178-116-218-225.access.telenet.be) (Remote host closed the connection)
22:35:31 × hgolden quits (~hgolden@cpe-172-251-233-141.socal.res.rr.com) (Remote host closed the connection)
22:35:47 × fizbin quits (~fizbin@user/fizbin) (Remote host closed the connection)
22:36:06 fizbin joins (~fizbin@user/fizbin)
22:36:34 freeside joins (~mengwong@103.252.202.159)
22:39:11 justache is now known as justReddy
22:39:26 × caryhartline quits (~caryhartl@2600:1700:2d0:8d30:31be:b9b2:d1e5:a2dd) (Quit: caryhartline)
22:40:48 caryhartline joins (~caryhartl@2600:1700:2d0:8d30:d067:b8ad:4af0:b156)
22:43:37 × Luj3 quits (~Luj@2a01:e0a:5f9:9681:df7f:d915:e87b:faad) (Quit: The Lounge - https://thelounge.chat)
22:47:06 × wroathe quits (~wroathe@user/wroathe) (Quit: leaving)
22:47:34 × adium quits (adium@user/adium) (Ping timeout: 260 seconds)
22:48:10 Luj3 joins (~Luj@2a01:e0a:5f9:9681:4a08:e5d4:539b:20f)
22:48:34 adium joins (adium@user/adium)
22:48:36 × tromp quits (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
22:52:11 × caryhartline quits (~caryhartl@2600:1700:2d0:8d30:d067:b8ad:4af0:b156) (Quit: caryhartline)
22:56:50 × jinsun quits (~jinsun@user/jinsun) (Read error: Connection reset by peer)
22:57:05 jinsun joins (~jinsun@user/jinsun)
22:59:54 jinsun__ joins (~jinsun@user/jinsun)
22:59:54 × jinsun quits (~jinsun@user/jinsun) (Killed (zinc.libera.chat (Nickname regained by services)))
22:59:54 jinsun__ is now known as jinsun
23:00:24 × fizbin quits (~fizbin@user/fizbin) (Ping timeout: 268 seconds)
23:00:29 × coot quits (~coot@2a02:a310:e241:1b00:ec1a:e9df:79ac:66ba) (Quit: coot)
23:02:52 × L29Ah quits (~L29Ah@wikipedia/L29Ah) (Ping timeout: 268 seconds)
23:04:27 × accord quits (uid568320@id-568320.hampstead.irccloud.com) (Quit: Connection closed for inactivity)
23:06:04 L29Ah joins (~L29Ah@wikipedia/L29Ah)
23:10:58 × eggplantade quits (~Eggplanta@2600:1700:38c5:d800:9c06:575b:efcb:5bf) (Remote host closed the connection)
23:10:58 × L29Ah quits (~L29Ah@wikipedia/L29Ah) (Read error: Connection reset by peer)
23:11:06 × __monty__ quits (~toonn@user/toonn) (Quit: leaving)
23:12:58 × tcard quits (~tcard@2400:4051:5801:7500:cf17:befc:ff82:5303) (Quit: Leaving)
23:14:26 eggplantade joins (~Eggplanta@2600:1700:38c5:d800:9c06:575b:efcb:5bf)
23:15:58 guisande[m] joins (~guisandem@2001:470:69fc:105::2:f049)
23:16:38 × bgs quits (~bgs@212-85-160-171.dynamic.telemach.net) (Remote host closed the connection)
23:18:47 × freeside quits (~mengwong@103.252.202.159) (Ping timeout: 264 seconds)
23:20:43 guisande[m] parts (~guisandem@2001:470:69fc:105::2:f049) ()
23:20:52 acidjnk joins (~acidjnk@p200300d6e715c430f99e79aa35639cab.dip0.t-ipconnect.de)
23:21:37 clementd-42[m] joins (~clementd-@2001:470:69fc:105::1:65c5)
23:21:52 fizbin joins (~fizbin@user/fizbin)
23:27:30 libertyprime joins (~libertypr@203.96.203.167)
23:34:50 freeside joins (~mengwong@103.252.202.159)
23:35:34 × fizbin quits (~fizbin@user/fizbin) (Ping timeout: 252 seconds)
23:36:51 mmhat joins (~mmh@p200300f1c7123c08ee086bfffe095315.dip0.t-ipconnect.de)
23:36:51 × mmhat quits (~mmh@p200300f1c7123c08ee086bfffe095315.dip0.t-ipconnect.de) (Client Quit)
23:42:13 fizbin joins (~fizbin@user/fizbin)
23:48:14 × AlexNoo quits (~AlexNoo@178.34.160.164) (Read error: Connection reset by peer)
23:51:43 × AlexZenon quits (~alzenon@178.34.160.164) (Ping timeout: 260 seconds)
23:52:24 × Alex_test quits (~al_test@178.34.160.164) (Ping timeout: 265 seconds)
23:52:40 × eggplantade quits (~Eggplanta@2600:1700:38c5:d800:9c06:575b:efcb:5bf) (Remote host closed the connection)
23:52:47 panovia joins (~user@user/siracusa)
23:53:54 × tremon quits (~tremon@83-85-213-108.cable.dynamic.v4.ziggo.nl) (Quit: getting boxed in)
23:55:24 tcard joins (~tcard@2400:4051:5801:7500:cf17:befc:ff82:5303)
23:56:51 shriekingnoise joins (~shrieking@186.137.175.87)
23:57:46 × mud quits (~mud@user/kadoban) (Quit: quit)

All times are in UTC on 2023-01-08.