Home liberachat/#haskell: Logs Calendar

Logs on 2021-11-13 (liberachat/#haskell)

00:00:30 × emf quits (~emf@2620:10d:c090:400::5:6b1) (Quit: emf)
00:01:14 <dsal> There's also ifromJSON that returns an IResult in case you want more letters in your code.
00:01:21 lavaman joins (~lavaman@98.38.249.169)
00:03:00 jinsun__ joins (~quassel@user/jinsun)
00:04:01 jinsun___ joins (~quassel@user/jinsun)
00:04:45 × __monty__ quits (~toonn@user/toonn) (Quit: leaving)
00:05:50 × lavaman quits (~lavaman@98.38.249.169) (Ping timeout: 260 seconds)
00:06:02 × jinsun quits (~quassel@user/jinsun) (Ping timeout: 240 seconds)
00:08:20 × jinsun__ quits (~quassel@user/jinsun) (Ping timeout: 268 seconds)
00:08:43 mikoto-chan joins (~mikoto-ch@esm-84-240-99-143.netplaza.fi)
00:18:15 × servytor quits (uid525486@hampstead.irccloud.com) (Quit: Connection closed for inactivity)
00:19:21 × Guest42 quits (~Guest42@eth-west-pareq2-46-193-4-100.wb.wifirst.net) (Quit: Client closed)
00:25:14 × zava quits (~zava@ip5f5bdf0f.dynamic.kabel-deutschland.de) (Quit: WeeChat 3.3)
00:26:22 × johnjay quits (~pi@192.142.100.50) (Ping timeout: 260 seconds)
00:27:18 × Lord_of_Life quits (~Lord@user/lord-of-life/x-2819915) (Ping timeout: 260 seconds)
00:28:00 johnjay joins (~pi@192.142.100.50)
00:28:47 Lord_of_Life joins (~Lord@user/lord-of-life/x-2819915)
00:35:28 × myShoggoth quits (~myShoggot@97-120-85-195.ptld.qwest.net) (Ping timeout: 268 seconds)
00:35:39 burnsidesLlama joins (~burnsides@dhcp168-014.wadham.ox.ac.uk)
00:37:05 Tuplanolla joins (~Tuplanoll@91-159-69-50.elisa-laajakaista.fi)
00:38:17 falafel__ joins (~falafel@cpe-76-168-195-162.socal.res.rr.com)
00:38:29 × gdown quits (~gavin@h69-11-248-109.kndrid.broadband.dynamic.tds.net) (Remote host closed the connection)
00:39:06 yauhsien joins (~yauhsien@118-167-47-187.dynamic-ip.hinet.net)
00:44:06 × yauhsien quits (~yauhsien@118-167-47-187.dynamic-ip.hinet.net) (Ping timeout: 268 seconds)
00:44:07 mvk joins (~mvk@2607:fea8:5cc3:e900::df92)
00:45:26 jinsun___ is now known as jinsun
00:48:09 × mvk quits (~mvk@2607:fea8:5cc3:e900::df92) (Client Quit)
00:48:33 mvk joins (~mvk@2607:fea8:5cc3:e900::df92)
00:48:36 × mvk quits (~mvk@2607:fea8:5cc3:e900::df92) (Client Quit)
00:48:53 mvk joins (~mvk@2607:fea8:5cc3:e900::df92)
00:49:23 merijn joins (~merijn@83-160-49-249.ip.xs4all.nl)
00:49:38 × Flonk quits (~Flonk@vps-zap441517-1.zap-srv.com) (Quit: The Lounge - https://thelounge.chat)
00:49:54 Flonk joins (~Flonk@vps-zap441517-1.zap-srv.com)
00:50:38 × Flonk quits (~Flonk@vps-zap441517-1.zap-srv.com) (Client Quit)
00:50:54 Flonk joins (~Flonk@vps-zap441517-1.zap-srv.com)
00:52:11 × jlamothe quits (~jlamothe@198.251.61.229) (Ping timeout: 245 seconds)
00:53:56 × Flonk quits (~Flonk@vps-zap441517-1.zap-srv.com) (Client Quit)
00:54:12 Flonk joins (~Flonk@vps-zap441517-1.zap-srv.com)
00:55:56 × Flonk quits (~Flonk@vps-zap441517-1.zap-srv.com) (Client Quit)
00:56:12 Flonk joins (~Flonk@vps-zap441517-1.zap-srv.com)
00:56:43 × Flonk quits (~Flonk@vps-zap441517-1.zap-srv.com) (Client Quit)
00:56:59 Flonk joins (~Flonk@vps-zap441517-1.zap-srv.com)
01:00:59 renzhi joins (~xp@2607:fa49:6500:b100::6e7f)
01:01:21 × [itchyjunk] quits (~itchyjunk@user/itchyjunk/x-7353470) (Ping timeout: 245 seconds)
01:02:00 × jgeerds quits (~jgeerds@55d41b94.access.ecotel.net) (Ping timeout: 268 seconds)
01:03:22 × falafel__ quits (~falafel@cpe-76-168-195-162.socal.res.rr.com) (Remote host closed the connection)
01:03:38 falafel__ joins (~falafel@2603-8000-d800-688c-34f9-26f3-71b0-5b78.res6.spectrum.com)
01:03:52 × acidjnk_new quits (~acidjnk@p200300d0c725147020cf3de033c5d4d3.dip0.t-ipconnect.de) (Ping timeout: 265 seconds)
01:03:59 wroathe joins (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
01:03:59 × wroathe quits (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Changing host)
01:03:59 wroathe joins (~wroathe@user/wroathe)
01:05:00 × Flonk quits (~Flonk@vps-zap441517-1.zap-srv.com) (Quit: The Lounge - https://thelounge.chat)
01:05:16 Flonk joins (~Flonk@vps-zap441517-1.zap-srv.com)
01:05:33 werneta joins (~werneta@70-142-214-115.lightspeed.irvnca.sbcglobal.net)
01:05:51 × Flonk quits (~Flonk@vps-zap441517-1.zap-srv.com) (Client Quit)
01:05:57 Gurkenglas parts (~Gurkengla@dslb-002-203-144-204.002.203.pools.vodafone-ip.de) (Leaving)
01:06:07 Flonk joins (~Flonk@vps-zap441517-1.zap-srv.com)
01:07:35 [itchyjunk] joins (~itchyjunk@user/itchyjunk/x-7353470)
01:08:01 × falafel__ quits (~falafel@2603-8000-d800-688c-34f9-26f3-71b0-5b78.res6.spectrum.com) (Ping timeout: 245 seconds)
01:17:18 × Midjak quits (~Midjak@82-65-111-221.subs.proxad.net) (Quit: This computer has gone to sleep)
01:19:03 gdown joins (~gavin@h69-11-248-109.kndrid.broadband.dynamic.tds.net)
01:19:18 × gdown quits (~gavin@h69-11-248-109.kndrid.broadband.dynamic.tds.net) (Remote host closed the connection)
01:20:17 SeungheonOh joins (~Thunderbi@2600:1700:5168:1400:efbd:f13b:39e3:ec30)
01:21:43 × waleee quits (~waleee@2001:9b0:216:8200:d457:9189:7843:1dbd) (Ping timeout: 268 seconds)
01:22:53 lavaman joins (~lavaman@98.38.249.169)
01:23:10 waleee joins (~waleee@h-98-128-228-119.NA.cust.bahnhof.se)
01:23:46 × merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 260 seconds)
01:28:30 × retroid_ quits (~retro@2e41e9c8.skybroadband.com) (Ping timeout: 268 seconds)
01:28:51 × alzgh quits (~alzgh@user/alzgh) (Remote host closed the connection)
01:28:55 shapr joins (~user@pool-100-36-247-68.washdc.fios.verizon.net)
01:32:08 × DNH quits (~DNH@8.44.0.72) (Quit: Textual IRC Client: www.textualapp.com)
01:44:54 jbox joins (~atlas@2600:1700:2196:2060:2906:6b16:da43:7be2)
01:45:01 × jbox quits (~atlas@2600:1700:2196:2060:2906:6b16:da43:7be2) (Changing host)
01:45:01 jbox joins (~atlas@user/jbox)
01:45:41 × jbox quits (~atlas@user/jbox) (Client Quit)
01:45:59 jbox joins (~jbox@user/jbox)
01:48:27 × ec quits (~ec@gateway/tor-sasl/ec) (Ping timeout: 276 seconds)
01:49:52 × mmhat quits (~mmh@55d4bb38.access.ecotel.net) (Quit: WeeChat 3.3)
01:51:14 × notzmv quits (~zmv@user/notzmv) (Ping timeout: 265 seconds)
01:51:34 <amesgen[m]> Franciman: Another very new lib for extremely high performance parsing is https://github.com/AndrasKovacs/flatparse
01:51:43 × Tuplanolla quits (~Tuplanoll@91-159-69-50.elisa-laajakaista.fi) (Quit: Leaving.)
01:55:05 emf joins (~emf@63.64.162.234)
01:56:47 notzmv joins (~zmv@user/notzmv)
01:57:09 jlamothe joins (~jlamothe@198.251.61.229)
01:59:57 × emf quits (~emf@63.64.162.234) (Ping timeout: 268 seconds)
02:01:07 emf joins (~emf@2620:10d:c090:400::5:3d2a)
02:02:41 harveypwca joins (~harveypwc@2601:246:c180:a570:3828:d8:e523:3f67)
02:09:05 <sm> > On microbenchmarks, flatparse is around 10 times faster than attoparsec or megaparsec. On larger examples with heavier use of source positions and spans and/or indentation parsing, the performance difference grows to 20-30 times. Compile times and exectuable sizes are also significantly better with flatparse than with megaparsec or attoparsec
02:09:07 <lambdabot> <hint>:1:19: error: parse error on input ‘,’
02:11:18 × emf quits (~emf@2620:10d:c090:400::5:3d2a) (Quit: emf)
02:11:43 <SeungheonOh> how do they accomplish a significantly better performance?
02:11:50 <SeungheonOh> do they use C ffi?
02:12:07 <c_wraith> you don't need to that.
02:12:16 <c_wraith> GHC gives you plenty of low-level tools
02:12:26 <sm> the readme tells
02:13:23 <SeungheonOh> ByteString?
02:13:44 <SeungheonOh> and GHC Primops
02:14:13 <davean> dsal: You don't even need to write it - its Foldable
02:14:59 × pretty_dumm_guy quits (trottel@gateway/vpn/protonvpn/prettydummguy/x-88029655) (Quit: WeeChat 3.3)
02:16:06 <jbox> I wish the haskell ecosystem was more modern
02:16:19 <jbox> I absolutely adore Haskell as a language but that's the only good thing about it imo
02:16:39 <SeungheonOh> why do you think haskell tooling is not modern?
02:17:00 <jbox> it's just a mess in my experience.
02:17:19 <jbox> for example, why does cabal need its own language? can't we just use toml or something?
02:17:52 <sclv> toml is not expressive enough
02:17:52 <davean> cabal is a mess, but if you tried to encode what it does in toml it would be a mess - how do you plan to condititionals for example?
02:18:08 <sclv> also cabal format predates toml or json for that matter
02:18:15 <SeungheonOh> stack is more refined
02:18:20 <sclv> if it used “the standard” it would have been xml
02:18:22 <davean> people do cram things into generic formats but they just never actually work
02:18:31 jbox hisses at xml
02:18:43 <sclv> i just talked to cargo devs this weekend who lamented the problems with toml
02:18:51 <jbox> you make a good point davean, I don't know.
02:18:55 × whatsupdoc quits (uid509081@hampstead.irccloud.com) (Quit: Connection closed for inactivity)
02:19:11 <jbox> sclv: can you link me the conversation? That sounds like something I'd be interested in
02:19:20 <davean> jbox: talk to kubnernets people about the security issues and random API errors from them using yaml :)
02:19:24 <sclv> i literally talked to them
02:19:31 <SeungheonOh> Golang uses their own unliterate formats. Cabal formats looks modern enough
02:19:44 × alx741 quits (~alx741@181.196.68.187) (Quit: alx741)
02:19:47 <davean> sclv: yes, but there is a proper citation format for a discusssion
02:19:52 <sclv> like with spoken voices
02:20:25 <davean> sclv: yes, you can cite that though :)
02:20:29 <jbox> davean: I wholeheartedly believe yaml is the spawn of satan
02:21:14 <davean> sclv: you give the name, list it as "Personal Interview" and give the date
02:21:46 <sclv> a common package description format between multiple languages would be great. as is, the cabal format is better than lots of alternatives and even with others
02:22:13 <jbox> the solution is lisp, of course
02:22:27 <sm> for a refreshing change, I submit... https://treenotation.org & https://treebase.treenotation.org
02:22:29 <sclv> python and npm are disasters, which require executing arbitrary code to even discover what is in a package manifest
02:22:33 <davean> Hum, yah I'd support configuring out packages in lisp, at least it wouldn't be cabal!
02:22:53 <davean> sclv: neither of those made me deal with cabal's format though :-p
02:22:53 <sm> it's like s-exprs, with indentation instead of parentheses
02:23:09 <monochrom> Unpopular opinion: cabal is not a mess.
02:23:34 <sclv> from talking to those maintainers, arbitrary code has been a terrible choice they can’t dig themselves out of
02:23:34 <monochrom> Unpopular opinion: s/modern/hype, fad/
02:24:14 <sclv> this was all at packaging-con btw, if you want a cite, but it was unrecorded “hallway track”
02:24:45 <sclv> Xml is like s exprs but with angle brackets instead of parens :-p
02:25:07 <davean> sclv: s-exprs are single-level, xml is trilevel
02:25:15 <monochrom> I don't know how to map xml attributes to s-expressions, honestly.
02:25:21 <davean> you can't
02:25:35 <sclv> Very Carefully!!!
02:25:37 <davean> not in general
02:25:41 <jbox> sm: this Tree Notation thing looks too ambitious and broad in scope
02:25:54 <monochrom> I like s-expressions, but please don't pretend every fad can be shoehorned into it.
02:26:00 ec joins (~ec@gateway/tor-sasl/ec)
02:26:01 <jbox> davean: what do you mean by single- and tri-level?
02:26:02 <davean> jbox: it also says things like "no syntax" and then discusses its syntax
02:26:15 <sm> I agree, but I think there's something good there
02:26:18 <davean> jbox: seperate denoted namespaces
02:26:35 <davean> jbox: xml has different meanings for node names, attributes, etc
02:27:10 <jbox> yeah, at first the claims with "no syntax" paired with the drawings made me think it was some kind of joke
02:28:42 <davean> I don't trust anything that starts with outright lies
02:29:19 <sclv> well if it starts with outright lies it has nowhere to go but up!
02:29:40 <monochrom> @quote monochrom kripke
02:29:40 <lambdabot> monochrom says: There are truths, damn truths, and Kripke structures.
02:29:46 <monochrom> :)
02:35:14 <jbox> while we're on the topic, what's the best information-rich document format?
02:35:32 <jbox> honestly I'd say xml, as much as I hate it
02:36:12 <jbox> I was just thinking of how nice it would be to have a repository of documentation for all sorts of things, in a standardized format, possibly as literate programming
02:39:39 <monochrom> I don't know what "best" should mean. But lately I have switched from xhtml to pandoc's markdown and become much happier.
02:39:51 falafel__ joins (~falafel@2603-8000-d800-688c-34f9-26f3-71b0-5b78.res6.spectrum.com)
02:43:44 × mark___ quits (~a@p200300ef973db1754086f0a6a24fc4dd.dip0.t-ipconnect.de) (Ping timeout: 268 seconds)
02:48:04 <dsal> This is disappointing:
02:48:08 <dsal> listToMaybe :: [a] -> Maybe a
02:48:08 <dsal> listToMaybe = foldr (const . Just) Nothing
02:50:56 × falafel__ quits (~falafel@2603-8000-d800-688c-34f9-26f3-71b0-5b78.res6.spectrum.com) (Ping timeout: 245 seconds)
02:51:53 <monochrom> That's a bit of an overkill, using foldr for just 2 cases :)
02:52:12 <monochrom> Someone was trying to be cute heh
02:54:23 × xff0x quits (~xff0x@2001:1a81:5251:b200:1b67:fb84:b521:2e46) (Ping timeout: 264 seconds)
02:55:35 × neurocyte0132889 quits (~neurocyte@user/neurocyte) (Ping timeout: 264 seconds)
02:56:09 <jbox> monochrom: I love pandoc markdown!
02:56:09 xff0x joins (~xff0x@2001:1a81:526d:df00:a345:8523:ad73:f70)
02:56:22 <monochrom> :)
02:56:56 <jbox> sorry, I meant to clarify and never did: by "best", I mean "stores as much data as possible and encompasses all forseeable use-cases"
02:57:31 <jbox> e.g. with my documentation database idea above, I'd want hyperlinks and all kind of metadata. Perhaps attributes, etc. Markdown wouldn't give me anything near what I would want
02:57:40 <jbox> I'm thinking LSP-like documentation interaction
02:58:43 <dsal> monochrom: It'd be super great if weren't limited to list. Or yeah, just do the two cases.
02:59:01 <jbox> also, can someone explain `listToMaybe = foldr (const . Just) Nothing` to me? I don't understand the `(const . Just)` part :)
02:59:26 <jbox> oh yeah and while I have everyone's attention can someone please for the love of god explain to me how a List is a monad?
02:59:44 <jollygood2> const . Just is the same as \_ x -> Just x
02:59:47 × renzhi quits (~xp@2607:fa49:6500:b100::6e7f) (Ping timeout: 264 seconds)
02:59:54 <dsal> Other way around.
02:59:57 <jollygood2> yeah sorry
03:00:00 <dsal> @pl \x _ -> pure x
03:00:00 <lambdabot> const . pure
03:00:48 <dsal> Short story: If there's anything at all in the list, it returns the first element and ignores the rest.
03:01:00 <jollygood2> I'm having a lot of fun using this image processing library in haskell https://hackage.haskell.org/package/hip-1.5.6.0/docs/Graphics-Image.html
03:01:02 <dsal> (Because it ignores the accumulator, therefore laziness wins)
03:01:46 <jollygood2> mergeImages images = foldl1 leftToRight (intersperse border images) where makeImage (31, 10) (const 1)
03:02:01 <jollygood2> this merges a list of images and adds an all-white border between each one
03:07:08 × ec quits (~ec@gateway/tor-sasl/ec) (Remote host closed the connection)
03:09:59 × SeungheonOh quits (~Thunderbi@2600:1700:5168:1400:efbd:f13b:39e3:ec30) (Quit: SeungheonOh)
03:12:26 ec joins (~ec@gateway/tor-sasl/ec)
03:15:47 × wroathe quits (~wroathe@user/wroathe) (Ping timeout: 256 seconds)
03:20:10 merijn joins (~merijn@83-160-49-249.ip.xs4all.nl)
03:23:19 yauhsien joins (~yauhsien@118-167-47-187.dynamic-ip.hinet.net)
03:24:14 × xkuru quits (~xkuru@user/xkuru) (Read error: Connection reset by peer)
03:24:27 × machinedgod quits (~machinedg@24.105.81.50) (Ping timeout: 268 seconds)
03:24:52 myShoggoth joins (~myShoggot@97-120-85-195.ptld.qwest.net)
03:26:46 brainfreeze joins (~brainfree@2a03:1b20:4:f011::20d)
03:27:41 × yauhsien quits (~yauhsien@118-167-47-187.dynamic-ip.hinet.net) (Ping timeout: 256 seconds)
03:30:04 falafel joins (~falafel@2603-8000-d800-688c-34f9-26f3-71b0-5b78.res6.spectrum.com)
03:31:26 <jollygood2> am I finally going insane for thinking this isn't such a bad idea? :). https://paste.tomsmeding.com/xE6Ou9fh
03:33:27 × jmorris quits (uid433911@hampstead.irccloud.com) (Quit: Connection closed for inactivity)
03:33:35 <monochrom> Heh, it is worth the while if you use it like at 10 places in your code.
03:33:37 deadmarshal joins (~deadmarsh@95.38.228.182)
03:38:37 × deadmarshal quits (~deadmarsh@95.38.228.182) (Ping timeout: 268 seconds)
03:42:20 × ec quits (~ec@gateway/tor-sasl/ec) (Quit: ec)
03:47:45 <jbox> dsal: what does the pure mean there?
03:48:10 <dsal> jbox: It can only mean `Just` here. `pure` is just the first thing that came to mind.
03:48:28 <jbox> ohh, I see. Thanks :)
03:48:29 <dsal> > pure 1 :: Maybe Int
03:48:30 <lambdabot> Just 1
03:48:31 <jbox> dsal++
03:49:01 <yin> any reason why take is not :: Foldable f => f a -> [a] ?
03:49:07 <jbox> is there documentation for the bot somewhere? I don't want to flood the channel trying to get the usage info lol
03:49:09 dajoer joins (~david@user/gvx)
03:49:21 yauhsien joins (~yauhsien@49.216.238.61)
03:49:38 <yin> take = foldl1 const
03:50:01 <dsal> :t foldl1 const
03:50:02 <lambdabot> Foldable t => t b -> b
03:50:03 <yin> oops nevermind that
03:50:23 <yin> i meant head
03:50:26 <dsal> Deciding the result should be a list is kind of limiting.
03:50:52 <dsal> `head` is generally a bad idea if it does anything other than `foldr (const . Just) Nothing`
03:51:00 jbox is now known as reputation
03:51:19 <yin> that's why i was confusing it with take
03:51:24 reputation is now known as jbox
03:51:30 <yin> i use (take 1) instead
03:52:32 <yin> this was, as they call it, a brain fart
03:52:32 × yauhsien quits (~yauhsien@49.216.238.61) (Read error: Connection reset by peer)
03:52:39 <dsal> take 1 is a different shape sort of, though it's the same cardinality as `Maybe a`
03:52:54 <jbox> found it: https://wiki.haskell.org/Lambdabot
03:52:56 <dsal> I mean, in that it gives you either 0 things or 1 thing.
03:53:07 <yin> dsal: yes
03:53:11 × myShoggoth quits (~myShoggot@97-120-85-195.ptld.qwest.net) (Ping timeout: 264 seconds)
03:53:29 <dsal> > (listToMaybe [0..], listToMaybe [])
03:53:31 <lambdabot> (Just 0,Nothing)
03:54:11 jbox is now known as repbot
03:54:30 × merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 260 seconds)
03:54:41 repbot is now known as jbox
03:55:22 <jbox> darcs is dead, right?
03:56:04 Guest|1 joins (~Guest|1@bp.ptr231.ptrcloud.net)
03:59:59 × td_ quits (~td@94.134.91.243) (Ping timeout: 256 seconds)
04:00:46 myShoggoth joins (~myShoggot@97-120-85-195.ptld.qwest.net)
04:01:29 td_ joins (~td@muedsl-82-207-238-039.citykom.de)
04:05:11 × falafel quits (~falafel@2603-8000-d800-688c-34f9-26f3-71b0-5b78.res6.spectrum.com) (Ping timeout: 264 seconds)
04:07:12 × jbox quits (~jbox@user/jbox) (Quit: Leaving)
04:10:23 jbox joins (~jbox@user/jbox)
04:11:43 × jbox quits (~jbox@user/jbox) (Client Quit)
04:11:55 × myShoggoth quits (~myShoggot@97-120-85-195.ptld.qwest.net) (Read error: Connection reset by peer)
04:12:13 myShoggoth joins (~myShoggot@97-120-85-195.ptld.qwest.net)
04:13:09 × unit73e quits (~emanuel@2001:818:e8dd:7c00:32b5:c2ff:fe6b:5291) (Ping timeout: 268 seconds)
04:16:52 jbox joins (~jbox@user/jbox)
04:17:13 × Guest|1 quits (~Guest|1@bp.ptr231.ptrcloud.net) (Quit: Connection closed)
04:18:33 atlas joins (~jbox@user/jbox)
04:18:56 × myShoggoth quits (~myShoggot@97-120-85-195.ptld.qwest.net) (Read error: Connection reset by peer)
04:19:13 myShoggoth joins (~myShoggot@97-120-85-195.ptld.qwest.net)
04:22:02 × ralu quits (~ralu@static.211.245.203.116.clients.your-server.de) (Ping timeout: 260 seconds)
04:23:19 × lavaman quits (~lavaman@98.38.249.169) (Remote host closed the connection)
04:23:34 lavaman joins (~lavaman@98.38.249.169)
04:23:40 × lavaman quits (~lavaman@98.38.249.169) (Remote host closed the connection)
04:33:22 jinsun__ joins (~quassel@user/jinsun)
04:34:35 × jbox quits (~jbox@user/jbox) (Quit: Leaving)
04:34:44 × atlas quits (~jbox@user/jbox) (Quit: Leaving)
04:34:44 × jinsun quits (~quassel@user/jinsun) (Ping timeout: 268 seconds)
04:34:48 × img quits (~img@user/img) (Quit: ZNC 1.8.2 - https://znc.in)
04:34:51 <dsal> I think I still use it now and then.
04:34:57 fvr joins (uid503686@uxbridge.irccloud.com)
04:35:01 jbox joins (~jbox@user/jbox)
04:35:10 × jbox quits (~jbox@user/jbox) (Remote host closed the connection)
04:35:11 atlas joins (~jbox@user/jbox)
04:38:20 × drdo quits (~drdo@roach0.drdo.eu) (Quit: Ping timeout (120 seconds))
04:40:11 img joins (~img@user/img)
04:40:13 × shapr quits (~user@pool-100-36-247-68.washdc.fios.verizon.net) (Ping timeout: 256 seconds)
04:41:57 drdo joins (~drdo@roach0.drdo.eu)
04:43:31 × drdo quits (~drdo@roach0.drdo.eu) (Client Quit)
04:47:32 drdo joins (~drdo@roach0.drdo.eu)
04:48:43 × drdo quits (~drdo@roach0.drdo.eu) (Client Quit)
04:52:37 drdo joins (~drdo@roach0.drdo.eu)
04:52:48 wei2912 joins (~wei2912@138.75.71.147)
04:53:54 × drdo quits (~drdo@roach0.drdo.eu) (Client Quit)
04:56:17 drdo joins (~drdo@roach0.drdo.eu)
04:56:39 Guest|26 joins (~Guest|26@c-73-153-68-22.hsd1.co.comcast.net)
04:57:36 × ChaiTRex quits (~ChaiTRex@user/chaitrex) (Remote host closed the connection)
04:58:00 ChaiTRex joins (~ChaiTRex@user/chaitrex)
04:58:06 × waleee quits (~waleee@h-98-128-228-119.NA.cust.bahnhof.se) (Quit: WeeChat 3.3)
04:58:12 yauhsien joins (~yauhsien@118-167-47-187.dynamic-ip.hinet.net)
04:59:05 × drdo quits (~drdo@roach0.drdo.eu) (Client Quit)
04:59:15 × mvk quits (~mvk@2607:fea8:5cc3:e900::df92) (Quit: Going elsewhere)
05:00:15 × Guest|26 quits (~Guest|26@c-73-153-68-22.hsd1.co.comcast.net) (Client Quit)
05:02:00 somnolent joins (~somnolent@c-73-153-68-22.hsd1.co.comcast.net)
05:02:36 × yauhsien quits (~yauhsien@118-167-47-187.dynamic-ip.hinet.net) (Ping timeout: 245 seconds)
05:03:08 drdo joins (~drdo@roach0.drdo.eu)
05:03:18 <somnolent> Hi, I'm trying to install ghcup and it fails with a cabal error
05:03:25 <somnolent> cabal: error while loading shared libraries: libffi.so.7: cannot open shared object file: No such file or directory
05:03:26 <somnolent> "cabal new-update" failed!
05:03:35 <somnolent> Any idea how I should start debugging this?
05:04:17 × drdo quits (~drdo@roach0.drdo.eu) (Client Quit)
05:04:47 <sclv> what os
05:06:25 <somnolent> pop-os
05:06:33 <somnolent> very nearly ubuntu
05:08:52 drdo joins (~drdo@roach0.drdo.eu)
05:09:28 × drdo quits (~drdo@roach0.drdo.eu) (Client Quit)
05:10:03 ralu joins (~ralu@static.211.245.203.116.clients.your-server.de)
05:13:29 <sclv> i suspect you need to install libffi or libffi-dev?
05:13:50 drdo joins (~drdo@roach0.drdo.eu)
05:14:02 falafel joins (~falafel@2603-8000-d800-688c-34f9-26f3-71b0-5b78.res6.spectrum.com)
05:14:14 <sclv> the cabal binary expects some system libs to be around. ghcup tries to install them for you but only on distros it has a clue about
05:14:39 × drdo quits (~drdo@roach0.drdo.eu) (Client Quit)
05:15:33 <somnolent> okay, apt-cache search libffi shows libffi-dev, libffi7, and a few others
05:15:41 <somnolent> is there any way to know which I need?
05:15:44 <somnolent> libffi7?
05:15:52 <sclv> i suspect that
05:16:14 <sclv> ghcup source will list what it usually looks for if you skim it
05:18:12 <somnolent> that fixed it, thanks!
05:18:24 drdo joins (~drdo@roach0.drdo.eu)
05:19:00 gdown joins (~gavin@h69-11-248-109.kndrid.broadband.dynamic.tds.net)
05:19:50 × drdo quits (~drdo@roach0.drdo.eu) (Client Quit)
05:23:18 drdo joins (~drdo@roach0.drdo.eu)
05:25:02 × drdo quits (~drdo@roach0.drdo.eu) (Client Quit)
05:25:58 mvk joins (~mvk@2607:fea8:5cc3:e900::df92)
05:29:39 drdo joins (~drdo@roach0.drdo.eu)
05:29:59 × ishutin_ quits (~ishutin@92-249-179-61.pool.digikabel.hu) (Ping timeout: 250 seconds)
05:30:13 × drdo quits (~drdo@roach0.drdo.eu) (Client Quit)
05:31:50 ishutin joins (~ishutin@84-236-40-131.pool.digikabel.hu)
05:33:59 drdo joins (~drdo@roach0.drdo.eu)
05:35:24 × drdo quits (~drdo@roach0.drdo.eu) (Client Quit)
05:38:21 drdo joins (~drdo@roach0.drdo.eu)
05:40:00 × zebrag quits (~chris@user/zebrag) (Remote host closed the connection)
05:40:36 × drdo quits (~drdo@roach0.drdo.eu) (Client Quit)
05:44:30 drdo joins (~drdo@roach0.drdo.eu)
05:45:47 × drdo quits (~drdo@roach0.drdo.eu) (Client Quit)
05:49:02 × somnolent quits (~somnolent@c-73-153-68-22.hsd1.co.comcast.net) (Quit: Connection closed)
05:49:54 drdo joins (~drdo@roach0.drdo.eu)
05:50:44 merijn joins (~merijn@83-160-49-249.ip.xs4all.nl)
05:50:58 × drdo quits (~drdo@roach0.drdo.eu) (Client Quit)
05:53:58 drdo joins (~drdo@roach0.drdo.eu)
05:56:10 × drdo quits (~drdo@roach0.drdo.eu) (Client Quit)
05:59:27 drdo joins (~drdo@roach0.drdo.eu)
06:01:02 × yahb quits (xsbot@user/mniip/bot/yahb) (Ping timeout: 240 seconds)
06:01:13 yahb joins (xsbot@user/mniip/bot/yahb)
06:01:21 × drdo quits (~drdo@roach0.drdo.eu) (Client Quit)
06:05:11 × bgamari quits (~bgamari@64.223.227.106) (Ping timeout: 264 seconds)
06:05:12 drdo joins (~drdo@roach0.drdo.eu)
06:06:19 × superbil quits (~superbil@1-34-176-171.hinet-ip.hinet.net) (Ping timeout: 268 seconds)
06:06:32 × drdo quits (~drdo@roach0.drdo.eu) (Client Quit)
06:07:06 bgamari joins (~bgamari@70.16.103.161)
06:07:15 deadmarshal joins (~deadmarsh@95.38.228.182)
06:07:20 × slowButPresent quits (~slowButPr@user/slowbutpresent) (Quit: leaving)
06:08:03 wroathe joins (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
06:08:03 × wroathe quits (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Changing host)
06:08:03 wroathe joins (~wroathe@user/wroathe)
06:08:27 superbil joins (~superbil@1-34-176-171.hinet-ip.hinet.net)
06:10:50 drdo joins (~drdo@roach0.drdo.eu)
06:10:50 × drdo quits (~drdo@roach0.drdo.eu) (Client Quit)
06:11:09 drdo joins (~drdo@roach0.drdo.eu)
06:12:15 × img quits (~img@user/img) (Quit: ZNC 1.8.2 - https://znc.in)
06:13:01 × wroathe quits (~wroathe@user/wroathe) (Ping timeout: 245 seconds)
06:14:16 × hololeap quits (~hololeap@user/hololeap) (Remote host closed the connection)
06:15:37 img joins (~img@user/img)
06:15:45 hololeap joins (~hololeap@user/hololeap)
06:16:16 × [itchyjunk] quits (~itchyjunk@user/itchyjunk/x-7353470) (Read error: Connection reset by peer)
06:19:20 × burnsidesLlama quits (~burnsides@dhcp168-014.wadham.ox.ac.uk) (Remote host closed the connection)
06:21:59 × falafel quits (~falafel@2603-8000-d800-688c-34f9-26f3-71b0-5b78.res6.spectrum.com) (Ping timeout: 264 seconds)
06:22:46 × aplainzetakind quits (~johndoe@captainludd.powered.by.lunarbnc.net) (Quit: Free ZNC ~ Powered by LunarBNC: https://LunarBNC.net)
06:22:49 eruditass joins (uid248673@uxbridge.irccloud.com)
06:24:04 aplainzetakind joins (~johndoe@captainludd.powered.by.lunarbnc.net)
06:25:03 × merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 256 seconds)
06:29:28 wroathe joins (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
06:29:28 × wroathe quits (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Changing host)
06:29:28 wroathe joins (~wroathe@user/wroathe)
06:32:54 <energizer> has anybody made statistics on the most common functions used in popular packages?
06:34:03 falafel joins (~falafel@2603-8000-d800-688c-34f9-26f3-71b0-5b78.res6.spectrum.com)
06:34:22 × gdown quits (~gavin@h69-11-248-109.kndrid.broadband.dynamic.tds.net) (Ping timeout: 268 seconds)
06:35:25 shidima joins (~shidima@84-104-108-90.cable.dynamic.v4.ziggo.nl)
06:38:35 mei3 joins (~mei@user/mei)
06:38:42 mei3 is now known as mei
06:41:51 falafel_ joins (~falafel@cpe-76-168-195-162.socal.res.rr.com)
06:45:23 × falafel quits (~falafel@2603-8000-d800-688c-34f9-26f3-71b0-5b78.res6.spectrum.com) (Ping timeout: 264 seconds)
06:47:44 × aegon quits (~mike@174.127.249.180) (Remote host closed the connection)
06:47:47 × mvk quits (~mvk@2607:fea8:5cc3:e900::df92) (Ping timeout: 264 seconds)
06:49:35 atlas is now known as jbox
06:56:58 chomwitt joins (~chomwitt@2a02:587:dc0f:7c00:12c3:7bff:fe6d:d374)
06:59:37 × wroathe quits (~wroathe@user/wroathe) (Ping timeout: 256 seconds)
07:06:33 yauhsien joins (~yauhsien@118-167-47-187.dynamic-ip.hinet.net)
07:07:14 gehmehgeh joins (~user@user/gehmehgeh)
07:10:57 × yauhsien quits (~yauhsien@118-167-47-187.dynamic-ip.hinet.net) (Ping timeout: 256 seconds)
07:15:24 pooryorick joins (~pooryoric@87-119-174-173.tll.elisa.ee)
07:15:38 × falafel_ quits (~falafel@cpe-76-168-195-162.socal.res.rr.com) (Ping timeout: 260 seconds)
07:15:54 wroathe joins (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
07:15:54 × wroathe quits (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Changing host)
07:15:54 wroathe joins (~wroathe@user/wroathe)
07:16:33 retroid_ joins (~retro@176.255.22.26)
07:19:32 falafel_ joins (~falafel@2603-8000-d800-688c-34f9-26f3-71b0-5b78.res6.spectrum.com)
07:20:18 × wroathe quits (~wroathe@user/wroathe) (Ping timeout: 260 seconds)
07:24:23 × falafel_ quits (~falafel@2603-8000-d800-688c-34f9-26f3-71b0-5b78.res6.spectrum.com) (Ping timeout: 264 seconds)
07:26:08 lavaman joins (~lavaman@98.38.249.169)
07:30:59 × lavaman quits (~lavaman@98.38.249.169) (Ping timeout: 264 seconds)
07:31:20 mbuf joins (~Shakthi@136.185.92.113)
07:35:09 max22- joins (~maxime@lfbn-ren-1-762-224.w81-53.abo.wanadoo.fr)
07:35:58 × max22- quits (~maxime@lfbn-ren-1-762-224.w81-53.abo.wanadoo.fr) (Remote host closed the connection)
07:41:20 jmorris joins (uid433911@hampstead.irccloud.com)
07:44:23 takuan joins (~takuan@178-116-218-225.access.telenet.be)
07:50:43 yauhsien joins (~yauhsien@118-167-47-187.dynamic-ip.hinet.net)
07:54:42 <sm> jbox: it's not dead. It's restin'!
07:55:35 × yauhsien quits (~yauhsien@118-167-47-187.dynamic-ip.hinet.net) (Ping timeout: 264 seconds)
07:55:35 × xff0x quits (~xff0x@2001:1a81:526d:df00:a345:8523:ad73:f70) (Ping timeout: 264 seconds)
07:56:21 xff0x joins (~xff0x@2001:1a81:526d:df00:9ede:d6:8225:5301)
08:03:58 <sm> what's a good way to group [(a,b)] into [(a,[b])] ?
08:05:05 <sm> extra:groupSort
08:07:30 <sm> extra, that's the package I forgot
08:07:54 <sm> everything useful lives there
08:09:23 × deadmarshal quits (~deadmarsh@95.38.228.182) (Ping timeout: 264 seconds)
08:12:43 × rtsn quits (~nstr@c-c7fe225c.07-59-7570703.bbcust.telenor.se) (Ping timeout: 256 seconds)
08:13:26 rtsn joins (~nstr@c-c7fe225c.07-59-7570703.bbcust.telenor.se)
08:15:35 merijn joins (~merijn@83-160-49-249.ip.xs4all.nl)
08:22:01 × Vajb quits (~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) (Read error: Connection reset by peer)
08:22:24 Vajb joins (~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi)
08:22:52 Everything joins (~Everythin@37.115.210.35)
08:22:56 × brainfreeze quits (~brainfree@2a03:1b20:4:f011::20d) (Remote host closed the connection)
08:28:43 × mei quits (~mei@user/mei) (Read error: Connection reset by peer)
08:31:31 × jollygood2 quits (~bc8165b6@217.29.117.252) (Quit: http://www.okay.uz/ (Session timeout))
08:35:42 Pickchea joins (~private@user/pickchea)
08:36:58 acidjnk_new joins (~acidjnk@p200300d0c725147020cf3de033c5d4d3.dip0.t-ipconnect.de)
08:40:20 × eggplantade quits (~Eggplanta@2600:1700:bef1:5e10:c075:f6f7:f2c7:7314) (Remote host closed the connection)
08:48:11 × xff0x quits (~xff0x@2001:1a81:526d:df00:9ede:d6:8225:5301) (Ping timeout: 268 seconds)
08:48:33 xff0x joins (~xff0x@2001:1a81:526d:df00:e60d:1bd2:2f9f:7e19)
08:49:53 jinsun__ is now known as jinusun
08:49:57 jinusun is now known as jinsun
08:51:39 × tinwood quits (~tinwood@canonical/tinwood) (Remote host closed the connection)
08:52:39 deadmarshal joins (~deadmarsh@95.38.228.182)
08:53:23 × forell quits (~forell@user/forell) (Quit: ZNC - https://znc.in)
08:54:11 forell joins (~forell@user/forell)
08:54:41 tinwood joins (~tinwood@general.default.akavanagh.uk0.bigv.io)
08:54:41 × tinwood quits (~tinwood@general.default.akavanagh.uk0.bigv.io) (Changing host)
08:54:41 tinwood joins (~tinwood@canonical/tinwood)
09:12:16 × Sgeo quits (~Sgeo@user/sgeo) (Read error: Connection reset by peer)
09:12:55 _ht joins (~quassel@82-169-194-8.biz.kpn.net)
09:14:29 × ProofTechnique quits (sid79547@ilkley.irccloud.com) (Ping timeout: 256 seconds)
09:14:29 × hamishmack quits (sid389057@hampstead.irccloud.com) (Ping timeout: 256 seconds)
09:14:47 × JSharp quits (sid4580@lymington.irccloud.com) (Ping timeout: 264 seconds)
09:15:03 × kristjansson_ quits (sid126207@tinside.irccloud.com) (Ping timeout: 256 seconds)
09:15:19 × jakesyl_ quits (sid56879@hampstead.irccloud.com) (Ping timeout: 268 seconds)
09:15:51 JSharp joins (sid4580@lymington.irccloud.com)
09:16:11 wroathe joins (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
09:16:11 × wroathe quits (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Changing host)
09:16:11 wroathe joins (~wroathe@user/wroathe)
09:16:35 × hendi quits (sid489601@lymington.irccloud.com) (Ping timeout: 264 seconds)
09:16:35 mc47 joins (~mc47@xmonad/TheMC47)
09:16:52 jakesyl_ joins (sid56879@hampstead.irccloud.com)
09:17:04 yauhsien joins (~yauhsien@118-167-47-187.dynamic-ip.hinet.net)
09:17:33 allbery_b joins (~geekosaur@xmonad/geekosaur)
09:17:33 × geekosaur quits (~geekosaur@xmonad/geekosaur) (Killed (NickServ (GHOST command used by allbery_b)))
09:17:36 allbery_b is now known as geekosaur
09:17:42 ProofTechnique joins (sid79547@ilkley.irccloud.com)
09:18:07 hamishmack joins (sid389057@hampstead.irccloud.com)
09:18:53 hendi joins (sid489601@lymington.irccloud.com)
09:18:53 kristjansson_ joins (sid126207@tinside.irccloud.com)
09:18:59 × ephemient quits (uid407513@lymington.irccloud.com) (Ping timeout: 264 seconds)
09:18:59 × hongminhee quits (sid295@tinside.irccloud.com) (Ping timeout: 264 seconds)
09:19:01 × S11001001 quits (sid42510@ilkley.irccloud.com) (Ping timeout: 256 seconds)
09:19:18 × merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 260 seconds)
09:19:32 × jakesyl_ quits (sid56879@hampstead.irccloud.com) (Max SendQ exceeded)
09:19:35 × carter quits (sid14827@helmsley.irccloud.com) (Ping timeout: 264 seconds)
09:19:35 × elvishjerricco quits (sid237756@helmsley.irccloud.com) (Ping timeout: 264 seconds)
09:19:35 × Pent quits (sid313808@lymington.irccloud.com) (Ping timeout: 256 seconds)
09:19:35 × obviyus quits (sid415299@user/obviyus) (Ping timeout: 256 seconds)
09:19:35 × bjs quits (sid190364@user/bjs) (Ping timeout: 256 seconds)
09:19:35 × SethTisue__ quits (sid14912@ilkley.irccloud.com) (Ping timeout: 256 seconds)
09:19:35 × degraafk quits (sid71464@lymington.irccloud.com) (Ping timeout: 256 seconds)
09:19:46 SethTisue__ joins (sid14912@ilkley.irccloud.com)
09:19:50 Pent joins (sid313808@lymington.irccloud.com)
09:20:09 × NiKaN quits (sid385034@helmsley.irccloud.com) (Ping timeout: 256 seconds)
09:20:11 × aarchi quits (sid486183@uxbridge.irccloud.com) (Ping timeout: 264 seconds)
09:20:13 degraafk joins (sid71464@lymington.irccloud.com)
09:20:25 S11001001 joins (sid42510@ilkley.irccloud.com)
09:20:27 jakesyl_ joins (sid56879@hampstead.irccloud.com)
09:20:42 obviyus joins (sid415299@user/obviyus)
09:21:10 × wroathe quits (~wroathe@user/wroathe) (Ping timeout: 260 seconds)
09:21:20 carter joins (sid14827@helmsley.irccloud.com)
09:21:39 ephemient joins (uid407513@lymington.irccloud.com)
09:21:51 × amir quits (sid22336@user/amir) (Ping timeout: 256 seconds)
09:22:03 × econo quits (uid147250@user/econo) (Quit: Connection closed for inactivity)
09:23:29 aarchi joins (sid486183@uxbridge.irccloud.com)
09:23:47 × parseval quits (sid239098@helmsley.irccloud.com) (Ping timeout: 264 seconds)
09:23:55 elvishjerricco joins (sid237756@helmsley.irccloud.com)
09:24:23 × fvr quits (uid503686@uxbridge.irccloud.com) (Ping timeout: 264 seconds)
09:24:44 NiKaN joins (sid385034@helmsley.irccloud.com)
09:25:29 max22- joins (~maxime@lfbn-ren-1-762-224.w81-53.abo.wanadoo.fr)
09:25:36 amir joins (sid22336@user/amir)
09:26:23 × ehamberg quits (sid18208@hampstead.irccloud.com) (Ping timeout: 256 seconds)
09:26:23 × gaze___ quits (sid387101@helmsley.irccloud.com) (Ping timeout: 256 seconds)
09:26:35 hongminhee joins (sid295@tinside.irccloud.com)
09:26:47 × bw quits (sid2730@user/betawaffle) (Ping timeout: 264 seconds)
09:26:57 × obviyus quits (sid415299@user/obviyus) (Ping timeout: 256 seconds)
09:26:57 × rtpg quits (sid443069@ilkley.irccloud.com) (Ping timeout: 256 seconds)
09:27:07 ehamberg joins (sid18208@hampstead.irccloud.com)
09:27:08 bjs joins (sid190364@user/bjs)
09:27:24 fvr joins (uid503686@uxbridge.irccloud.com)
09:27:32 parseval joins (sid239098@helmsley.irccloud.com)
09:28:10 obviyus joins (sid415299@user/obviyus)
09:28:32 <Franciman> amesgen[m]: thanks
09:29:32 rtpg joins (sid443069@ilkley.irccloud.com)
09:29:36 gaze___ joins (sid387101@helmsley.irccloud.com)
09:29:38 bw joins (sid2730@user/betawaffle)
09:39:23 × deadmarshal quits (~deadmarsh@95.38.228.182) (Ping timeout: 264 seconds)
09:40:54 eggplantade joins (~Eggplanta@2600:1700:bef1:5e10:d49b:b47c:7bbd:b323)
09:45:06 × eggplantade quits (~Eggplanta@2600:1700:bef1:5e10:d49b:b47c:7bbd:b323) (Ping timeout: 245 seconds)
09:51:21 × notzmv quits (~zmv@user/notzmv) (Ping timeout: 245 seconds)
09:54:25 × Vajb quits (~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) (Read error: Connection reset by peer)
09:55:18 Vajb joins (~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi)
09:55:27 johnny_sitar joins (~artur@078088015209.bialystok.vectranet.pl)
09:56:28 aliosablack joins (~chomwitt@ppp-94-67-200-81.home.otenet.gr)
09:56:40 cosimone joins (~user@2001:b07:ae5:db26:a7aa:8027:6b4e:2fb3)
09:58:26 × chomwitt quits (~chomwitt@2a02:587:dc0f:7c00:12c3:7bff:fe6d:d374) (Ping timeout: 245 seconds)
10:02:15 × cosimone quits (~user@2001:b07:ae5:db26:a7aa:8027:6b4e:2fb3) (Quit: ERC (IRC client for Emacs 27.1))
10:02:50 cosimone joins (~user@2001:b07:ae5:db26:a7aa:8027:6b4e:2fb3)
10:03:28 × tcard quits (~tcard@p2878075-ipngn18701hodogaya.kanagawa.ocn.ne.jp) (Quit: Leaving)
10:04:17 mmhat joins (~mmh@55d46755.access.ecotel.net)
10:04:32 × etrepum quits (sid763@uxbridge.irccloud.com) (Quit: Connection closed for inactivity)
10:05:36 unit73e joins (~emanuel@2001:818:e8dd:7c00:32b5:c2ff:fe6b:5291)
10:06:18 <sm> what operation transforms Just n to Just (n+1) and Nothing to Just 1 ?
10:07:31 <sm> map (maybe 1 (+1))
10:07:39 <sm> thank you rubber duck
10:08:03 deadmarshal joins (~deadmarsh@95.38.228.182)
10:08:08 tcard joins (~tcard@p2878075-ipngn18701hodogaya.kanagawa.ocn.ne.jp)
10:08:24 <Hecate> yer welcome
10:08:30 <Hecate> how are you doing sm btw?
10:09:04 <sm> good thanks Hecate, other than coding a bit too late. And yourself ?
10:09:16 <f-a> wait
10:09:36 <f-a> maybe 1 (+1) value works too, withoutu the map, am I wrong?
10:10:11 <f-a> > maybe 1 (+1) Nothing
10:10:12 <lambdabot> 1
10:10:15 <f-a> > maybe 1 (+1) (Just 8)
10:10:16 <lambdabot> 9
10:10:38 lavaman joins (~lavaman@98.38.249.169)
10:11:44 <int-e> f-a: the map was just context leaking into the IRC channel I think, not part of the answer
10:12:08 <f-a> ah of course
10:12:29 <Hecate> sm: starting to wake up, got a little html encoding issue with lucid & servant
10:13:19 <unit73e> f-a, you're not wrong. that's exactly what sm wants
10:13:38 <f-a> my question: I am writing a small game library
10:14:00 <f-a> and I would like a «turn this flag on to display current fps»
10:14:22 <f-a> I know «flag» in cabal files
10:14:25 <f-a> but:
10:14:30 × fvr quits (uid503686@uxbridge.irccloud.com) (Quit: Connection closed for inactivity)
10:14:47 <f-a> • can I conditionally compile my library based on these flags?; and
10:14:54 <unit73e> hum... but that's for users correct? forcing users to use cabal... not a good practice
10:15:07 <f-a> • how will the end user of the library be able pass those flags?
10:15:13 <unit73e> he won't
10:15:17 <f-a> yeah it is for the user unit73e
10:15:18 × lavaman quits (~lavaman@98.38.249.169) (Ping timeout: 260 seconds)
10:15:26 <unit73e> that's engine logic
10:15:29 <f-a> I am of course open to suggestions
10:15:31 sm is only loosely in control of this problem. Here is more of what I needed:
10:15:31 sm ```haskell
10:15:31 sm -- Crash sites within a row, and how many times at each one.
10:15:31 sm type RowCrashes = M.Map CaveCol Int
10:15:31 sm -- Add a new crash site to a RowCrashes.
10:15:32 sm rowCrashesAdd col rowcrashes = M.alter (maybe (Just 1) (Just . (+1))) col rowcrashes
10:15:32 sm ```
10:15:47 <unit73e> you should just use an actual flag, in code
10:16:05 <unit73e> in engines there's usually a key for that
10:16:12 <sm> I wouldn't use cabal flags f-a, they aren't worth the added complexity
10:16:31 <sm> and build time
10:17:00 <f-a> sm: you would go for Bool -> … like unit73e then?
10:17:16 <unit73e> users usually want to enable/disable fps while the game is running
10:17:16 <sm> a runtime flag, certainly
10:17:25 <unit73e> not at start
10:17:35 <unit73e> like F12 shows fps
10:17:37 <unit73e> something like that
10:17:49 <unit73e> or an option in the meny
10:17:51 <unit73e> or an option in the menu
10:18:00 <sm> I wouldn't mind specifying it at start of game, but changing on the fly while game is running is ideal of course
10:18:11 <f-a> mhhh I see, thanks for the feedback
10:18:26 <sm> but why ? Isn't it something you can always provide, and game can use it or not ?
10:18:58 <f-a> I could provide it in the `draw` function :: s -> FPS (Int) -> Plane
10:18:59 × stefan-_ quits (~cri@42dots.de) (Ping timeout: 264 seconds)
10:19:16 <unit73e> enabling/disabling show fps in runtime is a convention. if you do that as an cmd option gamers will be confused why it's only available as an option.
10:19:26 <unit73e> conventions are important
10:19:48 <unit73e> yeah you should have some sort of state
10:21:30 <f-a> https://hackage.haskell.org/package/ansi-terminal-game-1.5.0.0/docs/Terminal-Game.html#t:Game these are the current logic/draw function sigs, unit73e , I guess adding it to gDrawFunction is a possibility and then if the user does not need it, they will ignore it
10:22:10 Tuplanolla joins (~Tuplanoll@91-159-69-50.elisa-laajakaista.fi)
10:22:50 stefan-_ joins (~cri@42dots.de)
10:22:55 <unit73e> you can infer the fps with ticks per second
10:23:06 <f-a> you cannot as now
10:23:30 <f-a> Ticks are the same even if frames (drawing frames) are dropped
10:23:40 <unit73e> I see
10:23:46 Midjak joins (~Midjak@82-65-111-221.subs.proxad.net)
10:23:51 <f-a> (so the game runs at the same speed on every machine)
10:24:14 <unit73e> you might want other options so perhaps it would be included in a record or data for all runtime options
10:24:33 <unit73e> and your loop would cycle with those options
10:24:52 <unit73e> one being show fps
10:25:56 <unit73e> that would also allow you to have terminal options using the same runtime options structure
10:26:56 <unit73e> that would be your options state
10:27:23 × deadmarshal quits (~deadmarsh@95.38.228.182) (Ping timeout: 264 seconds)
10:28:14 <unit73e> I wouldn't do options with something generic with a Map but I bet someone would think that way :P
10:29:37 <unit73e> speaking of game engines, I added one more example here: https://gitlab.com/unit73e/sdl2-examples
10:29:47 × yauhsien quits (~yauhsien@118-167-47-187.dynamic-ip.hinet.net) (Remote host closed the connection)
10:30:07 zer0bitz joins (~zer0bitz@dsl-hkibng31-54fae3-116.dhcp.inet.fi)
10:31:22 <unit73e> it's about texture clipping, for animations, it's not exactly how I would like yet but the idea is to pack all your sprites in N^2 textures, make a JSON with the packer, and load animations with it. I need to make a better data structure though.
10:31:36 <f-a> do they add material to lazyfoo’s ones?
10:31:47 <f-a> if so you could see if they get merged
10:31:47 <unit73e> I don't think so
10:31:58 <unit73e> lazyfoo examples are very basic
10:32:16 <f-a> they are
10:32:19 <unit73e> they're not fit for proper game development though the examples do help
10:32:39 <f-a> and it is tricky to understand why they are wrong
10:32:46 <unit73e> yeah
10:32:52 yauhsien joins (~yauhsien@118-167-47-187.dynamic-ip.hinet.net)
10:34:17 <unit73e> one example is textures should always be N^2 because VRAM is in N^2 blocks so it's more efficient to have images with that size. lazyfoo uses several images instead. but the part that really bugged me was movement.
10:34:34 <unit73e> it's not smooth at all. what lazyfoo did was press arrows and the player moves N pixels
10:34:39 <unit73e> once per keystroke
10:36:46 <unit73e> he does end up explaning scrolling but I was not impressed. also lazyfoo doesn't want ports in other languages and that was the deal breaker.
10:37:42 × yauhsien quits (~yauhsien@118-167-47-187.dynamic-ip.hinet.net) (Ping timeout: 260 seconds)
10:39:48 × tzh quits (~tzh@c-24-21-73-154.hsd1.wa.comcast.net) (Quit: zzz)
10:40:30 MiguelNegrao joins (~MiguelNeg@194.210.216.223)
10:41:48 <MiguelNegrao> Hi all. Is there a package providing a variable size tuple backed by a type list ? Something like (a,b,c) ~ Tuple '[a,b,c]
10:42:13 <unit73e> is that your real name?
10:42:23 <MiguelNegrao> yes
10:42:33 <unit73e> lol just curious
10:42:36 <MiguelNegrao> why ?
10:42:44 <unit73e> well it's somewhat funny
10:43:08 <unit73e> but don't worry mine is funny too because of tooth paste, couto is my last name
10:43:16 <MiguelNegrao> For Brazilians I guess it would be
10:43:25 <MiguelNegrao> In Portugal it is pretty normal
10:43:34 <unit73e> I'm portuguese
10:43:44 <unit73e> and yeah I guess
10:44:05 <unit73e> just to be clear
10:44:09 <MiguelNegrao> I think it comes from italian. https://en.wikipedia.org/wiki/Negroni_(surname)
10:44:16 <unit73e> you want to transform a list to a tuple?
10:44:23 <unit73e> of any size?
10:44:57 <MiguelNegrao> Not exactly, a list would have to have all elements of same type
10:45:07 <MiguelNegrao> kind of like an HList but using normal tuples
10:45:15 × aliosablack quits (~chomwitt@ppp-94-67-200-81.home.otenet.gr) (Quit: Leaving)
10:45:24 <unit73e> why not just use an HList?
10:46:36 sm found this needful:
10:46:36 sm ```haskell
10:46:36 sm insertOrUpdate :: Ord k => v -> (v -> v) -> k -> M.Map k v -> M.Map k v
10:46:36 sm insertOrUpdate newval valupdatefn key = M.alter (maybe (Just newval) (Just . valupdatefn)) key
10:46:36 sm ```
10:47:31 <MiguelNegrao> I guess I thought people are more familiar with tuples
10:47:48 <MiguelNegrao> Something similar is implemented here https://hackage.haskell.org/package/vivid-0.5.1.0/docs/Vivid-SynthDef-TypesafeArgs.html
10:47:54 <MiguelNegrao> the VarArg type
10:48:05 <MiguelNegrao> Sorry VarList
10:48:41 <unit73e> it's not that different. there's data.tuple.select but I would just use an HList
10:48:57 <MiguelNegrao> Ok, thanks.
10:49:07 <MiguelNegrao> Good to know there are other Haskelers in Portugal. :-)
10:49:32 <unit73e> yup it's already hard enough to convince functional programming is good
10:49:59 <MiguelNegrao> Do you use Haskell at work ?
10:50:11 <unit73e> unfortunately no
10:50:23 <unit73e> you probably know portugal is a java country
10:50:25 × mniip quits (mniip@libera/staff/mniip) (Quit: This page is intentionally left blank.)
10:51:22 <unit73e> but I might take an haskell project if the opportunity arrives
10:52:02 chomwitt joins (~chomwitt@2a02:587:dc12:3f00:12c3:7bff:fe6d:d374)
10:54:29 × MiguelNegrao quits (~MiguelNeg@194.210.216.223) (Quit: Client closed)
10:57:45 yauhsien joins (~yauhsien@118-167-47-187.dynamic-ip.hinet.net)
10:57:48 mniip joins (mniip@libera/staff/mniip)
11:00:52 alx741 joins (~alx741@181.196.68.187)
11:08:06 xkuru joins (~xkuru@user/xkuru)
11:13:08 jgeerds joins (~jgeerds@55d41b94.access.ecotel.net)
11:15:47 merijn joins (~merijn@83-160-49-249.ip.xs4all.nl)
11:17:45 × yauhsien quits (~yauhsien@118-167-47-187.dynamic-ip.hinet.net) (Remote host closed the connection)
11:18:22 yauhsien joins (~yauhsien@118-167-47-187.dynamic-ip.hinet.net)
11:22:58 × yauhsien quits (~yauhsien@118-167-47-187.dynamic-ip.hinet.net) (Ping timeout: 260 seconds)
11:23:55 × FragByte quits (~christian@user/fragbyte) (Quit: Quit)
11:25:44 FragByte joins (~christian@user/fragbyte)
11:30:14 DNH joins (~DNH@8.43.122.53)
11:30:32 × DNH quits (~DNH@8.43.122.53) (Client Quit)
11:37:54 × max22- quits (~maxime@lfbn-ren-1-762-224.w81-53.abo.wanadoo.fr) (Remote host closed the connection)
11:38:43 max22- joins (~maxime@lfbn-ren-1-762-224.w81-53.abo.wanadoo.fr)
11:40:07 × pooryorick quits (~pooryoric@87-119-174-173.tll.elisa.ee) (Ping timeout: 256 seconds)
11:41:55 pooryorick joins (~pooryoric@87-119-174-173.tll.elisa.ee)
11:42:50 eggplantade joins (~Eggplanta@2600:1700:bef1:5e10:d49b:b47c:7bbd:b323)
11:46:13 × acidjnk_new quits (~acidjnk@p200300d0c725147020cf3de033c5d4d3.dip0.t-ipconnect.de) (Ping timeout: 265 seconds)
11:48:01 × eggplantade quits (~Eggplanta@2600:1700:bef1:5e10:d49b:b47c:7bbd:b323) (Ping timeout: 245 seconds)
11:48:41 yauhsien joins (~yauhsien@118-167-47-187.dynamic-ip.hinet.net)
11:50:19 × merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 256 seconds)
11:52:28 jollygood2 joins (~bc8165b6@217.29.117.252)
11:53:47 × yauhsien quits (~yauhsien@118-167-47-187.dynamic-ip.hinet.net) (Ping timeout: 264 seconds)
11:56:03 MiguelNegrao joins (~MiguelNeg@194.210.216.113)
11:56:15 × MiguelNegrao quits (~MiguelNeg@194.210.216.113) (Client Quit)
12:02:38 × Pickchea quits (~private@user/pickchea) (Ping timeout: 260 seconds)
12:06:08 × caubert quits (~caubert@136.244.111.235) (Quit: WeeChat 3.2)
12:07:12 caubert joins (~caubert@136.244.111.235)
12:07:39 × wei2912 quits (~wei2912@138.75.71.147) (Quit: Lost terminal)
12:14:20 × jassob1 quits (~jassob@h-98-128-167-112.NA.cust.bahnhof.se) (Ping timeout: 246 seconds)
12:22:52 yauhsien joins (~yauhsien@118-167-47-187.dynamic-ip.hinet.net)
12:27:50 × yauhsien quits (~yauhsien@118-167-47-187.dynamic-ip.hinet.net) (Ping timeout: 260 seconds)
12:28:00 burnsidesLlama joins (~burnsides@dhcp168-014.wadham.ox.ac.uk)
12:28:38 × max22- quits (~maxime@lfbn-ren-1-762-224.w81-53.abo.wanadoo.fr) (Remote host closed the connection)
12:29:14 max22- joins (~maxime@lfbn-ren-1-762-224.w81-53.abo.wanadoo.fr)
12:35:57 __monty__ joins (~toonn@user/toonn)
12:38:00 Guest80 joins (~Guest80@pd95ed7c0.dip0.t-ipconnect.de)
12:45:37 × jgeerds quits (~jgeerds@55d41b94.access.ecotel.net) (Ping timeout: 268 seconds)
12:46:02 × _ht quits (~quassel@82-169-194-8.biz.kpn.net) (Ping timeout: 260 seconds)
12:46:15 _ht joins (~quassel@37.120.218.148)
12:52:36 × jbox quits (~jbox@user/jbox) (Ping timeout: 245 seconds)
12:59:44 mark___ joins (~a@p200300ef973db1754086f0a6a24fc4dd.dip0.t-ipconnect.de)
13:02:37 v01d4lph4 joins (~v01d4lph4@user/v01d4lph4)
13:03:13 zava joins (~zava@ip5f5bdf0f.dynamic.kabel-deutschland.de)
13:09:03 × max22- quits (~maxime@lfbn-ren-1-762-224.w81-53.abo.wanadoo.fr) (Ping timeout: 268 seconds)
13:09:06 Pickchea joins (~private@user/pickchea)
13:22:00 × jpds quits (~jpds@gateway/tor-sasl/jpds) (Ping timeout: 276 seconds)
13:22:20 [itchyjunk] joins (~itchyjunk@user/itchyjunk/x-7353470)
13:23:29 xdej joins (~xdej@quatramaran.salle-s.org)
13:23:41 jpds joins (~jpds@gateway/tor-sasl/jpds)
13:25:41 × mark___ quits (~a@p200300ef973db1754086f0a6a24fc4dd.dip0.t-ipconnect.de) (Quit: WeeChat 3.0.1)
13:26:38 yauhsien joins (~yauhsien@118-167-47-187.dynamic-ip.hinet.net)
13:27:22 <Profpatsch> tryError :: forall exc a. (Exception exc) => IO a -> IO (Either Error a)
13:27:25 <Profpatsch> tryError io = Exc.try @exc io <&> first exceptionToError
13:27:36 <Profpatsch> GHC complains at the type application “not in scope: type variable exc”
13:27:46 <Profpatsch> But I explicitely brought it into scope with the forall, no?
13:27:55 <hpc> ScopedTypeVariables maybe?
13:27:57 <Profpatsch> Does it need to be mentioned on the right side of => to be in scope?
13:28:19 <Profpatsch> hpc: It asks for AllowAmbiguousTypeVAriables now
13:28:30 <Profpatsch> Hm
13:29:03 <Profpatsch> Ah, apparently that was a problem before TypeApplications https://stackoverflow.com/questions/45128492/what-is-allowambiguoustypes-and-why-is-it-needed-in-this-forall-example
13:29:10 <Profpatsch> So it looks like I’m safe more or less
13:29:20 <Profpatsch> is gonna require TypeApplications from downstream hm
13:29:29 skippy joins (~slice@user/slice)
13:29:30 <hpc> yeah, you just have to call tryError @Whatever do {...}
13:31:18 × yauhsien quits (~yauhsien@118-167-47-187.dynamic-ip.hinet.net) (Ping timeout: 260 seconds)
13:32:28 <Profpatsch> that was the idea, yeah
13:33:00 <Profpatsch> But then the code won’t compile before 8.0.1 hmm
13:34:35 × _ht quits (~quassel@37.120.218.148) (Ping timeout: 256 seconds)
13:35:02 _ht joins (~quassel@82-169-194-8.biz.kpn.net)
13:45:17 eggplantade joins (~Eggplanta@2600:1700:bef1:5e10:d49b:b47c:7bbd:b323)
13:46:17 merijn joins (~merijn@83-160-49-249.ip.xs4all.nl)
13:48:27 jkaye joins (~jkaye@2601:281:8300:7530:2d7e:ffab:3b55:862f)
13:48:29 Guest42 joins (~Guest42@eth-west-pareq2-46-193-4-100.wb.wifirst.net)
13:48:48 <Guest42> what't the state of game developement in functional programming?
13:49:17 <int-e> <insert state-less joke here>
13:49:37 <jkaye> https://wiki.haskell.org/Game_Development
13:49:41 × eggplantade quits (~Eggplanta@2600:1700:bef1:5e10:d49b:b47c:7bbd:b323) (Ping timeout: 245 seconds)
13:51:42 <f-a> Guest42: that is a large topic, any specific requirements?
13:52:02 <f-a> gaming goes from roguelikes to VR stuff
13:53:48 machinedgod joins (~machinedg@24.105.81.50)
13:55:42 <f-a> also: join #haskell-game , lots of useful discussion going there
13:57:02 × skippy quits (~slice@user/slice) (Quit: cya)
13:57:03 slowButPresent joins (~slowButPr@user/slowbutpresent)
13:57:25 slice joins (~slice@user/slice)
13:58:33 × slice quits (~slice@user/slice) (Client Quit)
14:09:35 <Guest42> f-a: well let's say we're talking about a 2d roguelike like Dead Cells
14:11:09 <Guest42> how does one model the "game loop" in a pure functional way? will it perform badly compared to imperative languages?
14:12:17 lavaman joins (~lavaman@98.38.249.169)
14:12:23 bitdex joins (~bitdex@gateway/tor-sasl/bitdex)
14:12:47 <f-a> Guest42: I would advise to start with sdl2, if you do not fancy that, shop around. A «game loop» can be made pure in various ways (callbacks, etc.)
14:13:09 <f-a> for performance, use the appropriate tools (criterion, etc.) and you will be fine
14:15:44 <f-a> game making seldom is a clean job
14:16:09 <Franciman> it surely is not the most exciting thing around
14:16:13 <Franciman> https://www.patreon.com/posts/58563886 it being
14:16:55 <Franciman> as you can see this is not functional programming
14:17:05 × lavaman quits (~lavaman@98.38.249.169) (Ping timeout: 256 seconds)
14:17:20 <Franciman> yet it seems an impacting thing
14:17:49 × sydddddd quits (~syd@cpc91646-hart11-2-0-cust432.11-3.cable.virginm.net) (Quit: Lost terminal)
14:19:26 × unit73e quits (~emanuel@2001:818:e8dd:7c00:32b5:c2ff:fe6b:5291) (Ping timeout: 265 seconds)
14:19:43 <Guest80> The game loop can be a function that takes the previous game-state, an event (input or timer) and creates the new state. Performance depends on the complexity of your state and the computations you do on it. Of course this can vary very much depending on your game. But for many games this shouldn't be an issue.
14:19:58 <maerwald> Guest42: maybe check out LambdaHack
14:20:47 × merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 264 seconds)
14:21:09 <Guest42> Guest80: my intuition tells me that the game state will have to be copied every frame so there is the overhead of recalculating it and GC-ing it, no?
14:21:35 <Guest42> maerwald: cool!
14:22:43 <jkaye> Guest42, not necessarily, immutability allows for all sorts of optimizations that would not otherwise be possible
14:23:16 <jkaye> E.g. if an immutable pure state is being replaced, the compiler can freely perform the update in place since it knows that the previous state would just be discarded anyway
14:23:22 <Guest80> Guest42: Depends on the datastructures you use. If most of the state is static (lets say the "world") and only some dynamic objects change then the new state will refer to the same static stuff in each iteration. So static objects won't be copied/reallocated. They will reuse the same values in each iteration.
14:23:33 <jkaye> So it's a little different than what you might expect from the imperative (C++ etc) world
14:25:07 <Guest42> jkaye: do I have ways to explicitly make the compiler (say GHC), to "change this data structure in place" ?
14:25:08 <Guest80> In Haskell you usually end up with a kind of "copy on write" model (if think in imperative terms).
14:26:08 <Guest80> Guest42: You shouldn't think that way if you want to write pure functional programs.
14:27:08 <Guest80> Of course you can... but why use Haskell when you want to mess around with mutable state? ;D
14:29:28 <Guest42> well I imagine you can build quite nice abstractions if you get the critical parts to perform right
14:29:49 max22- joins (~maxime@2a01cb08833598001b74a41a00edb48c.ipv6.abo.wanadoo.fr)
14:30:00 <Guest42> LambdaHack is quite a nice place to start for me, reading their code will be a pleasure
14:32:42 × jollygood2 quits (~bc8165b6@217.29.117.252) (Quit: http://www.okay.uz/ (Ping timeout))
14:32:42 × johnny_sitar quits (~artur@078088015209.bialystok.vectranet.pl) (Read error: Connection reset by peer)
14:35:18 × gawen quits (~gawen@user/gawen) (Quit: cya)
14:35:31 zebrag joins (~chris@user/zebrag)
14:35:39 zaquest joins (~notzaques@5.130.79.72)
14:36:39 gawen joins (~gawen@user/gawen)
14:37:06 shapr joins (~user@pool-100-36-247-68.washdc.fios.verizon.net)
14:37:20 <fluxit> Guest42: If you're open to more options, I'm having a good experience writing a game using the brick library. https://samtay.github.io/posts/introduction-to-brick got me started.
14:37:21 <shapr> good MORNING!
14:37:31 jassob1 joins (~jassob@h-98-128-167-112.NA.cust.bahnhof.se)
14:37:32 × Guest80 quits (~Guest80@pd95ed7c0.dip0.t-ipconnect.de) (Ping timeout: 256 seconds)
14:39:40 EvanR joins (~evan@user/evanr)
14:46:00 eggplantade joins (~Eggplanta@2600:1700:bef1:5e10:7032:7aef:17c2:c830)
14:48:22 jgeerds joins (~jgeerds@55d41b94.access.ecotel.net)
14:50:06 × eggplantade quits (~Eggplanta@2600:1700:bef1:5e10:7032:7aef:17c2:c830) (Ping timeout: 245 seconds)
14:51:35 johnny_sitar joins (~artur@078088015209.bialystok.vectranet.pl)
14:52:04 × tafa quits (~tafa@2a04:52c0:101:85c::1) (Quit: ZNC - https://znc.in)
14:53:05 renzhi joins (~xp@2607:fa49:6500:b100::6e7f)
14:54:24 tafa joins (~tafa@2a04:52c0:101:85c::1)
14:54:39 × max22- quits (~maxime@2a01cb08833598001b74a41a00edb48c.ipv6.abo.wanadoo.fr) (Remote host closed the connection)
14:55:39 zincy_ joins (~zincy@2a00:23c8:970c:4801:350f:7ee:191a:6f65)
14:57:59 × Midjak quits (~Midjak@82-65-111-221.subs.proxad.net) (Ping timeout: 264 seconds)
14:58:58 × pavonia quits (~user@user/siracusa) (Quit: Bye!)
15:05:37 son0p joins (~ff@181.136.122.143)
15:06:59 × zincy_ quits (~zincy@2a00:23c8:970c:4801:350f:7ee:191a:6f65) (Remote host closed the connection)
15:07:52 zincy_ joins (~zincy@host86-181-60-139.range86-181.btcentralplus.com)
15:08:28 × Vajb quits (~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) (Read error: Connection reset by peer)
15:09:23 × johnny_sitar quits (~artur@078088015209.bialystok.vectranet.pl) (Ping timeout: 264 seconds)
15:10:18 Vajb joins (~Vajb@2001:999:50:707f:90e9:e423:1236:7744)
15:11:41 yauhsien joins (~yauhsien@118-167-47-187.dynamic-ip.hinet.net)
15:12:00 pretty_dumm_guy joins (trottel@gateway/vpn/protonvpn/prettydummguy/x-88029655)
15:12:01 × jmorris quits (uid433911@hampstead.irccloud.com) (Quit: Connection closed for inactivity)
15:14:47 × Everything quits (~Everythin@37.115.210.35) (Quit: leaving)
15:19:09 × yauhsien quits (~yauhsien@118-167-47-187.dynamic-ip.hinet.net) (Remote host closed the connection)
15:25:03 yauhsien joins (~yauhsien@118-167-47-187.dynamic-ip.hinet.net)
15:27:59 × jkaye quits (~jkaye@2601:281:8300:7530:2d7e:ffab:3b55:862f) (Ping timeout: 264 seconds)
15:34:19 × burnsidesLlama quits (~burnsides@dhcp168-014.wadham.ox.ac.uk) (Remote host closed the connection)
15:38:12 Lycurgus joins (~juan@98.4.112.204)
15:40:07 × EvanR quits (~evan@user/evanr) (Ping timeout: 268 seconds)
15:41:58 × Vajb quits (~Vajb@2001:999:50:707f:90e9:e423:1236:7744) (Ping timeout: 268 seconds)
15:42:17 × sprout_ quits (~quassel@2a02:a467:ccd6:1:9825:20f3:f69:55d5) (Ping timeout: 250 seconds)
15:46:20 sprout joins (~quassel@2a02:a467:ccd6:1:34a5:6053:7bcf:2391)
15:47:54 waleee joins (~waleee@h-98-128-228-119.NA.cust.bahnhof.se)
15:52:51 × machinedgod quits (~machinedg@24.105.81.50) (Ping timeout: 256 seconds)
15:55:56 × xff0x quits (~xff0x@2001:1a81:526d:df00:e60d:1bd2:2f9f:7e19) (Ping timeout: 245 seconds)
15:56:45 xff0x joins (~xff0x@2001:1a81:526d:df00:b864:176f:3a64:2e83)
15:58:47 × yauhsien quits (~yauhsien@118-167-47-187.dynamic-ip.hinet.net) (Remote host closed the connection)
15:59:09 Guest80 joins (~Guest80@pd95ed7c0.dip0.t-ipconnect.de)
16:00:58 × Lycurgus quits (~juan@98.4.112.204) (Quit: Exeunt)
16:04:57 Hanicef joins (~gustaf@81-229-9-108-no92.tbcn.telia.com)
16:06:19 burnsidesLlama joins (~burnsides@dhcp168-014.wadham.ox.ac.uk)
16:09:00 yauhsien joins (~yauhsien@118-167-47-187.dynamic-ip.hinet.net)
16:12:07 × burnsidesLlama quits (~burnsides@dhcp168-014.wadham.ox.ac.uk) (Ping timeout: 256 seconds)
16:13:49 × yauhsien quits (~yauhsien@118-167-47-187.dynamic-ip.hinet.net) (Ping timeout: 256 seconds)
16:15:43 wroathe joins (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
16:15:43 × wroathe quits (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Changing host)
16:15:43 wroathe joins (~wroathe@user/wroathe)
16:16:52 merijn joins (~merijn@83-160-49-249.ip.xs4all.nl)
16:17:50 × jgeerds quits (~jgeerds@55d41b94.access.ecotel.net) (Ping timeout: 260 seconds)
16:26:13 × dsrt^ quits (~dsrt@h50.174.139.63.static.ip.windstream.net) (Remote host closed the connection)
16:28:33 <zincy_> Is there a nice way of dealing duplicate record field names and lens?
16:29:02 <zincy_> I have two record types that share some field names and am not sure what to do
16:29:21 <zincy_> Prefixing would work but a bit tedious
16:30:08 yauhsien joins (~yauhsien@118-167-47-187.dynamic-ip.hinet.net)
16:30:40 <Taneb> zincy_: lens has makeFieldsNoPrefix which may be useful for you
16:31:03 <zincy_> thanks!
16:31:11 × yauhsien quits (~yauhsien@118-167-47-187.dynamic-ip.hinet.net) (Remote host closed the connection)
16:31:45 yauhsien joins (~yauhsien@118-167-47-187.dynamic-ip.hinet.net)
16:33:05 × shapr quits (~user@pool-100-36-247-68.washdc.fios.verizon.net) (Ping timeout: 256 seconds)
16:36:29 × yauhsien quits (~yauhsien@118-167-47-187.dynamic-ip.hinet.net) (Ping timeout: 256 seconds)
16:37:35 MoC joins (~moc@user/moc)
16:37:53 × dolio quits (~dolio@130.44.130.54) (Quit: ZNC 1.8.2 - https://znc.in)
16:43:10 dolio joins (~dolio@130.44.130.54)
16:47:48 eggplantade joins (~Eggplanta@2600:1700:bef1:5e10:7032:7aef:17c2:c830)
16:49:48 × wroathe quits (~wroathe@user/wroathe) (Ping timeout: 268 seconds)
16:51:12 × merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 265 seconds)
16:52:03 burnsidesLlama joins (~burnsides@dhcp168-014.wadham.ox.ac.uk)
16:52:11 × eggplantade quits (~Eggplanta@2600:1700:bef1:5e10:7032:7aef:17c2:c830) (Ping timeout: 245 seconds)
16:53:01 × mbuf quits (~Shakthi@136.185.92.113) (Quit: Leaving)
16:53:48 yauhsien joins (~yauhsien@118-167-47-187.dynamic-ip.hinet.net)
16:54:39 × MoC quits (~moc@user/moc) (Quit: Konversation terminated!)
16:54:49 jakalx parts (~jakalx@base.jakalx.net) ()
16:58:11 jakalx joins (~jakalx@base.jakalx.net)
16:59:01 machinedgod joins (~machinedg@24.105.81.50)
17:02:42 johnny_sitar joins (~artur@078088015209.bialystok.vectranet.pl)
17:04:37 × jzsinatra quits (~jzsinatra@88-114-238-31.elisa-laajakaista.fi) (Ping timeout: 268 seconds)
17:06:12 Digit joins (~user@user/digit)
17:07:25 × dajoer quits (~david@user/gvx) (Quit: leaving)
17:07:56 MoC joins (~moc@user/moc)
17:11:52 timCF joins (~timCF@m91-129-99-212.cust.tele2.ee)
17:14:27 × Pickchea quits (~private@user/pickchea) (Ping timeout: 256 seconds)
17:20:19 × yauhsien quits (~yauhsien@118-167-47-187.dynamic-ip.hinet.net) (Remote host closed the connection)
17:24:23 × sprout quits (~quassel@2a02:a467:ccd6:1:34a5:6053:7bcf:2391) (Ping timeout: 264 seconds)
17:25:33 jess joins (~jess@libera/staff/jess)
17:26:01 jzsinatra joins (~jzsinatra@88-114-238-31.elisa-laajakaista.fi)
17:30:42 × zincy_ quits (~zincy@host86-181-60-139.range86-181.btcentralplus.com) (Remote host closed the connection)
17:31:22 <dsal> zincy_: There's also classy lenses, thought that may end up more confusing depending on the collisions. If a bunch of the things have a "_name" field that's `Text` then classy lens will let you access any of them via a `name` lens.
17:36:46 sprout joins (~quassel@2a02:a467:ccd6:1:34a5:6053:7bcf:2391)
17:41:37 × sprout quits (~quassel@2a02:a467:ccd6:1:34a5:6053:7bcf:2391) (Ping timeout: 268 seconds)
17:45:18 yauhsien joins (~yauhsien@118-167-47-187.dynamic-ip.hinet.net)
17:55:20 hippoid joins (~hippoid@c-98-220-13-8.hsd1.il.comcast.net)
18:01:23 × yauhsien quits (~yauhsien@118-167-47-187.dynamic-ip.hinet.net) (Remote host closed the connection)
18:01:23 sprout joins (~quassel@2a02:a467:ccd6:1:34a5:6053:7bcf:2391)
18:01:58 yauhsien joins (~yauhsien@118-167-47-187.dynamic-ip.hinet.net)
18:02:37 × hippoid quits (~hippoid@c-98-220-13-8.hsd1.il.comcast.net) (Ping timeout: 256 seconds)
18:03:01 hippoid joins (~hippoid@c-98-220-13-8.hsd1.il.comcast.net)
18:08:11 × hippoid quits (~hippoid@c-98-220-13-8.hsd1.il.comcast.net) (Ping timeout: 264 seconds)
18:13:00 nehsou^ joins (~nehsou@h50.174.139.63.static.ip.windstream.net)
18:14:04 lavaman joins (~lavaman@98.38.249.169)
18:18:59 × lavaman quits (~lavaman@98.38.249.169) (Ping timeout: 264 seconds)
18:18:59 tzh joins (~tzh@c-24-21-73-154.hsd1.or.comcast.net)
18:21:36 max22- joins (~maxime@lfbn-ren-1-762-224.w81-53.abo.wanadoo.fr)
18:22:20 Vajb joins (~Vajb@2001:999:83:e6dd:c80d:a972:83d6:40ce)
18:22:52 shapr joins (~user@2607:fb90:18d1:24ad:cf6e:d458:40ab:e571)
18:23:25 hippoid joins (~hippoid@c-98-220-13-8.hsd1.il.comcast.net)
18:27:13 zincy_ joins (~zincy@2a00:23c8:970c:4801:350f:7ee:191a:6f65)
18:28:07 × hippoid quits (~hippoid@c-98-220-13-8.hsd1.il.comcast.net) (Ping timeout: 256 seconds)
18:30:42 <shapr> Anyone know how to use cabal as a library to get all the dependencies from a given cabal file?
18:31:06 <sclv> Cabal-the-library can't get anything
18:31:26 <shapr> Fair enough, I'm happy to hand it the files as bytestring or whatever
18:31:34 <sclv> cabal the binary can unpack all deps, but idk if it can do it recursively
18:32:02 <sclv> oh i see, you mean just "determine"?
18:32:04 <shapr> I'm happy to hand all the files to cabal
18:32:10 <sclv> not like fetch
18:32:21 <shapr> yes, I'm back on "build a graph of dependencies" from a big pile of cabal files
18:32:36 <shapr> I could write my own parser, but would rather not.
18:32:39 <sclv> the best way is to "cabal configure" and then read the plan.json
18:32:40 × eldritch_ quits (~eldritch@user/eldritch/x-9272577) (Quit: bye)
18:32:44 × yauhsien quits (~yauhsien@118-167-47-187.dynamic-ip.hinet.net) (Remote host closed the connection)
18:32:45 <shapr> oh that sounds easy
18:32:46 <sclv> if you want to calculate recursive deps
18:33:01 <sclv> if you want one level deps direct from the cabal file then you just use Cabal the library to parse the file
18:33:09 <shapr> I want a command line tool though, so using cabal as a library would be nicer.
18:33:11 econo joins (uid147250@user/econo)
18:33:13 mrmaximuzz joins (~mrmaximuz@178.71.193.198)
18:33:36 yauhsien joins (~yauhsien@118-167-47-187.dynamic-ip.hinet.net)
18:34:01 hippoid joins (~hippoid@c-98-220-13-8.hsd1.il.comcast.net)
18:34:41 <maerwald> dependencies depend on architecture, flags etc... it isn't that straight forward with Cabal library
18:35:05 <maerwald> there are a couple of distro tools that do that, e.g. gentoos hackport
18:35:09 <sclv> for just parsing a cabal file its this: https://hackage.haskell.org/package/Cabal-3.6.2.0/docs/Distribution-PackageDescription-Parsec.html
18:35:40 <maerwald> https://github.com/gentoo-haskell/hackport/blob/master/Merge/Dependencies.hs
18:35:41 <sclv> you can find the entry point of cabal-install into `configure` and invoke it directly instead of via the command line as well -- sec
18:35:44 × mrmaximuzz quits (~mrmaximuz@178.71.193.198) (Read error: Connection reset by peer)
18:36:00 eldritch_ joins (~eldritch@user/eldritch/x-9272577)
18:36:19 <sclv> actually, only unreleased cabal exposes cabal-install as a lib, so i wouldn't recommend that yet
18:37:06 × Vajb quits (~Vajb@2001:999:83:e6dd:c80d:a972:83d6:40ce) (Ping timeout: 268 seconds)
18:38:20 × yauhsien quits (~yauhsien@118-167-47-187.dynamic-ip.hinet.net) (Ping timeout: 268 seconds)
18:39:01 <sclv> shapr: for your use case you're in a monorepo and want to calc for a set of packages, so my suggestion is make one package that depends on all the others, configure it once and forall, and read the graph right out of plan.json
18:39:03 Vajb joins (~Vajb@2001:999:83:e6dd:c80d:a972:83d6:40ce)
18:39:33 <sclv> (i _think_ that you'll get the full dep tree and not just a streamlined one)
18:39:45 <shapr> sclv: hm, that may not give me the info I want
18:39:46 <shapr> but it might
18:40:06 <maerwald> Also check https://hackage.haskell.org/package/cabal-plan
18:40:34 Pickchea joins (~private@user/pickchea)
18:40:48 <shapr> that could help
18:43:49 × Vajb quits (~Vajb@2001:999:83:e6dd:c80d:a972:83d6:40ce) (Ping timeout: 265 seconds)
18:47:21 eggplantade joins (~Eggplanta@2600:1700:bef1:5e10:7032:7aef:17c2:c830)
18:47:24 merijn joins (~merijn@83-160-49-249.ip.xs4all.nl)
18:47:47 × hippoid quits (~hippoid@c-98-220-13-8.hsd1.il.comcast.net) (Ping timeout: 264 seconds)
18:54:47 allbery_b joins (~geekosaur@xmonad/geekosaur)
18:54:47 × geekosaur quits (~geekosaur@xmonad/geekosaur) (Killed (NickServ (GHOST command used by allbery_b)))
18:54:50 allbery_b is now known as geekosaur
18:55:31 deadmarshal joins (~deadmarsh@95.38.228.182)
18:57:13 ees joins (~user@pool-108-18-30-46.washdc.fios.verizon.net)
18:57:52 × zincy_ quits (~zincy@2a00:23c8:970c:4801:350f:7ee:191a:6f65) (Remote host closed the connection)
18:58:11 Sgeo joins (~Sgeo@user/sgeo)
18:58:37 <ddb> int-e, geekosaur: I finally got it figured out. The last bit is that instead of @admin you do admin in the console.
19:00:10 Guest15 joins (~Guest15@nat-users-79-98-157-003.pnet.netair.net)
19:01:05 <geekosaur> I'd probably stick it in the config file, but whatever
19:01:34 <geekosaur> I don't think you use @ prefixes in the console since there isn't anything else to read commands the bot doesn't understand
19:01:47 × max22- quits (~maxime@lfbn-ren-1-762-224.w81-53.abo.wanadoo.fr) (Ping timeout: 268 seconds)
19:02:17 <int-e> right. it's a bit confusing because the `> ` prefix is still the same
19:02:45 × Hanicef quits (~gustaf@81-229-9-108-no92.tbcn.telia.com) (Quit: leaving)
19:03:06 hippoid joins (~hippoid@c-98-220-13-8.hsd1.il.comcast.net)
19:03:11 × Guest15 quits (~Guest15@nat-users-79-98-157-003.pnet.netair.net) (Client Quit)
19:03:48 <ddb> so I'm just running lambdabot, is there a param to pass in the config file?
19:05:35 <geekosaur> I don't understand the question. Param for what?
19:05:45 <ddb> which file to use as the config file
19:05:57 <int-e> ddb: there's a `-e` to run commands, and an `rc` command to source a file: -e 'rc online-min.rc'
19:06:17 <ddb> ah perfect
19:06:42 <geekosaur> oh, right, I'd forgotten that part
19:06:52 <int-e> https://github.com/lambdabot/lambdabot/tree/master/lambdabot/scripts should really have an example run script, tsk
19:06:59 <geekosaur> only remembered the usual config file was online.rc, not how you used it :)
19:07:11 <geekosaur> it's been a decade
19:07:43 × shapr quits (~user@2607:fb90:18d1:24ad:cf6e:d458:40ab:e571) (Remote host closed the connection)
19:07:46 × hippoid quits (~hippoid@c-98-220-13-8.hsd1.il.comcast.net) (Ping timeout: 260 seconds)
19:07:56 shapr joins (~user@2607:fb90:18d1:24ad:216e:e60a:4c82:5164)
19:07:58 <ddb> indeed, that's ok, I've got it working well now. I'll update it to use a config file on next boot.
19:08:17 <geekosaur> hope they fixed the bug in the version I was running where I had to hit enter every so often in the console so the IRC connect and join would actually happen in the background :)
19:08:40 <geekosaur> was always annoying when I had to restart the bot
19:08:45 <ddb> I did have another question though, now that it's working
19:08:50 <ddb> sometimes mueval seems to take a long time
19:08:55 <ddb> > product [1..5]
19:08:56 <lambdabot> 120
19:08:59 <ddb> I got a timeout once by doing that
19:09:13 <geekosaur> occasionally this one times out as well
19:09:40 <ddb> cool, all the other modules seem to run quite quickly
19:09:48 <int-e> mueval is slow, especially when compiled statically... which it *forces* by default
19:10:17 <hpc> mueval is also just in general a whole new process
19:10:20 <hpc> it has to load /everything/
19:10:23 hippoid joins (~hippoid@c-98-220-13-8.hsd1.il.comcast.net)
19:10:23 <hpc> it's not just typing into ghci
19:10:38 <ddb> ooh that makes sense then
19:10:43 <hpc> even () can time out
19:10:45 fendor joins (~fendor@178.115.56.25.wireless.dyn.drei.com)
19:10:53 <int-e> (it does ghc-options: -Wall -static -threaded in its .cabal file which is quite terrible IMHO)
19:11:18 <int-e> It's quite a bit faster if you patch that out and build a dynamic version
19:12:23 <johnjay> is there a deeper reason that 5*-3 makes ghci complain about a varible out of scope *-?
19:12:39 <johnjay> i expect something more like invalid operator or something
19:12:45 <geekosaur> johnjay, you can make new operators on the fly
19:13:01 <geekosaur> hyow would it know when to stop doing so and treat the - as something else?
19:13:08 <hpc> > let x *- y = "surprise!" in 5*-3
19:13:09 <lambdabot> "surprise!"
19:13:10 <awpr> the way the lexical syntax is defined is that adjacent runs of symbols are single operators
19:13:18 <hpc> > let x *- y = "surprise!" in 5 * -3
19:13:19 <lambdabot> error:
19:13:19 <lambdabot> Precedence parsing error
19:13:19 <lambdabot> cannot mix ‘*’ [infixl 7] and prefix `-' [infixl 6] in the same infi...
19:13:23 <int-e> hpc: well, a standalong mueval command with hot cache and nothing else running in parallel takes a bit over a second on lambdabot's VPS. the timeout is 5s. it can overshoot by running several muevals in parallel and perhaps some other VM on the same server causing the shared libraries to be evicted from memory
19:13:24 <hpc> > let x *- y = "surprise!" in 5 * (-3)
19:13:25 <lambdabot> -15
19:13:29 <hpc> johnjay: ^
19:13:35 <awpr> same reason you can get messed up comments by writing e.g. `--|`
19:13:50 <int-e> Anyway, it works most of the time these days.
19:13:56 <int-e> (as far as I can see)
19:13:56 HurdyGurdyBurdy joins (~HurdyGurd@user/hurdygurdyburdy)
19:15:41 <johnjay> int-e: that latter one raises more questions lol
19:15:44 <johnjay> but ok
19:15:52 <int-e> the reason why the dynamic version of mueval is faster is that then it loads libraries as shared libraries with the system's dynamic linker; the static version uses ghc's own linker from the RTS which can load standard .o files... which I think has more relocations to do, and definitely has more files to load and is less optimized.
19:16:10 <geekosaur> johnjay, consider that --> is a perfectly valid operator name
19:16:42 <geekosaur> but | as the start of a comment is part of haddock markup. so some people initially leave off the space before the | and get an unpleasant surprise
19:18:17 <hpc> maybe base could define (--|) and (--^) with a custom error
19:18:38 <geekosaur> wonder how many packages that would break :)
19:19:20 <hpc> according to hoogle, it would break https://hackage.haskell.org/package/persistent-documentation-0.1.0.4/docs/Database-Persist-Documentation.html#v:-45--45--94-
19:19:26 <hpc> so hmm, maybe not then
19:19:34 <geekosaur> anyway xmonad is an example of using --> as an operator. (this breaks a remarkable number of syntax coloring engines, too :)
19:20:27 zincy_ joins (~zincy@host86-181-60-139.range86-181.btcentralplus.com)
19:20:57 <geekosaur> actually, hm, that mnakes me wonder if they did the same thing
19:21:13 <maerwald> if it's not that, then CPP or TH/QuasiQuotes will break your tools
19:21:28 <geekosaur> nope, just borrowed the idea I guess
19:21:45 × zincy_ quits (~zincy@host86-181-60-139.range86-181.btcentralplus.com) (Remote host closed the connection)
19:21:59 × merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 264 seconds)
19:23:21 yauhsien joins (~yauhsien@118-167-47-187.dynamic-ip.hinet.net)
19:23:47 × hippoid quits (~hippoid@c-98-220-13-8.hsd1.il.comcast.net) (Ping timeout: 264 seconds)
19:26:07 × shapr quits (~user@2607:fb90:18d1:24ad:216e:e60a:4c82:5164) (Remote host closed the connection)
19:27:36 × yauhsien quits (~yauhsien@118-167-47-187.dynamic-ip.hinet.net) (Ping timeout: 245 seconds)
19:27:58 <geekosaur> johnjay, the other half of the answer is that Haskell is functional, so an operator is just a variable whose value is *usually* a function
19:28:17 <johnjay> ah
19:29:28 <johnjay> just for my sanity haskell doesn't care about whitespace correct?
19:29:37 <johnjay> so let x=5 and let x = 5 and let x = 5 are the same?
19:29:46 <geekosaur> the lexer uses different rules to identify infix variables vs. prefix, but they're both variables as far as haskell is concerned
19:29:50 <geekosaur> they are the same
19:30:03 <geekosaur> although there are a few extensions which break this
19:30:34 <geekosaur> already BangPatterns made foo ! bar different from foo !bar a decade ago
19:30:56 <geekosaur> and several other such things have crept in over the years
19:32:19 Jeanne-Kamikaze joins (~Jeanne-Ka@static-198-54-131-104.cust.tzulo.com)
19:33:20 <geekosaur> most recently RecordDotSyntax completely confused how dots are parsed in various contexts including spacing, so they don't break . as an operator
19:34:06 <yin> data Nat = 1 | 2 | 3 | 4 ... ; data Int = Neg Nat | Zero | Pos Nat -- this is my fantasy
19:34:08 geekosaur seriously thinks we could have lived without that complication, dots are hard enough to parse as it is
19:34:50 <geekosaur> (in fact ghc does not parse them according to the Report, which shows in obscure ways related to qualified names)
19:34:53 <johnjay> why does it allow "let 2 = 7" in ghci?
19:35:07 <geekosaur> because it's a patttern that can never be referenced
19:35:23 <geekosaur> so it never finds out that the pattern fails
19:35:36 <geekosaur> > let 2 = 7 then 5
19:35:37 <lambdabot> <hint>:1:11: error: parse error on input ‘then’
19:35:43 <geekosaur> whoo[ps duh
19:35:48 <geekosaur> > let 2 = 7 in 5
19:35:49 <lambdabot> 5
19:36:07 × deadmarshal quits (~deadmarsh@95.38.228.182) (Ping timeout: 256 seconds)
19:36:11 <geekosaur> one of the weird corner cases in how pattern matching works
19:36:52 <johnjay> TIL
19:37:03 <johnjay> i was trying to generate an error to get more familiar with the error messages
19:39:06 <yin> > let Nothing = pure () in 1
19:39:07 <lambdabot> 1
19:39:09 <geekosaur> > let 2 = !7 in 5
19:39:10 <lambdabot> <hint>:1:9: error: parse error on input ‘!’
19:39:25 <geekosaur> right, wrong side duh
19:39:34 <geekosaur> > let !2 = 7 in 5
19:39:35 <lambdabot> *Exception: <interactive>:3:5-10: Non-exhaustive patterns in 2
19:40:09 <yin> it should be simple enough to make patterns that bind no variables illegal, no?
19:40:21 Vajb joins (~Vajb@n1s4o3bcbx01a3mj1-2.v6.elisa-mobile.fi)
19:40:40 <johnjay> i have main = do let result = 5 print result in file.hs
19:40:42 <hpc> that Nothing pattern doesn't bind any variables
19:41:00 <johnjay> how do i actually see the result of main? ghci file.hs just says it loaded the module
19:41:10 <hpc> johnjay: you have to run main
19:41:11 <geekosaur> do :main
19:41:19 <johnjay> you mean in ghci?
19:41:21 <yin> hoc: any reason not to have the cmpiler disallow it?
19:41:21 <geekosaur> you can also pass "command line" arguments that way
19:41:21 <hpc> ghci is strictly a repl
19:41:30 <geekosaur> :main foo bar baz
19:41:31 <johnjay> ah ok
19:41:31 <hpc> it's not like running python foo.py
19:41:37 <janus> does haskell really require a dollar before 'do' while purescript doesn't? seems like i can get away with omitting it there
19:41:56 <yin> janus: there's an extension for that
19:42:08 <janus> yin: BlockArguments?
19:42:08 <yin> dont rememeber the name though
19:42:13 <hpc> janus: it's a parsing thing, unfortunately
19:42:20 <yin> janus: yes i think that's the one
19:42:30 max22- joins (~maxime@2a01cb0883359800a1957cb129df87ea.ipv6.abo.wanadoo.fr)
19:42:34 <geekosaur> yeh, BlockArguments
19:43:09 <janus> i have heard people don't like it in haskell... wonder if the purescript version has the same problems
19:43:17 <johnjay> oh i see i can do 'ghc asdf.hs' as long as I have llvm in path
19:43:25 <johnjay> also i have llvm13 and 12 for some reason in /opt
19:43:25 <geekosaur> there's also runghc
19:43:31 × Guest80 quits (~Guest80@pd95ed7c0.dip0.t-ipconnect.de) (Ping timeout: 256 seconds)
19:44:15 <yin> so, is there any reason not to disallow patterns that don't bind variables?
19:44:17 <geekosaur> (there's also ghc -e "expression")
19:44:44 <geekosaur> technically a pattern using a wildcard doesn't bind a variable
19:44:47 <awpr> `case x of 0 -> "zero"; _ -> "nonzero"`
19:45:06 <yin> i mean in let expressions
19:45:11 <awpr> does `-Wincomplete-uni-patterns` complain about this?
19:46:38 <geekosaur> by the time the compiler can tell it has a pattern in a let vs. a case, can it still tell that there's no bindings because a wildcard was used?
19:46:40 <yin> > let _ = 0 in 1
19:46:42 <lambdabot> 1
19:46:54 <yin> :/
19:46:56 × max22- quits (~maxime@2a01cb0883359800a1957cb129df87ea.ipv6.abo.wanadoo.fr) (Remote host closed the connection)
19:47:03 zincy_ joins (~zincy@2a00:23c8:970c:4801:350f:7ee:191a:6f65)
19:47:23 <awpr> I don't see any problem with that one. it's unnecessary, sure, but so is `id $ id id $ id 5`
19:47:57 <geekosaur> or a lambda (including the implicit one in do's <-)?
19:48:33 <geekosaur> basically I think it comes down to having to carry too much state around internally that would be used only to prevent a weird corner case most people don't care about
19:48:50 falafel joins (~falafel@2603-8000-d800-688c-34f9-26f3-71b0-5b78.res6.spectrum.com)
19:49:30 <yin> λ let Nothing = pure 1 in ()
19:49:30 <yin> <interactive>:1:5: warning: [-Wunused-pattern-binds] This pattern-binding binds no variables: Nothing = pure 1
19:49:33 <yin> ()
19:50:02 × Vajb quits (~Vajb@n1s4o3bcbx01a3mj1-2.v6.elisa-mobile.fi) (Ping timeout: 265 seconds)
19:50:09 <yin> why not make this an error instead of the warning? isn't the check there anyways?
19:50:14 max22- joins (~maxime@lfbn-ren-1-762-224.w81-53.abo.wanadoo.fr)
19:51:05 <c_wraith> the main reason I'd think of to not make it an error is to make generating code easier.
19:51:32 <awpr> the program is still well-defined and can still be compiled in that case, so it's not really an error. `-Werror` is meant for this kind of situation, where you want the compiler to reject weird / suspicious things that are technically okay
19:51:34 <c_wraith> I have written template-haskell that generates a non-binding let expression before, just as an additional layer of type-checking.
19:52:19 eldritch_ is now known as eldritch
19:52:51 <yin> weirdness
19:53:05 <johnjay> i'm amazed that Tru && False and rue && False both suggest I meant True. phenomenal!
19:53:06 × pbrisbin quits (~patrick@pool-173-49-152-45.phlapa.fios.verizon.net) (Quit: WeeChat 3.3)
19:53:32 <johnjay> but ru doesn't
19:53:54 <yin> johnjay: you should like copilot
19:56:27 <johnjay> yin: maybe i'm missing something. it says it helps you verify c programs
19:56:37 <johnjay> wouldn't you just verify c programs from the c programs
19:56:39 × zincy_ quits (~zincy@2a00:23c8:970c:4801:350f:7ee:191a:6f65) (Remote host closed the connection)
19:56:55 zincy_ joins (~zincy@2a00:23c8:970c:4801:350f:7ee:191a:6f65)
19:56:56 × zincy_ quits (~zincy@2a00:23c8:970c:4801:350f:7ee:191a:6f65) (Read error: Connection reset by peer)
19:57:18 <yin> https://copilot.github.com/
19:58:07 <yin> you look videos of people using it, it's insane
19:58:12 <johnjay> videos huh
19:58:23 <geekosaur> I wonder if verify means the same thing to you that it does to us
19:59:07 <yin> narrator: "it does not"
19:59:19 <johnjay> you probably mean something like formally verify
19:59:32 <geekosaur> yep
19:59:34 <johnjay> like using hoare logic to prove something always terminates
20:00:53 hippoid joins (~hippoid@c-98-220-13-8.hsd1.il.comcast.net)
20:01:51 lavaman joins (~lavaman@98.38.249.169)
20:02:36 <johnjay> amusingly ( and ) give different errors. the former says mismatched parentheses but the later says parse error
20:03:27 <geekosaur> I sus[pect something about the brace insertion logic leads to that because it has to track opened/unclosed parens to get it right
20:03:44 <geekosaur> (brace insertion is relevant to do/let/case blocks)
20:04:00 <johnjay> well i should probably learn me more haskell before continuing
20:04:11 <johnjay> all punctuation was similar except : and $
20:04:21 <johnjay> $ said i need to use TemplateHaskell and : just said loaded empty module
20:04:22 <geekosaur> and is something you'll rarely care about unless looking to cimplement a Haskell compiler
20:04:41 <johnjay> i always try to learn the error messages of any software i use
20:04:50 <johnjay> because they are bad and require lots of interpretation to use
20:04:53 <geekosaur> right, $ at the top level (or the prompt in ghci) expects to insert a TH splice
20:05:11 × juhp quits (~juhp@128.106.188.220) (Ping timeout: 264 seconds)
20:05:16 <geekosaur> : in ghci not followed by a command repeats the previous command
20:05:20 <yin> : is the mandatory prefix to infix data constructors
20:05:25 <johnjay> suggestin I meant 'True' instead of 'Tru' frankly shocking to me
20:05:47 × hippoid quits (~hippoid@c-98-220-13-8.hsd1.il.comcast.net) (Ping timeout: 264 seconds)
20:05:54 <johnjay> geekosaur: not that i can tell. it says OK, no modules loaded.
20:06:06 <yin> the '$' operator has *some magic* going on iirc but it's otherwise not special at all
20:06:25 <yin> mind that ghci commands start with :
20:06:38 <geekosaur> right, and : by itself repeats the previous command
20:07:02 <yin> ah right
20:07:04 <geekosaur> which will be a (possibly null) load at the start of a session, if you have not typed any :-commands yet
20:07:59 <johnjay> apparently it is the last thing
20:08:05 juhp joins (~juhp@128.106.188.220)
20:08:33 <dolio> ($) isn't special in 9.2 anymore, right?
20:08:35 <johnjay> if i type 5 though then print it says in stmt of form print it
20:08:44 <johnjay> where is "print it" coming from?
20:09:09 <awpr> dolio: right, IIRC the only special-ness left is that it has the ImpredicativeTypes behavior even when ImpredicativeTypes is not enabled
20:09:21 <geekosaur> dolio, pretty sure this is just typing "$" to ghci, which would try to expand a TH splice but TH was disabled
20:09:43 <geekosaur> awpr, not even that because with QuickLook it's impredicative anyway
20:10:11 <geekosaur> hm, maybe
20:10:30 <awpr> my recollection is that quick look is enabled by ImpredicativeTypes, with the exception that $ always has it
20:11:04 <geekosaur> johnjay, the way ghci works, it evaluates an expression, then binds the result to `it`, then executes `print it` or a replacement that can be specified by an option
20:11:27 <geekosaur> except that if the expression is in IO then it assumes the output was done by the IO action
20:12:00 <geekosaur> but see https://downloads.haskell.org/ghc/latest/docs/html/users_guide/ghci.html#using-a-custom-interactive-printing-function
20:12:08 <geekosaur> which would then replace `print it`
20:12:40 <johnjay> hmm good i'll use the manual as well
20:12:59 × eggplantade quits (~Eggplanta@2600:1700:bef1:5e10:7032:7aef:17c2:c830) (Remote host closed the connection)
20:13:10 <yin> interesting! it = print it
20:13:16 <johnjay> the first message it says was no instance for (Show (() -> IO ()))
20:13:43 <johnjay> i guess they are really one statement but separated by bullet points
20:13:45 <yin> @type print
20:13:46 <lambdabot> Show a => a -> IO ()
20:15:56 hippoid joins (~hippoid@c-98-220-13-8.hsd1.il.comcast.net)
20:17:20 <yin> you can't print a function because they are opaque. the nly way to know what a function does is to run it
20:17:36 <yin> > print id
20:17:37 <lambdabot> error:
20:17:37 <lambdabot> • No instance for (Typeable a0) arising from a use of ‘print’
20:17:37 <lambdabot> • In the expression: print id
20:17:48 <yin> > print print
20:17:49 <lambdabot> <IO ()>
20:17:58 <yin> wait what?
20:18:19 <awpr> https://hackage.haskell.org/package/base-4.16.0.0/docs/Text-Show-Functions.html
20:18:36 <awpr> er, not exactly that, but apparently a similar orphan instance
20:19:28 <yin> > show id
20:19:29 <lambdabot> error:
20:19:29 <lambdabot> • No instance for (Typeable a0) arising from a use of ‘show’
20:19:29 <lambdabot> • In the expression: show id
20:19:33 <yin> > show print
20:19:34 <lambdabot> "<() -> IO ()>"
20:19:44 <awpr> uh, Typeable?
20:19:46 <yin> when did this happen?
20:20:05 <awpr> I would guess this is a lambdabot-specific orphan instance that's OVERLAPPABLE
20:20:06 × hippoid quits (~hippoid@c-98-220-13-8.hsd1.il.comcast.net) (Ping timeout: 245 seconds)
20:21:02 <awpr> e.g. `instance {-# OVERLAPPABLE #-} Typeable a => Show a where showsPrec x = showChar '<' . showsPrec 0 (typeOf x) . showChar '>'`
20:22:46 <geekosaur> yes
20:23:26 <geekosaur> @version
20:23:26 <lambdabot> lambdabot 5.3.0.1
20:23:27 <lambdabot> git clone https://github.com/lambdabot/lambdabot
20:24:20 <geekosaur> hm, not there
20:24:23 <geekosaur> @where L.hs
20:24:24 <lambdabot> what lambdabot has in scope is at https://silicon.int-e.eu/lambdabot/State/Pristine.hs
20:27:13 <geekosaur> hm, can't find the ShowFun module
20:27:24 <geekosaur> @hoogle ShowFun
20:27:25 <lambdabot> TextShow.Generic data ShowFunsB arity a
20:27:25 <lambdabot> TextShow.Generic data ShowFunsT arity a
20:27:25 <lambdabot> TextShow.Generic data ShowFunsTL arity a
20:28:35 × falafel quits (~falafel@2603-8000-d800-688c-34f9-26f3-71b0-5b78.res6.spectrum.com) (Ping timeout: 264 seconds)
20:33:40 falafel joins (~falafel@2603-8000-d800-688c-34f9-26f3-71b0-5b78.res6.spectrum.com)
20:36:26 × chomwitt quits (~chomwitt@2a02:587:dc12:3f00:12c3:7bff:fe6d:d374) (Read error: Connection reset by peer)
20:37:01 acidjnk_new joins (~acidjnk@p200300d0c725147020cf3de033c5d4d3.dip0.t-ipconnect.de)
20:37:10 × Jeanne-Kamikaze quits (~Jeanne-Ka@static-198-54-131-104.cust.tzulo.com) (Quit: Leaving)
20:38:11 × falafel quits (~falafel@2603-8000-d800-688c-34f9-26f3-71b0-5b78.res6.spectrum.com) (Ping timeout: 264 seconds)
20:38:17 acidjnk_new3 joins (~acidjnk@p200300d0c736cb18d4b31450c12316ac.dip0.t-ipconnect.de)
20:41:43 fresheyeball joins (~fresheyeb@c-76-25-93-164.hsd1.co.comcast.net)
20:42:14 × acidjnk_new quits (~acidjnk@p200300d0c725147020cf3de033c5d4d3.dip0.t-ipconnect.de) (Ping timeout: 265 seconds)
20:46:50 eggplantade joins (~Eggplanta@2600:1700:bef1:5e10:7032:7aef:17c2:c830)
20:50:14 random-jellyfish joins (~random-je@user/random-jellyfish)
20:52:27 × fresheyeball quits (~fresheyeb@c-76-25-93-164.hsd1.co.comcast.net) (Quit: WeeChat 2.9)
20:55:47 zincy_ joins (~zincy@host86-181-60-139.range86-181.btcentralplus.com)
20:58:50 jkaye joins (~jkaye@2601:281:8300:7530:663a:b6d3:3081:a6b4)
20:58:51 Vajb joins (~Vajb@npscn2i6yp8h48ih-3.v6.elisa-mobile.fi)
21:01:47 eggplant_ joins (~Eggplanta@2600:1700:bef1:5e10:d32:7961:c8e7:76c1)
21:03:04 × _ht quits (~quassel@82-169-194-8.biz.kpn.net) (Remote host closed the connection)
21:04:29 × lavaman quits (~lavaman@98.38.249.169) (Ping timeout: 268 seconds)
21:04:51 gdown joins (~gavin@h69-11-248-109.kndrid.broadband.dynamic.tds.net)
21:05:11 × eggplantade quits (~Eggplanta@2600:1700:bef1:5e10:7032:7aef:17c2:c830) (Ping timeout: 264 seconds)
21:08:48 × Vajb quits (~Vajb@npscn2i6yp8h48ih-3.v6.elisa-mobile.fi) (Ping timeout: 268 seconds)
21:15:10 Vajb joins (~Vajb@2001:999:54:373a:391d:ee55:f345:f09a)
21:18:07 × Pickchea quits (~private@user/pickchea) (Ping timeout: 256 seconds)
21:18:13 merijn joins (~merijn@83-160-49-249.ip.xs4all.nl)
21:19:34 etrepum joins (uid763@uxbridge.irccloud.com)
21:19:56 × Vajb quits (~Vajb@2001:999:54:373a:391d:ee55:f345:f09a) (Ping timeout: 265 seconds)
21:21:03 × azimut_ quits (~azimut@gateway/tor-sasl/azimut) (Ping timeout: 276 seconds)
21:21:20 × FinnElija quits (~finn_elij@user/finn-elija/x-0085643) (Remote host closed the connection)
21:21:48 hippoid joins (~hippoid@c-98-220-13-8.hsd1.il.comcast.net)
21:23:21 × hippoid quits (~hippoid@c-98-220-13-8.hsd1.il.comcast.net) (Client Quit)
21:25:27 FinnElija joins (~finn_elij@user/finn-elija/x-0085643)
21:26:56 hippoid joins (~hippoid@c-98-220-13-8.hsd1.il.comcast.net)
21:28:10 × m5zs7k quits (aquares@web10.mydevil.net) (Ping timeout: 260 seconds)
21:30:03 Vajb joins (~Vajb@2001:999:85:46d7:d6a4:d6c1:950b:ce99)
21:31:31 × hippoid quits (~hippoid@c-98-220-13-8.hsd1.il.comcast.net) (Quit: leaving)
21:32:26 azimut joins (~azimut@gateway/tor-sasl/azimut)
21:33:18 m5zs7k joins (aquares@web10.mydevil.net)
21:34:26 × Vajb quits (~Vajb@2001:999:85:46d7:d6a4:d6c1:950b:ce99) (Ping timeout: 265 seconds)
21:37:34 × shidima quits (~shidima@84-104-108-90.cable.dynamic.v4.ziggo.nl) (Ping timeout: 260 seconds)
21:39:27 Vajb joins (~Vajb@2001:999:85:46d7:d6a4:d6c1:950b:ce99)
21:46:25 × Vajb quits (~Vajb@2001:999:85:46d7:d6a4:d6c1:950b:ce99) (Ping timeout: 268 seconds)
21:52:11 × merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 245 seconds)
21:58:04 Pickchea joins (~private@user/pickchea)
21:59:28 × Pickchea quits (~private@user/pickchea) (Remote host closed the connection)
22:00:28 mvk joins (~mvk@2607:fea8:5cc3:e900::df92)
22:01:45 × zincy_ quits (~zincy@host86-181-60-139.range86-181.btcentralplus.com) (Remote host closed the connection)
22:01:47 aegon joins (~mike@174.127.249.180)
22:02:51 ec joins (~ec@gateway/tor-sasl/ec)
22:06:06 × [itchyjunk] quits (~itchyjunk@user/itchyjunk/x-7353470) (Read error: Connection reset by peer)
22:12:19 × max22- quits (~maxime@lfbn-ren-1-762-224.w81-53.abo.wanadoo.fr) (Quit: Leaving)
22:12:50 × econo quits (uid147250@user/econo) (Quit: Connection closed for inactivity)
22:17:40 × fendor quits (~fendor@178.115.56.25.wireless.dyn.drei.com) (Read error: Connection reset by peer)
22:24:10 yauhsien joins (~yauhsien@118-167-47-187.dynamic-ip.hinet.net)
22:26:50 unit73e joins (~emanuel@2001:818:e8dd:7c00:32b5:c2ff:fe6b:5291)
22:28:17 Vajb joins (~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi)
22:28:57 × yauhsien quits (~yauhsien@118-167-47-187.dynamic-ip.hinet.net) (Ping timeout: 256 seconds)
22:31:03 Feuermagier joins (~Feuermagi@user/feuermagier)
22:34:00 allbery_b joins (~geekosaur@xmonad/geekosaur)
22:34:00 × geekosaur quits (~geekosaur@xmonad/geekosaur) (Killed (NickServ (GHOST command used by allbery_b)))
22:34:02 × zer0bitz quits (~zer0bitz@dsl-hkibng31-54fae3-116.dhcp.inet.fi) (Ping timeout: 260 seconds)
22:34:03 allbery_b is now known as geekosaur
22:34:25 jgeerds joins (~jgeerds@55d41b94.access.ecotel.net)
22:37:11 <energizer> Hello. I'm interested in functional programming and performance. If I understand right, there are *some* algorithms whose fastest imperative implementation is significantly faster than the fastest functional version. Is there a good place to read about which algorithms are "solved" from this perspective and which are still slower than imperative?
22:38:39 tfeb joins (~tfb@88.98.95.237)
22:39:39 tfeb is now known as tfb
22:39:48 <maerwald> what qualifies a functional algorithm? Recursive? No mutable updates?
22:39:53 × gehmehgeh quits (~user@user/gehmehgeh) (Quit: Leaving)
22:40:10 slice joins (~slice@user/slice)
22:40:22 <geekosaur> https://en.wikipedia.org/wiki/Purely_functional_data_structure
22:40:39 <geekosaur> which among other things links to Okasaki's thesis work on it
22:40:50 <energizer> yes, no mutable updates
22:40:55 <geekosaur> (also to his book but that's not free)
22:40:59 <maerwald> geekosaur: that link doesn't seem to talk about algorithms
22:42:08 <geekosaur> usually the algorithm falls out from the data structure, like how lists in Haskell are loops encoded as data
22:42:34 f-a parts (f2a@f2a.jujube.ircnow.org) ()
22:42:37 <maerwald> can't relate
22:43:36 <maerwald> I only remember the blog about quicksort in haskell and the argument that quicksort IS an imperative algorithm
22:43:56 <maerwald> because it uses mutable updates
22:44:14 <maerwald> (which was then implemented via ST)
22:44:45 <maerwald> but here you say *implementation*
22:45:05 <maerwald> where I feel it's more like: there are two algorithms to solve the same issue, which one is faster?
22:45:31 <maerwald> and I doubt there is an answer
22:45:35 × tfb quits (~tfb@88.98.95.237) (Quit: died)
22:45:56 <energizer> i didnt know the word for what you're calling an "issue" so i used algorithm but yeah "algorithm" isn't the right word
22:46:46 kadir joins (~kadir@78.178.105.36)
22:47:42 <maerwald> I just feel the definitions aren't really precise enough to give useful answers
22:49:10 <maerwald> is graham scan imperative or functional?
22:49:22 <c_wraith> graham scan works fine either way
22:49:28 <maerwald> yes
22:49:39 <energizer> in other words - for each task, how much of a slowdown do you suffer if you disallow mutation
22:49:46 <c_wraith> look at something like Tarjan's Union-Find for really wanting mutable data
22:49:52 <energizer> some tasks the difference is small, for some big
22:50:03 <energizer> i want to see a list
22:50:21 <c_wraith> I doubt anyone's ever made such a list
22:50:23 jmorris joins (uid433911@hampstead.irccloud.com)
22:50:43 <maerwald> and even if you did... it's hard to attribute the performance difference to the paradigm
22:50:49 × pwug quits (~pwug@user/pwug) (Quit: Leaving)
22:50:53 <energizer> is it?
22:50:57 <c_wraith> it's the sort of thing you look at a description of the algorithm and go "how much does this depend on mutation of shared values?"
22:51:09 <maerwald> energizer: well, which language/compiler etc are you using?
22:51:53 × Vajb quits (~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) (Read error: Connection reset by peer)
22:51:59 <maerwald> and... what's really "functional" then? You're not producing code for functional architectures
22:52:12 <c_wraith> maerwald: I really feel like you're working hard to ignore the core question
22:52:43 <c_wraith> maerwald: "how much does the performance of these algorithms depend on mutation" is a perfectly fine question
22:52:46 <maerwald> c_wraith: no, I reverse engineered some imperative algorithms to haskell that were "imperative" and I was never able to tell a difference
22:52:55 <Franciman> maerwald: functional is theoretically sound
22:53:15 deadmarshal joins (~deadmarsh@95.38.117.102)
22:53:28 <geekosaur> doesn't help that a compiler like ghc will happily optimize functional code to code that does mutations behind your back
22:53:34 <energizer> i can tell the difference https://koerbitz.me/posts/Efficient-Quicksort-in-Haskell.html
22:53:35 <maerwald> e.g. the half-edge algorithm
22:53:45 <maerwald> (or data structure)
22:53:49 <geekosaur> and purity gives it considerable leeway to do so, because it knows when it's safe
22:53:53 <c_wraith> energizer: that's not really a fair question, as the Haskell version is *not* quicksort
22:54:04 <maerwald> geekosaur: exactly
22:54:07 Vajb joins (~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi)
22:54:20 <maerwald> so even if you did compare implementations, what are you really comparing?
22:54:30 <maerwald> probably compilers?
22:54:56 × ees quits (~user@pool-108-18-30-46.washdc.fios.verizon.net) (Read error: Connection reset by peer)
22:55:01 <energizer> some compilers exist and some don't
22:55:05 pwug joins (~pwug@user/pwug)
22:55:12 <c_wraith> why not do something obvious then? Kruskall's algorithm on a complete graph, comparing a mutation-based union-find with one that uses no observable mutation?
22:56:44 <c_wraith> (nevermind that you'd use Djikstra's algorithm in basically any real-world case)
22:56:46 × random-jellyfish quits (~random-je@user/random-jellyfish) (Ping timeout: 256 seconds)
22:57:14 ees joins (~user@pool-108-18-30-46.washdc.fios.verizon.net)
22:57:36 × deadmarshal quits (~deadmarsh@95.38.117.102) (Ping timeout: 245 seconds)
23:01:23 <dsal> energizer: I think your thinking is backwards. It's not "how much of a slowdown do you suffer if you disallow mutation" it's "how many bugs do you need to think about if you allow mutation"
23:01:50 <c_wraith> energizer: for what it's worth, it's known that under the Random Access Model, an algorithm containing no mutation will never be worse than an O(log n) factor additional work on top of an algorithm containing mutation. This comes from the fact that you can simulate mutable memory with a balanced binary tree.
23:02:30 <dsal> We have things like ST that do allow us to put mutation in a box and implement an algorithm inside that box where performance matters, but it's far easier to get to a working solution, even in heavy concurrency and stuff when stuff you're referencing isn't being mutated under you.
23:02:33 <energizer> dsal: i'm assuming correct code in my question
23:03:01 × nehsou^ quits (~nehsou@h50.174.139.63.static.ip.windstream.net) (Remote host closed the connection)
23:03:10 <geekosaur> I feel like that's "point missed"
23:03:37 <maerwald> mutation can be contained reasonably
23:04:20 <energizer> geekosaur: i know functional code can be helpful for avoiding bugs but i dont want to introduce other dimensions into the question i'm asking about which is performance.
23:05:00 <geekosaur> you're assuming they're disjoint, among other things
23:05:11 <dsal> At a level up, do you want it to be easier to make something work correctly, or do you want it to be easier to make something faster?
23:05:20 <dsal> Faster is interesting because fast enough is usually a pretty low bar.
23:05:52 <energizer> that's not the situation i'm talking about. i'm talking about where "fast enough" is a high bar
23:06:09 <dsal> I got tired of obscure, difficult to reproduce mosquitto bugs, so I wrote an mqtt broker in Haskell and didn't look back.
23:06:33 <maerwald> c_wraith: that's interesting... I think that might be the only thing you can reasonably assess... "performance" is much more fuzzy. You could pick the same language for both implementations, but even then: maybe the language optimizes for one case better
23:07:08 <maerwald> So you're always comparing compilers as well
23:07:10 <energizer> c_wraith: i agree that is interesting
23:07:11 <dsal> Too much hypothetical here. Immutability makes some things faster. It makes many things easier. Sometimes mutating stuff makes things faster. You can mutate things in those cases, but not completely freely.
23:08:13 <energizer> dsal: right. i'm looking to fill in the "some things" and "many things" with some specifics
23:08:32 <energizer> ie /which/ things and by how much
23:09:08 <energizer> but c_wraith says probably there is no list of these, and i believe them
23:09:28 <geekosaur> part of this is the question assumes there is a simple list. I'm not so sure it's simple
23:09:32 <dsal> These mostly show up for me in doing Advent of Code or something. Where you have a problem that requires mutating a vector or array in a loop and then yielding a result. I'll do the easy thing first, get an answer/test case and stuff. And then I'll rewrite it with ST and get a speedup.
23:09:47 <dsal> It's more like, I encountered a problem and my solution isn't fast enough. How do I make my solution faster?
23:10:10 <dsal> There are lots of ways to speed most things up. Most things don't need sped up, but when you have something that does, you have to consider what's making the particular thing slow.
23:10:33 <dsal> Sometimes, you just have a bad algorithm. Or you're doing some work more than you need to. Sometimes, you just need to stomp on memory a lot because of how the problem was contrived.
23:11:00 <energizer> this is all on the wrong track
23:11:11 <energizer> anyway thanks c_wraith
23:11:45 <dsal> It's hard to get concrete answers to hypotheticals. Better questions are "I don't think this code is fast enough. How can I speed it up?"
23:12:51 <dsal> Sometimes the answers are super not obvious. Like, "Hey, if you use a lazy map here and deleted a bunch of that code there, your solution would be much faster."
23:12:59 × mc47 quits (~mc47@xmonad/TheMC47) (Remote host closed the connection)
23:13:25 × kadir quits (~kadir@78.178.105.36) (Quit: WeeChat 3.3)
23:13:54 <energizer> on another topic. `foldr f (foldr f e ys) xs = foldr f e (xs ++ ys)` one of these is said to be "fused" but i dont know which one
23:18:24 <dsal> That might be referring to `{-# RULES "++" [~1] forall xs ys. xs ++ ys = augment (\c n -> foldr c n xs) ys #-}`
23:19:43 <maerwald> energizer: for example... I tried the example you linked and I can't observe the performance difference in the article
23:20:46 <maerwald> on 135k integers, haskell is 1.34s and C++ 1.29
23:20:56 × johnny_sitar quits (~artur@078088015209.bialystok.vectranet.pl) (Ping timeout: 245 seconds)
23:21:28 <energizer> which haskell one?
23:21:34 <maerwald> https://koerbitz.me/posts/Efficient-Quicksort-in-Haskell.html
23:22:19 <maerwald> but that post is almost 10 years old, so who knows which GHC version was used
23:22:27 × cosimone quits (~user@2001:b07:ae5:db26:a7aa:8027:6b4e:2fb3) (Quit: ERC (IRC client for Emacs 27.1))
23:22:35 × mvk quits (~mvk@2607:fea8:5cc3:e900::df92) (Ping timeout: 264 seconds)
23:24:12 <dsal> I imagine Haskell has improved more than c++ in that time.
23:24:26 <geekosaur> c++ may actually have lost performance
23:24:33 <[exa]> relevant: https://arxiv.org/pdf/1908.10926.pdf
23:24:45 <geekosaur> I've seen a number of complaints about recent gcc/g++
23:24:54 <maerwald> I'm using clang
23:25:06 × ees quits (~user@pool-108-18-30-46.washdc.fios.verizon.net) (Read error: Connection reset by peer)
23:25:28 <geekosaur> davean would have some words about that, although I note that for the uses I have locally clang performs better than g++
23:26:15 <geekosaur> (I should say clang++-compiled code performs better than g++-compiled code)
23:27:41 <maerwald> and ghc-9.2.1 became slower too it seems :o
23:28:27 × tzh quits (~tzh@c-24-21-73-154.hsd1.or.comcast.net) (Ping timeout: 256 seconds)
23:29:21 × etrepum quits (uid763@uxbridge.irccloud.com) (Quit: Connection closed for inactivity)
23:29:41 × jkaye quits (~jkaye@2601:281:8300:7530:663a:b6d3:3081:a6b4) (Ping timeout: 245 seconds)
23:29:56 jbox joins (~jbox@user/jbox)
23:30:07 × eggplant_ quits (~Eggplanta@2600:1700:bef1:5e10:d32:7961:c8e7:76c1) (Remote host closed the connection)
23:32:08 <maerwald> and ghc-8.8.4 is fastest so far
23:32:19 <sm> :/
23:32:40 <maerwald> 9.2.1 takes 1.4s, 8.8.4 1.07s
23:32:44 <maerwald> that's large
23:33:17 <maerwald> but maybe that's due to changes in inlining behavior or so... it changes frequently
23:37:25 × myShoggoth quits (~myShoggot@97-120-85-195.ptld.qwest.net) (Ping timeout: 268 seconds)
23:37:34 × __monty__ quits (~toonn@user/toonn) (Quit: leaving)
23:37:42 msmhbvd^ joins (~msmhbvd@h50.174.139.63.static.ip.windstream.net)
23:38:39 × machinedgod quits (~machinedg@24.105.81.50) (Ping timeout: 256 seconds)
23:40:49 × takuan quits (~takuan@178-116-218-225.access.telenet.be) (Remote host closed the connection)
23:40:57 random-jellyfish joins (~random-je@user/random-jellyfish)
23:42:48 eggplantade joins (~Eggplanta@2600:1700:bef1:5e10:d32:7961:c8e7:76c1)
23:44:21 yauhsien joins (~yauhsien@118-167-47-187.dynamic-ip.hinet.net)
23:47:18 × jgeerds quits (~jgeerds@55d41b94.access.ecotel.net) (Ping timeout: 268 seconds)
23:48:47 merijn joins (~merijn@83-160-49-249.ip.xs4all.nl)
23:49:59 × tcard quits (~tcard@p2878075-ipngn18701hodogaya.kanagawa.ocn.ne.jp) (Remote host closed the connection)
23:51:24 × Guest42 quits (~Guest42@eth-west-pareq2-46-193-4-100.wb.wifirst.net) (Quit: Client closed)
23:53:10 × eggplantade quits (~Eggplanta@2600:1700:bef1:5e10:d32:7961:c8e7:76c1) (Remote host closed the connection)
23:56:44 tcard joins (~tcard@p2878075-ipngn18701hodogaya.kanagawa.ocn.ne.jp)
23:59:58 allbery_b joins (~geekosaur@xmonad/geekosaur)
23:59:58 × geekosaur quits (~geekosaur@xmonad/geekosaur) (Killed (NickServ (GHOST command used by allbery_b)))

All times are in UTC on 2021-11-13.