2021/09/16

2021-09-16 00:05:37 +0000ec_(~ec@gateway/tor-sasl/ec)
2021-09-16 00:07:41 +0000gioyik(~gioyik@gateway/tor-sasl/gioyik)
2021-09-16 00:11:31 +0000amitnjha(~amit@024-216-124-116.res.spectrum.com) (Quit: amitnjha)
2021-09-16 00:11:45 +0000amitnjha(~amit@024-216-124-116.res.spectrum.com)
2021-09-16 00:12:55 +0000aegon(~mike@174.127.249.180) (Quit: leaving)
2021-09-16 00:13:45 +0000gioyik(~gioyik@gateway/tor-sasl/gioyik) (Ping timeout: 276 seconds)
2021-09-16 00:16:29 +0000lavaman(~lavaman@98.38.249.169)
2021-09-16 00:21:11 +0000lavaman(~lavaman@98.38.249.169) (Ping timeout: 265 seconds)
2021-09-16 00:21:42 +0000merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2021-09-16 00:21:51 +0000amitnjha(~amit@024-216-124-116.res.spectrum.com) (Quit: amitnjha)
2021-09-16 00:22:10 +0000amitnjha(~amit@024-216-124-116.res.spectrum.com)
2021-09-16 00:24:28 +0000ph88(~ph88@2a02:8109:9e00:7e5c:c17a:3fe0:849c:9e0a)
2021-09-16 00:24:58 +0000gioyik(~gioyik@gateway/tor-sasl/gioyik)
2021-09-16 00:26:06 +0000ec_(~ec@gateway/tor-sasl/ec) (Ping timeout: 276 seconds)
2021-09-16 00:26:57 +0000geekosaur(~geekosaur@xmonad/geekosaur)
2021-09-16 00:27:40 +0000ph88^(~ph88@ip5f5af6fd.dynamic.kabel-deutschland.de) (Ping timeout: 268 seconds)
2021-09-16 00:29:33 +0000stites(~stitescoc@130.44.141.131) (Quit: Bridge terminating on SIGTERM)
2021-09-16 00:29:33 +0000enick_769(~matrixbot@130.44.141.131) (Quit: Bridge terminating on SIGTERM)
2021-09-16 00:30:00 +0000gioyik(~gioyik@gateway/tor-sasl/gioyik) (Ping timeout: 276 seconds)
2021-09-16 00:39:24 +0000pretty_dumm_guy(trottel@gateway/vpn/protonvpn/prettydummguy/x-88029655) (Quit: WeeChat 3.2.1)
2021-09-16 00:43:42 +0000proofofkeags_(~proofofke@205.209.28.54) (Ping timeout: 268 seconds)
2021-09-16 00:46:18 +0000gioyik(~gioyik@gateway/tor-sasl/gioyik)
2021-09-16 00:51:27 +0000gioyik(~gioyik@gateway/tor-sasl/gioyik) (Ping timeout: 276 seconds)
2021-09-16 00:51:44 +0000 <ldlework> i'm finding the rendering performance of gloss a bit unsatsifactory
2021-09-16 00:51:48 +0000 <ldlework> but i bet it's my code
2021-09-16 00:54:16 +0000jinsun(~quassel@user/jinsun) (Read error: Connection reset by peer)
2021-09-16 00:55:12 +0000merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 268 seconds)
2021-09-16 00:57:03 +0000jinsun(~quassel@user/jinsun)
2021-09-16 00:57:56 +0000lbseale(~lbseale@user/ep1ctetus) (Read error: Connection reset by peer)
2021-09-16 00:59:24 +0000geekosaur(~geekosaur@xmonad/geekosaur) (Remote host closed the connection)
2021-09-16 01:01:39 +0000geekosaur(~geekosaur@xmonad/geekosaur)
2021-09-16 01:01:43 +0000 <Axman6> Feel free to share some code
2021-09-16 01:05:20 +0000gioyik(~gioyik@gateway/tor-sasl/gioyik)
2021-09-16 01:07:40 +0000acarrico(~acarrico@dhcp-68-142-39-249.greenmountainaccess.net)
2021-09-16 01:08:41 +0000 <ldlework> Axman6: https://github.com/dustinlacewell/cells-hs
2021-09-16 01:08:46 +0000 <ldlework> It's very "jerky"
2021-09-16 01:09:06 +0000 <ldlework> It's not the computation going on either, because I can kick it up to 1000 ticks a frame and it keeps up just fine
2021-09-16 01:09:16 +0000 <ldlework> It's like the rendering itself is very jerky / not vsynced
2021-09-16 01:10:57 +0000gioyik(~gioyik@gateway/tor-sasl/gioyik) (Ping timeout: 276 seconds)
2021-09-16 01:12:00 +0000albet70(~xxx@2400:8902::f03c:92ff:fe60:98d8) (Remote host closed the connection)
2021-09-16 01:12:50 +0000vysn(~vysn@user/vysn) (Ping timeout: 260 seconds)
2021-09-16 01:13:07 +0000albet70(~xxx@2400:8902::f03c:92ff:fe60:98d8)
2021-09-16 01:13:09 +0000 <Axman6> mrianbloom: it looks relatively easy to run an Acc a expression with either backend, what issues are you running into?
2021-09-16 01:13:30 +0000 <awpr> from a cursory look I think its memory usage will grow unbounded and make GCs take progressively longer over time as there's more live data on the heap to look through
2021-09-16 01:13:40 +0000 <awpr> (ldlework)
2021-09-16 01:14:23 +0000 <ldlework> awpr: i'm not sure what to do about that, since you need to generate new rows of cells as the simulation evolves, etc
2021-09-16 01:14:27 +0000 <mrianbloom> Axman6: I think in early debugging sessions I maybe convinced myself that aliasing PTX.runN was somehow problematic. Now I'm thinking that's a false negative.
2021-09-16 01:14:49 +0000 <awpr> can old rows be deleted as they get very old?
2021-09-16 01:15:00 +0000 <ldlework> awpr: yeah
2021-09-16 01:15:07 +0000 <ldlework> i don't even keep them in the World structure
2021-09-16 01:15:10 +0000 <Axman6> mrianbloom: yeah worth exploring further I think
2021-09-16 01:15:13 +0000xff0x(~xff0x@2001:1a81:522c:4300:5ee7:ef88:cf65:a085) (Ping timeout: 252 seconds)
2021-09-16 01:15:31 +0000 <Axman6> ldlework: looks like you're reinvention a lot of Data.Bits btw
2021-09-16 01:15:40 +0000 <ldlework> yeah? lol
2021-09-16 01:15:51 +0000 <Axman6> reinventing*
2021-09-16 01:15:55 +0000 <awpr> oh, I missed that appendRow trims it to a bounded length
2021-09-16 01:16:08 +0000asivitz(uid178348@id-178348.tinside.irccloud.com) (Quit: Connection closed for inactivity)
2021-09-16 01:16:20 +0000 <ldlework> If I increase the resolution of a the sim a lot, it starts off fast, then gets slow after about 2 seconds, then starts to chug
2021-09-16 01:16:22 +0000 <awpr> could store rows as Integer or Word64 depending on size, to have 1 allocation per row instead of 2n
2021-09-16 01:16:47 +0000xff0x(~xff0x@2001:1a81:526d:1c00:a4aa:2b9e:15c4:9931)
2021-09-16 01:16:55 +0000 <awpr> well, Integer would be like n/64 rather than 1, but still
2021-09-16 01:17:03 +0000 <ldlework> awpr: maybe I should pregenerate every possible row ;P
2021-09-16 01:17:59 +0000 <awpr> if the number of rows is large, you might benefit from Data.Sequence where you can append and uncons in constant time. worse constant factors, though, so it may or may not help
2021-09-16 01:18:02 +0000 <ldlework> storing rows directly as numbers will complicate make having the row size be flexible I think
2021-09-16 01:18:14 +0000 <Cajun> are you trying to strictly stay with Lists or are you willing to use an array library for a more efficient (and simpler) implementation?
2021-09-16 01:18:20 +0000 <mrianbloom> Axman6: I think my main question is how to make it a compile time option without modifying any code.
2021-09-16 01:18:33 +0000 <ldlework> Cajun: not at all, I'm open to optimizations that I can still understand
2021-09-16 01:18:38 +0000 <awpr> Integer is an unbounded number of bits, and you can use testBit to access each one
2021-09-16 01:18:39 +0000 <Cajun> doing this with `massiv` and stencils
2021-09-16 01:18:47 +0000 <Cajun> *would be not too complicated
2021-09-16 01:18:54 +0000 <mrianbloom> Axman6: as in a user of my library can decide.
2021-09-16 01:20:01 +0000 <Axman6> hmm, so do you only want to compile in one backend and have a flag which decides which?
2021-09-16 01:20:04 +0000 <ldlework> Would another option be to parallize it?
2021-09-16 01:20:10 +0000 <ldlework> Like split the row in half
2021-09-16 01:20:27 +0000 <awpr> I'd check out how much memory it's using and how much time it's spending in GC first. if you have GC pauses, parallelizing work might not fix it
2021-09-16 01:20:49 +0000 <Cajun> massiv could parallelize it automatically, removes all the issues that updating a state in parallel has. it shouldnt be necessary to use massiv though
2021-09-16 01:20:49 +0000 <Axman6> You'll just make garbage faster!
2021-09-16 01:20:52 +0000 <mrianbloom> Axman6: That's correct.
2021-09-16 01:20:52 +0000 <ldlework> haha
2021-09-16 01:21:08 +0000 <awpr> https://downloads.haskell.org/~ghc/latest/docs/html/users_guide/runtime_control.html#rts-options-t…
2021-09-16 01:21:47 +0000 <Axman6> mrianbloom: what are you exposing to the user? are you exposing Acc things or functions which are supposed to use accelerate behind the scenes?
2021-09-16 01:22:23 +0000 <mrianbloom> I'm exposing functions on Array representations.
2021-09-16 01:23:01 +0000 <mrianbloom> Axman6: So definitely behind the scenes accelerate.
2021-09-16 01:23:02 +0000 <Axman6> So wouldn't it be up to the user to decide how to execute those functions and make the necessary decisions in their code?
2021-09-16 01:23:05 +0000 <Axman6> ah ok
2021-09-16 01:23:46 +0000 <mrianbloom> Axman6: I mean none of the exposed functions have Acc in the type signatures.
2021-09-16 01:23:47 +0000 <Axman6> Well, usually this is the sort of thing you would do with a combination of cabal flags and some CPP
2021-09-16 01:24:08 +0000 <Axman6> as that's the only way to dynamically add dependencies
2021-09-16 01:24:16 +0000 <Axman6> "dynamically" at compile time
2021-09-16 01:24:36 +0000sneedsfeed(~sneedsfee@rrcs-173-95-122-169.midsouth.biz.rr.com)
2021-09-16 01:24:37 +0000 <mrianbloom> Axman6: Ok cool, that's good confirmation. I was thinking there might be another way besides cpp.
2021-09-16 01:25:30 +0000 <geekosaur> backpack?
2021-09-16 01:29:06 +0000neurocyte6(~neurocyte@185.117.68.241)
2021-09-16 01:29:06 +0000neurocyte6(~neurocyte@185.117.68.241) (Changing host)
2021-09-16 01:29:06 +0000neurocyte6(~neurocyte@user/neurocyte)
2021-09-16 01:31:11 +0000neurocyte(~neurocyte@user/neurocyte) (Ping timeout: 268 seconds)
2021-09-16 01:31:11 +0000neurocyte6neurocyte
2021-09-16 01:36:16 +0000gioyik(~gioyik@gateway/tor-sasl/gioyik)
2021-09-16 01:37:27 +0000 <ldlework> OK made the Data.Bits refactor, https://github.com/dustinlacewell/cells-hs/blob/master/app/Main.hs#L45
2021-09-16 01:37:29 +0000 <ldlework> thanks for that tip
2021-09-16 01:38:22 +0000 <ldlework> I'm more uncertain about my ability to use massiv
2021-09-16 01:40:39 +0000 <zzz> now im worried
2021-09-16 01:41:30 +0000gioyik(~gioyik@gateway/tor-sasl/gioyik) (Ping timeout: 276 seconds)
2021-09-16 01:42:30 +0000 <awpr> ldlework: I'd try running with `+RTS -s -RTS` to see how much time it's spending on GC first; there's more info in the link I sent
2021-09-16 01:42:55 +0000 <awpr> best to know what it's spending time on before trying to speed up any particular thing
2021-09-16 01:43:10 +0000roboguy_(~roboguy_@2605:a601:afe7:9f00:d11a:2286:b23f:5e4c)
2021-09-16 01:43:12 +0000 <ldlework> awpr: I use nix, and no idea how it's build infrastructure works really
2021-09-16 01:43:19 +0000 <ldlework> So I'm not sure how I would add those flags :(
2021-09-16 01:43:24 +0000 <awpr> those are flags to the compiled binary itself
2021-09-16 01:43:29 +0000 <ldlework> oh weird
2021-09-16 01:44:02 +0000 <awpr> the GHC runtime has its own set of flags that are magically in every binary, if enabled. you might have to enable it explicitly, though
2021-09-16 01:45:28 +0000favonia(~favonia@user/favonia)
2021-09-16 01:45:38 +0000 <ldlework> awpr: https://gist.github.com/dustinlacewell/466cd9c9bbf58290ef3cf8470521bca2
2021-09-16 01:46:13 +0000 <awpr> wow, 0% of time in GC, was not expecting that
2021-09-16 01:46:39 +0000 <ldlework> awpr: are you able to run the project
2021-09-16 01:46:52 +0000 <ldlework> i wonder if it's just me?
2021-09-16 01:47:01 +0000 <ldlework> screwy linux, not using gpu or something?
2021-09-16 01:48:19 +0000abhixec(~abhixec@c-67-169-139-16.hsd1.ca.comcast.net)
2021-09-16 01:50:06 +0000abhixec(~abhixec@c-67-169-139-16.hsd1.ca.comcast.net) (Client Quit)
2021-09-16 01:51:19 +0000brainfreeze(~brainfree@2a03:1b20:4:f011::20d)
2021-09-16 01:51:56 +0000brettgilio(~brettgili@x-node.gq)
2021-09-16 01:53:16 +0000 <awpr> still building, but the list indexing looks like it'll be pretty slow -- every cell will traverse the row 3 times
2021-09-16 01:54:57 +0000 <awpr> switching to Vector Bool might speed it up a lot, since it's constant-time access
2021-09-16 01:57:12 +0000 <awpr> could also build and run it with profiling enabled, if you can figure out how to do that with nix (I haven't used it myself, but it's not terribly hard to profile under Stack)
2021-09-16 01:57:29 +0000eggplantade(~Eggplanta@2600:1700:bef1:5e10:fcfd:5153:b61b:fe3d) (Remote host closed the connection)
2021-09-16 01:58:43 +0000waleee(~waleee@2001:9b0:216:8200:d457:9189:7843:1dbd) (Ping timeout: 268 seconds)
2021-09-16 01:59:05 +0000eggplantade(~Eggplanta@2600:1700:bef1:5e10:fcfd:5153:b61b:fe3d)
2021-09-16 02:00:25 +0000eggplantade(~Eggplanta@2600:1700:bef1:5e10:fcfd:5153:b61b:fe3d) (Remote host closed the connection)
2021-09-16 02:00:34 +0000eggplantade(~Eggplanta@2600:1700:bef1:5e10:fcfd:5153:b61b:fe3d)
2021-09-16 02:02:12 +0000amitnjha(~amit@024-216-124-116.res.spectrum.com) (Quit: amitnjha)
2021-09-16 02:02:27 +0000amitnjha(~amit@024-216-124-116.res.spectrum.com)
2021-09-16 02:03:25 +0000sneedsfeed(~sneedsfee@rrcs-173-95-122-169.midsouth.biz.rr.com) (Ping timeout: 256 seconds)
2021-09-16 02:04:28 +0000gioyik(~gioyik@gateway/tor-sasl/gioyik)
2021-09-16 02:09:15 +0000proofofkeags_(~proofofke@97-118-134-2.hlrn.qwest.net)
2021-09-16 02:09:27 +0000gioyik(~gioyik@gateway/tor-sasl/gioyik) (Ping timeout: 276 seconds)
2021-09-16 02:10:54 +0000geekosaur(~geekosaur@xmonad/geekosaur) (Remote host closed the connection)
2021-09-16 02:11:24 +0000zebrag(~chris@user/zebrag) (Quit: Konversation terminated!)
2021-09-16 02:13:09 +0000geekosaur(~geekosaur@xmonad/geekosaur)
2021-09-16 02:14:58 +0000amitnjha(~amit@024-216-124-116.res.spectrum.com) (Ping timeout: 268 seconds)
2021-09-16 02:16:11 +0000 <awpr> looks like all the time is going to OpenGL functions, especially matrix stack manipulation
2021-09-16 02:17:12 +0000goepsilongo(~chacho@2603-7000-ab00-62ed-0000-0000-0000-0bd0.res6.spectrum.com)
2021-09-16 02:19:22 +0000alx741(~alx741@181.196.68.49) (Quit: alx741)
2021-09-16 02:21:14 +0000 <ldlework> awpr: maybe it is the way I reset the transform for each cell?
2021-09-16 02:21:26 +0000 <ldlework> i wonder why that would cause it to slow down over time though
2021-09-16 02:21:45 +0000 <awpr> that sure sounds consistent with the profile. I didn't run it for very long, though
2021-09-16 02:22:01 +0000td_(~td@muedsl-82-207-238-063.citykom.de) (Ping timeout: 265 seconds)
2021-09-16 02:23:44 +0000td_(~td@muedsl-82-207-238-006.citykom.de)
2021-09-16 02:24:20 +0000orion(~orion@user/orion)
2021-09-16 02:25:02 +0000ridcully_(~ridcully@p508ac428.dip0.t-ipconnect.de) (Ping timeout: 252 seconds)
2021-09-16 02:27:05 +0000ridcully_(~ridcully@p57b523cc.dip0.t-ipconnect.de)
2021-09-16 02:27:32 +0000jpds(~jpds@gateway/tor-sasl/jpds) (Remote host closed the connection)
2021-09-16 02:28:36 +0000jpds(~jpds@gateway/tor-sasl/jpds)
2021-09-16 02:33:30 +0000chexum(~quassel@gateway/tor-sasl/chexum) (Ping timeout: 276 seconds)
2021-09-16 02:33:51 +0000 <ldlework> awpr: https://i.imgur.com/rRVPkZ6.png
2021-09-16 02:35:27 +0000 <awpr> odd, I didn't notice any space-leaky behavior when I ran it. do you have optimizations on?
2021-09-16 02:36:18 +0000 <ldlework> awpr: i just added -O2 yeah
2021-09-16 02:36:28 +0000 <ldlework> just throwing stuff at the wall lol
2021-09-16 02:37:48 +0000 <ldlework> awpr: when I run it for longer, it looks like the memory flattens out
2021-09-16 02:37:49 +0000 <ldlework> http://logos.ldlework.com/caps/2021-09-16-02-37-35.png
2021-09-16 02:37:53 +0000 <awpr> my binary seems to be constant memory. it might ramp up until the row limit is reached and then plateau, does that heap profile cover after that part?
2021-09-16 02:37:55 +0000 <ldlework> the curve is probably filling up the grid with rows
2021-09-16 02:37:56 +0000 <awpr> yeah, what you just said
2021-09-16 02:38:01 +0000greg8128(~user@50.47.115.102)
2021-09-16 02:38:19 +0000 <ldlework> I also increased the resolution by a lot to make the effect more dramatic
2021-09-16 02:39:14 +0000 <ldlework> these stand out https://gist.github.com/dustinlacewell/135cf3906f0fb036e2048558cadb14f4
2021-09-16 02:39:54 +0000 <awpr> the rightmost 4 columns seem to say very little time or allocation is spent on them
2021-09-16 02:42:22 +0000[itchyjunk](~itchyjunk@user/itchyjunk/x-7353470)
2021-09-16 02:45:25 +0000hyiltiz(~quassel@31.220.5.250) (Ping timeout: 252 seconds)
2021-09-16 02:45:42 +0000wroathe(~wroathe@user/wroathe) (Ping timeout: 265 seconds)
2021-09-16 02:48:04 +0000 <ldlework> awpr: `neighborhood` is the most expensive function of my own authorship, with 4.4 individual %
2021-09-16 02:48:13 +0000 <ldlework> doesn't that indicate that stenciling might help?
2021-09-16 02:48:22 +0000sneedsfeed(~sneedsfee@rrcs-173-95-122-169.midsouth.biz.rr.com)
2021-09-16 02:49:06 +0000 <ldlework> beyond that, my only guess is the wasteful transforms
2021-09-16 02:49:18 +0000 <awpr> well it was running at 2-3fps on my machine, so making that function infinitely faster isn't gonna bring it up to 60. the time is going to the rendering much more than the world update (as much as I initially expected it to go to list indexing or GC)
2021-09-16 02:49:18 +0000 <ldlework> need haskell->GLSL
2021-09-16 02:49:51 +0000 <awpr> if matrix stack manipulation is expensive, try to do less of it
2021-09-16 02:50:14 +0000 <ldlework> I guess my drawing routine will have to be smarter somehow
2021-09-16 02:50:39 +0000ph88^(~ph88@2a02:8109:9e00:7e5c:c17a:3fe0:849c:9e0a)
2021-09-16 02:50:39 +0000 <ldlework> the reason i'm translating to origin for each cell that's drawn, is so that i don't have to draw each cell
2021-09-16 02:50:40 +0000 <awpr> my vague recollection is that the matrix stack is meant for, like, loading an entire mesh under a transform, not so much to be the entire means of getting positions for every vertex
2021-09-16 02:50:49 +0000jokleinn(~jokleinn@user/jokleinn)
2021-09-16 02:50:52 +0000 <ldlework> to avoid the transforms, i'd have to like go cell by cell
2021-09-16 02:51:01 +0000 <ldlework> which seems like it would mean even more transforms
2021-09-16 02:51:36 +0000merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2021-09-16 02:51:42 +0000 <awpr> I don't really know how gloss does things unfortunately. the code looked sensible, but somehow it's changing the matrix stack a whole lot
2021-09-16 02:51:55 +0000 <ldlework> awpr: indeed the API for Gloss wants you to transform somewhere, then use some kind of primitive like a square of a certain size
2021-09-16 02:51:59 +0000 <ldlework> the square doesn't take a position
2021-09-16 02:52:32 +0000 <awpr> is it possible this is just pushing the limits of the number of individual things Gloss can deal with? I'm not really familiar with the library
2021-09-16 02:52:59 +0000 <ldlework> awpr: I believe it is using the old-style OpenGL pipeline
2021-09-16 02:53:06 +0000hyiltiz(~quassel@31.220.5.250)
2021-09-16 02:53:08 +0000 <awpr> yeah, it is
2021-09-16 02:53:39 +0000 <awpr> profile mentioned the function that pushes a singular vertex into the stream
2021-09-16 02:54:26 +0000ph88(~ph88@2a02:8109:9e00:7e5c:c17a:3fe0:849c:9e0a) (Ping timeout: 268 seconds)
2021-09-16 02:55:33 +0000orion(~orion@user/orion) (Read error: Connection reset by peer)
2021-09-16 02:56:01 +0000 <ldlework> I assume it would be no faster switching to hSDL
2021-09-16 02:56:03 +0000 <ldlework> hmm
2021-09-16 02:56:16 +0000 <ldlework> I could just move on with my life I guess
2021-09-16 02:58:18 +0000FinnElija(~finn_elij@user/finn-elija/x-0085643) (Ping timeout: 260 seconds)
2021-09-16 02:58:49 +0000 <awpr> it doesn't really look very aggressively performance optimized; this might just be how fast it goes with lots of tiny rectangles
2021-09-16 02:59:32 +0000chexum(~quassel@gateway/tor-sasl/chexum)
2021-09-16 03:00:07 +0000FinnElija(~finn_elij@user/finn-elija/x-0085643)
2021-09-16 03:02:03 +0000 <awpr> https://www.47deg.com/blog/game-of-life-haskell/ has someone doing a similar thing, and the end result is "hooray, we improved it from 2 iterations before crashing to 60 iterations before crashing", so it looks like yours is already ahead of the curve
2021-09-16 03:03:26 +0000shapr(~user@pool-100-36-247-68.washdc.fios.verizon.net) (Ping timeout: 260 seconds)
2021-09-16 03:04:40 +0000goepsilongo(~chacho@2603-7000-ab00-62ed-0000-0000-0000-0bd0.res6.spectrum.com) (Quit: Konversation terminated!)
2021-09-16 03:07:49 +0000doyougnu(~user@c-73-25-202-122.hsd1.or.comcast.net) (Ping timeout: 252 seconds)
2021-09-16 03:13:17 +0000[itchyjunk](~itchyjunk@user/itchyjunk/x-7353470) (Remote host closed the connection)
2021-09-16 03:15:46 +0000zaquest(~notzaques@5.128.210.178) (Remote host closed the connection)
2021-09-16 03:17:12 +0000zaquest(~notzaques@5.128.210.178)
2021-09-16 03:20:38 +0000 <Cajun> Idlework: if you want to learn `massiv` (which i highly recommend as an upgrade to `repa` and a good cpu-bound upgrade to `accelerate` ) he has a 6 part talk from 2019 about the library. its quite long, around 6 hours but itll tell you the ins and outs of the library
2021-09-16 03:21:02 +0000 <ldlework> phew
2021-09-16 03:21:05 +0000 <ldlework> hit me I guess
2021-09-16 03:21:31 +0000 <Cajun> heres 1/6: https://www.youtube.com/watch?v=euEacUD6jQQ
2021-09-16 03:21:35 +0000 <ldlework> thanks
2021-09-16 03:23:15 +0000wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
2021-09-16 03:23:16 +0000wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Changing host)
2021-09-16 03:23:16 +0000wroathe(~wroathe@user/wroathe)
2021-09-16 03:25:49 +0000merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 265 seconds)
2021-09-16 03:29:06 +0000dtman34(~dtman34@c-73-62-246-247.hsd1.mn.comcast.net) (Ping timeout: 260 seconds)
2021-09-16 03:38:50 +0000notzmv(~zmv@user/notzmv) (Ping timeout: 268 seconds)
2021-09-16 03:39:54 +0000Vajb(~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) (Read error: Connection reset by peer)
2021-09-16 03:46:36 +0000machinedgod(~machinedg@135-23-192-217.cpe.pppoe.ca) (Ping timeout: 265 seconds)
2021-09-16 03:50:10 +0000justsomeguy(~justsomeg@user/justsomeguy) (Quit: WeeChat 3.2)
2021-09-16 03:52:08 +0000falafel(~falafel@2603-8000-d800-688c-4852-3b82-73df-20ff.res6.spectrum.com)
2021-09-16 03:54:01 +0000dtman34(~dtman34@c-73-62-246-247.hsd1.mn.comcast.net)
2021-09-16 03:55:01 +0000notzmv(~zmv@user/notzmv)
2021-09-16 03:58:25 +0000dtman34(~dtman34@c-73-62-246-247.hsd1.mn.comcast.net) (Ping timeout: 252 seconds)
2021-09-16 04:07:59 +0000Vajb(~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi)
2021-09-16 04:08:19 +0000jokleinn(~jokleinn@user/jokleinn) (Ping timeout: 252 seconds)
2021-09-16 04:15:20 +0000phma(~phma@host-67-44-208-97.hnremote.net) (Read error: Connection reset by peer)
2021-09-16 04:18:56 +0000phma(~phma@host-67-44-208-97.hnremote.net)
2021-09-16 04:21:42 +0000haysh_
2021-09-16 04:23:14 +0000texasmynsted(~texasmyns@99.96.221.112) (WeeChat 3.1)
2021-09-16 04:37:09 +0000lavaman(~lavaman@98.38.249.169)
2021-09-16 04:40:23 +0000sneedsfeed(~sneedsfee@rrcs-173-95-122-169.midsouth.biz.rr.com) (Ping timeout: 256 seconds)
2021-09-16 04:49:45 +0000roboguy_(~roboguy_@2605:a601:afe7:9f00:d11a:2286:b23f:5e4c) ()
2021-09-16 04:49:45 +0000lavaman(~lavaman@98.38.249.169) (Remote host closed the connection)
2021-09-16 04:49:58 +0000lavaman(~lavaman@98.38.249.169)
2021-09-16 04:50:07 +0000lavaman(~lavaman@98.38.249.169) (Remote host closed the connection)
2021-09-16 04:56:06 +0000dsrt^(~dsrt@68.101.54.227) (Remote host closed the connection)
2021-09-16 05:03:42 +0000Vajb(~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) (Read error: Connection reset by peer)
2021-09-16 05:07:14 +0000Vajb(~Vajb@nbptnppvs5wp2vjps-2.v6.elisa-mobile.fi)
2021-09-16 05:07:20 +0000zmt00(~zmt00@user/zmt00)
2021-09-16 05:10:43 +0000zmt01(~zmt00@user/zmt00) (Ping timeout: 268 seconds)
2021-09-16 05:10:52 +0000michalz(~michalz@185.246.204.61)
2021-09-16 05:11:58 +0000gentauro(~gentauro@user/gentauro) (Read error: Connection reset by peer)
2021-09-16 05:13:07 +0000wroathe(~wroathe@user/wroathe) (Ping timeout: 265 seconds)
2021-09-16 05:14:02 +0000qbt(~edun@user/edun)
2021-09-16 05:15:26 +0000myShoggoth(~myShoggot@97-120-70-214.ptld.qwest.net) (Read error: Connection reset by peer)
2021-09-16 05:15:43 +0000myShoggoth(~myShoggot@97-120-70-214.ptld.qwest.net)
2021-09-16 05:16:12 +0000dtman34(~dtman34@c-73-62-246-247.hsd1.mn.comcast.net)
2021-09-16 05:16:35 +0000gentauro(~gentauro@user/gentauro)
2021-09-16 05:20:36 +0000lavaman(~lavaman@98.38.249.169)
2021-09-16 05:20:53 +0000aws(~aws@mx1.aosync.me)
2021-09-16 05:21:36 +0000sagax(~sagax_nb@user/sagax)
2021-09-16 05:24:02 +0000merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2021-09-16 05:24:03 +0000Vajb(~Vajb@nbptnppvs5wp2vjps-2.v6.elisa-mobile.fi) (Read error: Connection reset by peer)
2021-09-16 05:25:08 +0000Vajb(~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi)
2021-09-16 05:25:31 +0000lavaman(~lavaman@98.38.249.169) (Ping timeout: 268 seconds)
2021-09-16 05:26:32 +0000aws(~aws@mx1.aosync.me) (Leaving)
2021-09-16 05:26:43 +0000waleee(~waleee@2001:9b0:216:8200:d457:9189:7843:1dbd)
2021-09-16 05:30:05 +0000wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
2021-09-16 05:30:05 +0000wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Changing host)
2021-09-16 05:30:05 +0000wroathe(~wroathe@user/wroathe)
2021-09-16 05:34:40 +0000wroathe(~wroathe@user/wroathe) (Ping timeout: 252 seconds)
2021-09-16 05:37:25 +0000_ht(~quassel@82-169-194-8.biz.kpn.net)
2021-09-16 05:37:31 +0000gioyik(~gioyik@gateway/tor-sasl/gioyik)
2021-09-16 05:39:06 +0000greg8128(~user@50.47.115.102) (Remote host closed the connection)
2021-09-16 05:40:20 +0000takuan(~takuan@178-116-218-225.access.telenet.be)
2021-09-16 05:43:07 +0000 <Orbstheorem> The more I play with `ViewPatterns`, the more I like them, but I also have to admit, it makes the code look a bit scarier x)
2021-09-16 05:52:10 +0000ellie(~ellie@user/ellie) (Quit: The Lounge - https://thelounge.chat)
2021-09-16 05:52:24 +0000ellie(~ellie@user/ellie)
2021-09-16 05:53:47 +0000 <c_wraith> You can use them with Pattern Synonyms to make them look much more normal
2021-09-16 05:56:07 +0000merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 252 seconds)
2021-09-16 05:57:47 +0000chele(~chele@user/chele)
2021-09-16 06:00:01 +0000 <Orbstheorem> Oh, neat!
2021-09-16 06:02:33 +0000phma(~phma@host-67-44-208-97.hnremote.net) (Read error: Connection reset by peer)
2021-09-16 06:04:11 +0000nshepperd(nshepperd@2600:3c03::f03c:92ff:fe28:92c9) (Quit: quit)
2021-09-16 06:04:11 +0000nshepperd2(~nshepperd@li364-218.members.linode.com) (Quit: The Lounge - https://thelounge.chat)
2021-09-16 06:04:23 +0000phma(~phma@host-67-44-208-97.hnremote.net)
2021-09-16 06:05:57 +0000brainfreeze(~brainfree@2a03:1b20:4:f011::20d) (Remote host closed the connection)
2021-09-16 06:09:50 +0000img(~img@user/img) (Quit: ZNC 1.8.2 - https://znc.in)
2021-09-16 06:10:50 +0000Akronymus(~Akronymus@85.31.8.180)
2021-09-16 06:12:12 +0000img(~img@user/img)
2021-09-16 06:13:36 +0000ubert(~Thunderbi@178.165.161.81.wireless.dyn.drei.com)
2021-09-16 06:14:51 +0000ph88(~ph88@2a02:8109:9e00:7e5c:c17a:3fe0:849c:9e0a)
2021-09-16 06:15:40 +0000jakalx(~jakalx@base.jakalx.net) ()
2021-09-16 06:18:16 +0000dhouthoo(~dhouthoo@178-117-36-167.access.telenet.be)
2021-09-16 06:18:20 +0000ph88^(~ph88@2a02:8109:9e00:7e5c:c17a:3fe0:849c:9e0a) (Ping timeout: 268 seconds)
2021-09-16 06:19:03 +0000lavaman(~lavaman@98.38.249.169)
2021-09-16 06:23:10 +0000falafel(~falafel@2603-8000-d800-688c-4852-3b82-73df-20ff.res6.spectrum.com) (Ping timeout: 260 seconds)
2021-09-16 06:23:17 +0000nshepperd2(~nshepperd@li364-218.members.linode.com)
2021-09-16 06:23:20 +0000nshepperd(nshepperd@2600:3c03::f03c:92ff:fe28:92c9)
2021-09-16 06:23:40 +0000lavaman(~lavaman@98.38.249.169) (Ping timeout: 252 seconds)
2021-09-16 06:27:10 +0000zmt00(~zmt00@user/zmt00) (Ping timeout: 240 seconds)
2021-09-16 06:30:01 +0000gioyik(~gioyik@gateway/tor-sasl/gioyik) (Quit: WeeChat 3.1)
2021-09-16 06:31:41 +0000falafel(~falafel@2603-8000-d800-688c-753f-04f5-7eeb-6eb7.res6.spectrum.com)
2021-09-16 06:31:50 +0000nattiestnate(~nate@2001:448a:20a0:4134:25e:715f:d637:5263) (Quit: WeeChat 3.2)
2021-09-16 06:33:31 +0000shriekingnoise(~shrieking@186.137.144.80) (Quit: Quit)
2021-09-16 06:33:41 +0000ubert1(~Thunderbi@178.165.161.81.wireless.dyn.drei.com)
2021-09-16 06:34:14 +0000pfurla(~pfurla@64.145.79.69)
2021-09-16 06:35:40 +0000ubert(~Thunderbi@178.165.161.81.wireless.dyn.drei.com) (Ping timeout: 240 seconds)
2021-09-16 06:35:40 +0000ubert1ubert
2021-09-16 06:36:49 +0000pfurla_(~pfurla@ool-182ed2e2.dyn.optonline.net) (Ping timeout: 252 seconds)
2021-09-16 06:37:18 +0000benin036932301(~benin@183.82.24.197)
2021-09-16 06:38:41 +0000xff0x(~xff0x@2001:1a81:526d:1c00:a4aa:2b9e:15c4:9931) (Ping timeout: 268 seconds)
2021-09-16 06:39:14 +0000xff0x(~xff0x@port-92-195-42-138.dynamic.as20676.net)
2021-09-16 06:39:47 +0000_ht(~quassel@82-169-194-8.biz.kpn.net) (Remote host closed the connection)
2021-09-16 06:41:27 +0000pfurla_(~pfurla@ool-182ed2e2.dyn.optonline.net)
2021-09-16 06:43:08 +0000myShoggoth(~myShoggot@97-120-70-214.ptld.qwest.net) (Read error: Connection reset by peer)
2021-09-16 06:44:28 +0000pfurla(~pfurla@64.145.79.69) (Ping timeout: 265 seconds)
2021-09-16 06:45:24 +0000falafel(~falafel@2603-8000-d800-688c-753f-04f5-7eeb-6eb7.res6.spectrum.com) (Read error: Connection reset by peer)
2021-09-16 06:45:30 +0000falafel_(~falafel@2603-8000-d800-688c-753f-04f5-7eeb-6eb7.res6.spectrum.com)
2021-09-16 06:47:56 +0000Erutuon(~Erutuon@user/erutuon) (Ping timeout: 268 seconds)
2021-09-16 06:48:15 +0000cfricke(~cfricke@user/cfricke)
2021-09-16 06:49:16 +0000tromp(~textual@dhcp-077-249-230-040.chello.nl)
2021-09-16 06:49:35 +0000xsperry(~as@user/xsperry)
2021-09-16 06:49:37 +0000xsperry(~as@user/xsperry) (Excess Flood)
2021-09-16 06:50:08 +0000jstolarek(~jstolarek@ers4.neoplus.adsl.tpnet.pl)
2021-09-16 06:51:15 +0000kuribas(~user@ptr-25vy0i96fc65i21clnv.18120a2.ip6.access.telenet.be)
2021-09-16 06:52:07 +0000dschrempf(~dominik@070-207.dynamic.dsl.fonira.net)
2021-09-16 06:52:46 +0000benin036932301(~benin@183.82.24.197) (Ping timeout: 252 seconds)
2021-09-16 06:53:05 +0000benin036932301(~benin@183.82.24.197)
2021-09-16 06:54:02 +0000falafel__(~falafel@2603-8000-d800-688c-753f-04f5-7eeb-6eb7.res6.spectrum.com)
2021-09-16 06:57:14 +0000falafel_(~falafel@2603-8000-d800-688c-753f-04f5-7eeb-6eb7.res6.spectrum.com) (Ping timeout: 260 seconds)
2021-09-16 07:02:31 +0000lavaman(~lavaman@98.38.249.169)
2021-09-16 07:03:53 +0000jakalx(~jakalx@base.jakalx.net)
2021-09-16 07:04:08 +0000 <kuribas> I got to present my haskell project to the company. Mostly it went well, they where quite interested. They asked me to explain why I think haskell is a good fit for the project.
2021-09-16 07:05:32 +0000 <kuribas> One example I give was type directed parsing of the CSV, which allows you to easily parse code with good error messages.
2021-09-16 07:05:47 +0000 <kuribas> Their response "we can do that in lisp, you don't need haskell for that"
2021-09-16 07:06:30 +0000 <tdammers> I can do that in C, no need for lisp
2021-09-16 07:06:30 +0000 <kuribas> My claims for robustness where refuted with "those are easy fixes, we don't care".
2021-09-16 07:06:55 +0000 <kuribas> point is, you "can" do this in lisp/clojure, but nobody does.
2021-09-16 07:07:06 +0000 <tdammers> case in point, though, CSV parsing is maybe not the most compelling example
2021-09-16 07:07:22 +0000 <Akronymus> csv's aren't even a good format
2021-09-16 07:07:37 +0000 <Akronymus> escape character > escaping the range
2021-09-16 07:07:43 +0000 <kuribas> true, but loading CSVs into the database was the usecase for this project.
2021-09-16 07:07:47 +0000 <tdammers> technically, CSV isn't even a format at all, there is no standard
2021-09-16 07:07:55 +0000 <kuribas> and we'll go to .ods
2021-09-16 07:08:16 +0000 <tdammers> seriously though, CSV data is basically [[String]], so there's not much to be gained in terms of type safety
2021-09-16 07:08:49 +0000 <Akronymus> But if you have a separator in the data, you have to use "
2021-09-16 07:08:52 +0000System123(~System123@net-37-179-171-3.cust.vodafonedsl.it)
2021-09-16 07:08:59 +0000eggplantade(~Eggplanta@2600:1700:bef1:5e10:fcfd:5153:b61b:fe3d) (Remote host closed the connection)
2021-09-16 07:09:06 +0000 <Akronymus> And if you have " in it too, you need to use "" afair
2021-09-16 07:09:09 +0000 <kuribas> tdammers: you need a parser [String] -> Either err a
2021-09-16 07:09:26 +0000 <Akronymus> Just let me do \<escape character>
2021-09-16 07:09:28 +0000 <kuribas> or (Map String String) -> a
2021-09-16 07:09:44 +0000 <tdammers> what? no
2021-09-16 07:09:58 +0000 <tdammers> there are only 2 special characters, you can special-case those in code
2021-09-16 07:10:34 +0000lavaman(~lavaman@98.38.249.169) (Remote host closed the connection)
2021-09-16 07:10:37 +0000VoidNoir0(~VoidNoir0@72.80.203.52)
2021-09-16 07:12:24 +0000 <Akronymus> tdammers `,;.:` all of those are valid for csv afair
2021-09-16 07:12:29 +0000 <kuribas> tdammers: but parsing a record is still better than taking a list with clojure types, and getting a stacktrace when the types don't match later.
2021-09-16 07:12:37 +0000 <Akronymus> Along with quoting
2021-09-16 07:13:17 +0000 <kuribas> three quotes, no?
2021-09-16 07:13:28 +0000 <kuribas> "abc" => """abc"""
2021-09-16 07:15:05 +0000 <kuribas> Another point was that all my queries worked the first time, and the type system even caught something that could be a subtle bug...
2021-09-16 07:15:43 +0000 <kuribas> Their response that it's hard to write such code, and those kind of errors are easy to fix.
2021-09-16 07:15:50 +0000 <DigitalKiwi> o/ ldlework
2021-09-16 07:15:57 +0000 <kuribas> Both of which statements I disagree with.
2021-09-16 07:16:22 +0000 <kuribas> 1) it's not that hard when you know what you do 2) Some of those bugs can be tricky to find.
2021-09-16 07:16:22 +0000 <ldlework> yo yo
2021-09-16 07:17:11 +0000 <awpr> kuribas: I haven't had much luck convincing people with those sorts of obviously different values that there's any value to Haskell. I've had better luck looking for people with the same values as me to begin with
2021-09-16 07:17:27 +0000 <kuribas> awpr: makes sense.
2021-09-16 07:18:03 +0000mousey(~sky@gateway/tor-sasl/mousey)
2021-09-16 07:18:22 +0000 <awpr> but if you have unlimited effort to convince people and manage to succeed, that's awesome
2021-09-16 07:18:31 +0000 <Akronymus> kuribas also: the bugs can make quite expensive problems even if they are easy to fix
2021-09-16 07:19:04 +0000 <kuribas> the sad thing is most of the developers where quite interested, only the two leads where giving me a hard time.
2021-09-16 07:19:18 +0000 <kuribas> trying as hard as possible to refute any of my arguments.
2021-09-16 07:19:21 +0000 <Akronymus> If they want lisp, implement haskell as a DSL? /s
2021-09-16 07:19:26 +0000 <awpr> guerilla Haskell team!
2021-09-16 07:19:30 +0000 <Akronymus> On top of lisp
2021-09-16 07:20:03 +0000 <Akronymus> kuribas was it a thesis defense or something?
2021-09-16 07:20:10 +0000vaucouleur(~vaucouleu@78.194.70.105)
2021-09-16 07:20:16 +0000 <kuribas> Akronymus: nah, a project I am doing in the company.
2021-09-16 07:20:30 +0000 <kuribas> It felt a bit like that yeah...
2021-09-16 07:21:21 +0000 <tdammers> kuribas: how can the types not match? It's all just strings. Converting those to "proper" types is something you'd do later, when you map the list-of-string CSV rows to more meaningful record types.
2021-09-16 07:21:34 +0000 <tdammers> I wouldn't call that "parsing"
2021-09-16 07:21:39 +0000 <Akronymus> Numbers?
2021-09-16 07:21:56 +0000 <kuribas> tdammers: I mean, the "later" is what I am talking about.
2021-09-16 07:22:15 +0000 <kuribas> tdammers: not the library code that takes a ByteString and returns a [[String]]
2021-09-16 07:22:24 +0000 <tdammers> OK
2021-09-16 07:23:11 +0000 <kuribas> anyway, the project is still ongoing, so if it works well and is very stable, I'll have proven my point :)
2021-09-16 07:23:32 +0000 <kuribas> then they'll rewrite it in clojure...
2021-09-16 07:23:56 +0000max22-(~maxime@2a01cb088335980073df05503d80cbee.ipv6.abo.wanadoo.fr)
2021-09-16 07:24:02 +0000falafel_(~falafel@2603-8000-d800-688c-753f-04f5-7eeb-6eb7.res6.spectrum.com)
2021-09-16 07:24:49 +0000 <tdammers> So you need to make the conversion explicit, and you have to somehow fail if the conversion is invalid. That goes for both Haskell and Clojure: in both cases, if the data is malformed, you have to throw (or return Nothing, or a Left Error, or however you decide to signal it) - malformed data is always going to cause a runtime error, not compile-time
2021-09-16 07:24:56 +0000 <kuribas> awpr: you're right, but otherwise I like the values of the company, working in renewables etc...
2021-09-16 07:25:05 +0000 <tdammers> so the "exception throwing" argument is a strawman
2021-09-16 07:25:12 +0000 <tdammers> Haskell's advantage is more subtle
2021-09-16 07:25:16 +0000 <dminuoso> Unless you unsafePerformIO in TemplateHaskell and load the file then, tdammers!
2021-09-16 07:25:23 +0000 <dminuoso> Oh wait, dont even need unsafePerformIO.
2021-09-16 07:25:24 +0000 <kuribas> tdammers: I am also not throwing, I collect the errors using Validation.
2021-09-16 07:25:37 +0000 <tdammers> dminuoso: indeed, there's runIO :: IO a -> Q a
2021-09-16 07:25:48 +0000 <tdammers> kuribas: you can do the same in clojure though
2021-09-16 07:26:04 +0000 <tdammers> kuribas: hence the "or however you want to signal it" part
2021-09-16 07:26:35 +0000 <kuribas> tdammers: you can do anything in any language which is turing complete.
2021-09-16 07:26:37 +0000 <tdammers> kuribas: the advantage that Haskell brings is that once you've done the conversion, the type system can make sure, statically, that from that point onwards, your data is valid as per the type
2021-09-16 07:26:52 +0000 <kuribas> indeed, I made that point.
2021-09-16 07:27:37 +0000falafel__(~falafel@2603-8000-d800-688c-753f-04f5-7eeb-6eb7.res6.spectrum.com) (Ping timeout: 268 seconds)
2021-09-16 07:28:20 +0000 <kuribas> IMO, it's not just about what the language can do, but also the idiomatic way to do things.
2021-09-16 07:29:07 +0000 <kuribas> Because in practice, people in clojure simply don't start from a single "type definition", which they use to verify the types, etc...
2021-09-16 07:29:24 +0000 <kuribas> Being more rigorous is *possible* in clojure, but most of the time not done.
2021-09-16 07:29:48 +0000 <kuribas> The honeysql libary for example *should* validate the arguments, so the generated SQL is valid, but it doesn't.
2021-09-16 07:30:20 +0000 <tdammers> it's all about ergonomics and meatware performance
2021-09-16 07:30:37 +0000 <tdammers> (which is also why the Turing Completeness argument is utter bullshit)
2021-09-16 07:30:45 +0000merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2021-09-16 07:30:47 +0000 <kuribas> Even if the query generator is correct, some error in an unrelated part can cause the generation of an invalid query, or even a valid but simply wrong query.
2021-09-16 07:31:12 +0000 <tdammers> yup. welcome to the crazy world of the Consenting Adults Fallacy
2021-09-16 07:31:20 +0000 <kuribas> what's that?
2021-09-16 07:33:10 +0000falafel_(~falafel@2603-8000-d800-688c-753f-04f5-7eeb-6eb7.res6.spectrum.com) (Ping timeout: 260 seconds)
2021-09-16 07:35:49 +0000bitmapper(uid464869@id-464869.lymington.irccloud.com) (Quit: Connection closed for inactivity)
2021-09-16 07:41:08 +0000lavaman(~lavaman@98.38.249.169)
2021-09-16 07:43:14 +0000 <tdammers> a thing from the Python community, where they reject features like proper module systems, type systems, controllable mutability, etc., saying that "we're all consenting adults here, we don't need to police each other", which is of course not what any of those features are about, but the sentiments runs quite strong - not just in the Python community, but in pretty much any dynamic language
2021-09-16 07:43:23 +0000Sgeo(~Sgeo@user/sgeo) (Read error: Connection reset by peer)
2021-09-16 07:43:43 +0000 <tdammers> it's kind of a gross overestimation of the reliability and feasibility of manual diligence
2021-09-16 07:44:16 +0000 <tdammers> "without a type checker, how can I make sure that nobody passes the wrong arguments to this function?" - "well, duh, just don't pass the wrong arguments, ezpz"
2021-09-16 07:44:42 +0000 <kuribas> yeah, in our place it's called "garbage in - garbage out".
2021-09-16 07:45:51 +0000lavaman(~lavaman@98.38.249.169) (Ping timeout: 265 seconds)
2021-09-16 07:46:04 +0000 <Drew[m]> "I have an excellent and flawless plan. All it requires is to get everyone everywhere to alter their behavior."
2021-09-16 07:48:09 +0000 <kuribas> How am I suppose to know what is garbage in a function I didn't write, or write a year ago, and which has no type signature...
2021-09-16 07:48:21 +0000tzh(~tzh@c-24-21-73-154.hsd1.wa.comcast.net) (Quit: zzz)
2021-09-16 07:49:17 +0000 <tdammers> easy: just read the code :P
2021-09-16 07:49:52 +0000 <dminuoso> 09:26:37 tdammers | kuribas: the advantage that Haskell brings is that once you've done the conversion, the type system can make sure, statically, that from that point onwards, your data is valid as per the type
2021-09-16 07:50:16 +0000 <dminuoso> Having seen a talk by Richard Hickey, Im nearly convinced that your averge clojure fan will not care about that in the slightest.
2021-09-16 07:50:56 +0000 <kuribas> yeah
2021-09-16 07:51:00 +0000 <tdammers> having written clojure professionally for a year and a half, I'm gonna say you're probably right
2021-09-16 07:51:48 +0000ph88^(~ph88@2a02:8109:9e00:7e5c:c17a:3fe0:849c:9e0a)
2021-09-16 07:52:22 +0000hnOsmium0001(uid453710@id-453710.hampstead.irccloud.com) (Quit: Connection closed for inactivity)
2021-09-16 07:55:09 +0000ph88(~ph88@2a02:8109:9e00:7e5c:c17a:3fe0:849c:9e0a) (Ping timeout: 268 seconds)
2021-09-16 07:59:45 +0000System12_(~System123@ec2-52-61-197-79.us-gov-west-1.compute.amazonaws.com)
2021-09-16 08:03:10 +0000System123(~System123@net-37-179-171-3.cust.vodafonedsl.it) (Ping timeout: 252 seconds)
2021-09-16 08:03:14 +0000hendursa1(~weechat@user/hendursaga)
2021-09-16 08:04:21 +0000mousey(~sky@gateway/tor-sasl/mousey) (Ping timeout: 276 seconds)
2021-09-16 08:05:45 +0000dexterfoo(dexter@2a01:7e00::f03c:91ff:fe86:59ec)
2021-09-16 08:06:00 +0000hendursa2(~weechat@user/hendursaga)
2021-09-16 08:06:18 +0000hendursaga(~weechat@user/hendursaga) (Ping timeout: 276 seconds)
2021-09-16 08:09:09 +0000Gurkenglas(~Gurkengla@dslb-002-207-014-195.002.207.pools.vodafone-ip.de)
2021-09-16 08:09:24 +0000eggplantade(~Eggplanta@2600:1700:bef1:5e10:fcfd:5153:b61b:fe3d)
2021-09-16 08:09:33 +0000hendursa1(~weechat@user/hendursaga) (Ping timeout: 276 seconds)
2021-09-16 08:13:51 +0000nschoe(~quassel@2a04:cec0:11d0:a38e:f051:be01:a43f:d5b6)
2021-09-16 08:14:28 +0000mc47(~mc47@xmonad/TheMC47)
2021-09-16 08:15:06 +0000eggplantade(~Eggplanta@2600:1700:bef1:5e10:fcfd:5153:b61b:fe3d) (Ping timeout: 268 seconds)
2021-09-16 08:15:49 +0000Vajb(~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) (Read error: Connection reset by peer)
2021-09-16 08:16:07 +0000hyiltiz(~quassel@31.220.5.250) (Ping timeout: 268 seconds)
2021-09-16 08:17:02 +0000Vajb(~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi)
2021-09-16 08:17:45 +0000allbery_b(~geekosaur@xmonad/geekosaur)
2021-09-16 08:17:45 +0000geekosaur(~geekosaur@xmonad/geekosaur) (Killed (NickServ (GHOST command used by allbery_b)))
2021-09-16 08:17:48 +0000allbery_bgeekosaur
2021-09-16 08:17:56 +0000hyiltiz(~quassel@31.220.5.250)
2021-09-16 08:21:09 +0000max22-(~maxime@2a01cb088335980073df05503d80cbee.ipv6.abo.wanadoo.fr) (Quit: Leaving)
2021-09-16 08:23:33 +0000theang(~theang@fef109.internetdsl.tpnet.pl) (Ping timeout: 265 seconds)
2021-09-16 08:24:54 +0000theang(~theang@2a00:f41:58f0:244b:4742:c02a:6877:e413)
2021-09-16 08:26:43 +0000slowButPresent(~slowButPr@user/slowbutpresent) (Quit: leaving)
2021-09-16 08:30:55 +0000benin036932301(~benin@183.82.24.197) (Ping timeout: 268 seconds)
2021-09-16 08:31:25 +0000eggplantade(~Eggplanta@2600:1700:bef1:5e10:c18a:e65c:d93c:bac0)
2021-09-16 08:32:57 +0000eggplant_(~Eggplanta@2600:1700:bef1:5e10:65ff:a34c:5e53:2b94)
2021-09-16 08:33:22 +0000System12_(~System123@ec2-52-61-197-79.us-gov-west-1.compute.amazonaws.com) (Ping timeout: 260 seconds)
2021-09-16 08:33:39 +0000amahl(~amahl@dsl-jklbng12-54fbca-64.dhcp.inet.fi)
2021-09-16 08:34:18 +0000merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 260 seconds)
2021-09-16 08:34:59 +0000econo(uid147250@user/econo) (Quit: Connection closed for inactivity)
2021-09-16 08:35:00 +0000chele_(~chele@user/chele)
2021-09-16 08:35:09 +0000chele(~chele@user/chele) (Ping timeout: 265 seconds)
2021-09-16 08:36:28 +0000eggplantade(~Eggplanta@2600:1700:bef1:5e10:c18a:e65c:d93c:bac0) (Ping timeout: 268 seconds)
2021-09-16 08:36:54 +0000chele_(~chele@user/chele) (Remote host closed the connection)
2021-09-16 08:37:55 +0000eggplant_(~Eggplanta@2600:1700:bef1:5e10:65ff:a34c:5e53:2b94) (Ping timeout: 268 seconds)
2021-09-16 08:42:08 +0000azeem(~azeem@2a00:801:23a:d5ca:5e0:54f5:67cf:d7dc) (Read error: Connection reset by peer)
2021-09-16 08:45:46 +0000azeem(~azeem@emp-91-123.eduroam.uu.se)
2021-09-16 08:46:40 +0000mateusz(~mateusz@83.0.46.72.internetdsl.tpnet.pl)
2021-09-16 08:46:51 +0000 <ldlework> I just got hylide working and i'm kind of excited
2021-09-16 08:47:35 +0000__monty__(~toonn@user/toonn)
2021-09-16 08:54:11 +0000System123(~System123@net-37-179-171-3.cust.vodafonedsl.it)
2021-09-16 08:56:00 +0000 <mateusz> Hi! I want to understand deeper why `untest` function cannot compile due to type error. The question is what should I look for in order to understand that? data Test = X Int | Y String deriving Show
2021-09-16 08:56:01 +0000 <mateusz> untest val = case val of ; X i -> i ; Y s -> s
2021-09-16 08:57:13 +0000 <__monty__> mateusz: The first step is really reading the type error.
2021-09-16 08:57:19 +0000 <__monty__> @where paste
2021-09-16 08:57:19 +0000 <lambdabot> Help us help you: please paste full code, input and/or output at e.g. https://paste.tomsmeding.com
2021-09-16 08:57:33 +0000 <__monty__> Output includes the errors : )
2021-09-16 08:58:41 +0000Guest2294(~neo3@cpe-292712.ip.primehome.com)
2021-09-16 08:58:48 +0000 <dminuoso> mateusz: The only way to write something as generic as that, is with GADTs.
2021-09-16 08:58:49 +0000Guest2294neo1
2021-09-16 08:59:02 +0000ezzieyguywuf(~Unknown@user/ezzieyguywuf) (Ping timeout: 260 seconds)
2021-09-16 08:59:10 +0000ezzieyguywuf(~Unknown@user/ezzieyguywuf)
2021-09-16 08:59:19 +0000System123(~System123@net-37-179-171-3.cust.vodafonedsl.it) (Ping timeout: 265 seconds)
2021-09-16 08:59:24 +0000 <mateusz> So error says like types don't match, and its probably due to type inference but I wonder if there is any way in standard Haskell (without extensions) to manually annotate that https://paste.tomsmeding.com/2aHWTmAo
2021-09-16 08:59:37 +0000 <dminuoso> The thing is
2021-09-16 08:59:45 +0000 <dminuoso> What do you expect the return type of that function?
2021-09-16 09:00:58 +0000 <mateusz> What I can't understand is that if I annotate this as: `Test -> a` it doesnt work, I would expect type to be a, and based on expression either Int or String
2021-09-16 09:01:11 +0000 <dminuoso> You can do this with GADTs.
2021-09-16 09:01:17 +0000 <dminuoso> % data Test a where X :: Int -> Test Int; Y :: String -> Test String
2021-09-16 09:01:18 +0000 <yahb> dminuoso:
2021-09-16 09:01:28 +0000 <dminuoso> % untest val = case val of; X i -> i; Y s -> s
2021-09-16 09:01:28 +0000 <yahb> dminuoso: ; <interactive>:24:34: error:; * Couldn't match expected type `p' with actual type `Int'; `p' is untouchable inside the constraints: a ~ Int bound by a pattern with constructor: X :: Int -> Test Int, in a case alternative at <interactive>:24:27-29; `p' is a rigid type variable bound by; the inferred type of untest :: Test a -> p; at <interactive>:24:1-44; Possible
2021-09-16 09:01:37 +0000 <dminuoso> Hold on
2021-09-16 09:02:14 +0000 <__monty__> mateusz: But if the return type were 'a' then someone calling the function would get to choose the type. How can your function return a value of any type it is asked for starting from a Test?
2021-09-16 09:02:24 +0000 <mateusz> thanks, will look into that later but I think I should understand why it throws error before I dive into GADTs, any resource or search keyword which might help in it?
2021-09-16 09:02:39 +0000 <dminuoso> % untest :: Test a -> a; untest val = case val of; X i -> i; Y s -> s
2021-09-16 09:02:39 +0000 <yahb> dminuoso:
2021-09-16 09:02:42 +0000 <dminuoso> mateusz: ^- there.
2021-09-16 09:03:00 +0000 <kuribas> mateusz: the idiomatic way is to return a sumtype.
2021-09-16 09:03:08 +0000 <awpr> a) can't infer stuff across GADT constructor matches, but b) I doubt GADTs are the most helpful answer here, this seems like a case of missing some key aspects of type checking
2021-09-16 09:03:14 +0000 <dminuoso> mateusz: Your expectation is *exactly* what GADTs fill. :)
2021-09-16 09:03:28 +0000 <kuribas> or just go to idris :)
2021-09-16 09:03:34 +0000 <dminuoso> Then you can annotate it as `Test a -> a` exactly.
2021-09-16 09:03:52 +0000 <dminuoso> GADTs are a very intuitive and almost obvious conclusion of ADTs, really.
2021-09-16 09:04:10 +0000hpc(~juzz@ip98-169-35-13.dc.dc.cox.net) (Ping timeout: 260 seconds)
2021-09-16 09:04:40 +0000 <dminuoso> mateusz: So part of the reason without GADTs is the way that type variables work. A type variable is something the caller/consumer must chose.
2021-09-16 09:04:48 +0000 <awpr> sure, but they're probably not the next step after "why doesn't this function work as `forall a. Test -> a`?"
2021-09-16 09:04:56 +0000 <dminuoso> Let's for the same of argument argue that you coudl write it as:
2021-09-16 09:05:03 +0000 <dminuoso> untest :: Test -> a; untest = ...
2021-09-16 09:05:16 +0000 <dminuoso> That means, the *consumer* of untest can pick an arbitrary type for `a`
2021-09-16 09:05:22 +0000sim590(~simon@modemcable090.207-203-24.mc.videotron.ca) (Ping timeout: 252 seconds)
2021-09-16 09:05:27 +0000 <dminuoso> Irrespective of what the value of Test is.
2021-09-16 09:05:34 +0000ezzieyguywuf(~Unknown@user/ezzieyguywuf) (Ping timeout: 260 seconds)
2021-09-16 09:06:08 +0000 <dminuoso> So you coudl write something like:
2021-09-16 09:06:18 +0000 <kuribas> the cps version is still "simple" haskell, the GADT is not.
2021-09-16 09:06:20 +0000 <dminuoso> `untest (Y "String") :: Float`
2021-09-16 09:06:26 +0000ezzieyguywuf(~Unknown@user/ezzieyguywuf)
2021-09-16 09:06:54 +0000 <dminuoso> Which is of course non-sense.
2021-09-16 09:07:45 +0000 <mateusz> ok so the question is where from comes the constaint of not typing this union like: `Test -> [Int|String]`? Is it from system f?
2021-09-16 09:08:05 +0000 <mateusz> kuribas what you mean by cps?
2021-09-16 09:08:11 +0000 <kuribas> mateusz: Continuation passing style
2021-09-16 09:08:25 +0000 <kuribas> mateusz: That would be "Text -> Either Int String"
2021-09-16 09:08:32 +0000 <__monty__> mateusz: It's because that would mean the caller gets to pick whether the return type is Int or String *regardless* of what the input Test value is.
2021-09-16 09:09:06 +0000chris(~chris@81.96.113.213)
2021-09-16 09:09:09 +0000chrisGuest240
2021-09-16 09:09:19 +0000 <kuribas> mateusz: untest :: Text -> (Int -> a) -> (String -> a) -> a
2021-09-16 09:09:19 +0000merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2021-09-16 09:09:23 +0000hpc(~juzz@ip98-169-35-13.dc.dc.cox.net)
2021-09-16 09:09:29 +0000 <__monty__> kuribas: Test, not Text.
2021-09-16 09:09:48 +0000 <kuribas> __monty__: yeah. Muscle memory
2021-09-16 09:11:58 +0000max22-(~maxime@2a01cb08833598004808c986d8fd0bff.ipv6.abo.wanadoo.fr)
2021-09-16 09:12:00 +0000 <awpr> wow, QuickCheck discovered the Haskell `\&` syntax all on its own and showed me a bug regarding it
2021-09-16 09:12:09 +0000Guest240(~chris@81.96.113.213) (Remote host closed the connection)
2021-09-16 09:12:19 +0000nschoe(~quassel@2a04:cec0:11d0:a38e:f051:be01:a43f:d5b6) (Remote host closed the connection)
2021-09-16 09:12:22 +0000 <mateusz> kuribas i don't get this example, why two additional args?
2021-09-16 09:12:33 +0000 <kuribas> mateusz: one for each case
2021-09-16 09:13:13 +0000 <kuribas> mateusz: but note that untest doesn't do anything useful.
2021-09-16 09:13:16 +0000 <mateusz> hmm this example shows how to make polymorphic a possible with untest function?
2021-09-16 09:13:32 +0000nschoe(~quassel@2a04:cec0:11d0:a38e:b326:412:811:9d36)
2021-09-16 09:13:33 +0000 <mateusz> polymorphic `a`
2021-09-16 09:13:40 +0000pounce(~pounce@facebook/engineering/pounce) (Ping timeout: 240 seconds)
2021-09-16 09:13:50 +0000 <kuribas> mateusz: no, `a` is the return type of the continuation.
2021-09-16 09:14:13 +0000 <kuribas> see for example the either function
2021-09-16 09:14:14 +0000 <kuribas> :t either
2021-09-16 09:14:15 +0000 <lambdabot> (a -> c) -> (b -> c) -> Either a b -> c
2021-09-16 09:14:52 +0000 <kuribas> it's case matching on each case.
2021-09-16 09:15:01 +0000 <kuribas> And you get a different continuation for each.
2021-09-16 09:15:19 +0000 <mateusz> why different if both return `c`?
2021-09-16 09:15:45 +0000 <mateusz> I cant handle differently way from a/b to c
2021-09-16 09:15:48 +0000 <kuribas> > either show id $ (Left 2 :: Either Int String)
2021-09-16 09:15:50 +0000 <lambdabot> "2"
2021-09-16 09:16:01 +0000 <kuribas> > either show id $ (Right "2" :: Either Int String)
2021-09-16 09:16:03 +0000 <lambdabot> "2"
2021-09-16 09:16:52 +0000 <kuribas> mateusz: but note that normally you just pattern match. either just makes the code a bit shorter.
2021-09-16 09:17:33 +0000 <kuribas> > case (Left 2 :: Either Int String) of Left i -> show i; Right s -> s
2021-09-16 09:17:35 +0000 <lambdabot> "2"
2021-09-16 09:18:16 +0000 <kuribas> mateusz: you have to handle them differently, since they have different types.
2021-09-16 09:19:01 +0000 <__monty__> mateusz: Inference example, `\x -> toUpper (id x) :: Char -> Char`, what is the inferred type of `id` here?
2021-09-16 09:19:17 +0000pounce(~pounce@facebook/engineering/pounce)
2021-09-16 09:20:02 +0000ishutin_(~ishutin@87-97-12-212.pool.digikabel.hu) (Ping timeout: 260 seconds)
2021-09-16 09:20:40 +0000 <mateusz> __monty__ Char?
2021-09-16 09:21:02 +0000 <__monty__> No, id is a function, so the type has to have an `->`.
2021-09-16 09:21:24 +0000ishutin(~ishutin@80-95-82-223.pool.digikabel.hu)
2021-09-16 09:21:26 +0000 <mateusz> :D i meant `Char->Char` because its derived from lambda annotation
2021-09-16 09:21:47 +0000 <__monty__> And do you see where that Char is coming from?
2021-09-16 09:22:13 +0000 <__monty__> You're inferring it from the *output* side a in `a -> a`, right? Not the input side?
2021-09-16 09:22:15 +0000max22-(~maxime@2a01cb08833598004808c986d8fd0bff.ipv6.abo.wanadoo.fr) (Remote host closed the connection)
2021-09-16 09:22:18 +0000 <mateusz> I think yes, `x` can be Char exclusively so id has to return Char
2021-09-16 09:22:37 +0000 <mateusz> I inferred from input
2021-09-16 09:22:41 +0000 <__monty__> How do you know x can only be Char?
2021-09-16 09:22:43 +0000 <mateusz> input to lambda
2021-09-16 09:22:51 +0000 <__monty__> Ah, crap.
2021-09-16 09:22:54 +0000 <mateusz> from the annotation for lambda: `Char->Char`
2021-09-16 09:22:58 +0000 <__monty__> Shouldn't have put a signature on it >.<
2021-09-16 09:23:03 +0000max22-(~maxime@2a01cb0883359800c203f4e20803de91.ipv6.abo.wanadoo.fr)
2021-09-16 09:23:19 +0000 <__monty__> Let's just pretend I gave you `toUpper . id`.
2021-09-16 09:24:50 +0000 <__monty__> Do you see how the inference for the type of id would be the same even though you have no information about the type of the input?
2021-09-16 09:25:36 +0000 <mateusz> given that toUpper is `Char->Char` and id `a->a`, contraint comes from toUpper which expect `Char` as input so i think it would be `Char->Char`
2021-09-16 09:25:46 +0000 <__monty__> Exactly.
2021-09-16 09:25:56 +0000 <__monty__> How about `toUpper . untest`?
2021-09-16 09:26:00 +0000 <mateusz> Are there any priorities in inference rules?
2021-09-16 09:26:06 +0000 <mateusz> wow give me sec
2021-09-16 09:28:11 +0000System123(~System123@net-37-179-171-3.cust.vodafonedsl.it)
2021-09-16 09:31:14 +0000 <mateusz> consider `toUpper :: Text->Text`, OverloadedStrings, I can't pick untest implementation which dosnt raise type error
2021-09-16 09:31:28 +0000pretty_dumm_guy(trottel@gateway/vpn/protonvpn/prettydummguy/x-88029655)
2021-09-16 09:32:03 +0000 <mateusz> or will define untestY as function which returns always Text, so it matches
2021-09-16 09:32:33 +0000 <mateusz> __monty__
2021-09-16 09:34:39 +0000hannessteffenhag(~hannesste@ip4d14ffd8.dynamic.kabel-deutschland.de) (Ping timeout: 268 seconds)
2021-09-16 09:34:47 +0000 <__monty__> mateusz: Let's take `Data.Char.toUpper . untest`. OverloadedStrings is only complicating matters.
2021-09-16 09:35:46 +0000eggplantade(~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net)
2021-09-16 09:35:46 +0000 <mateusz> so not sure which implementation of untest you picked, the one I proposed (`Test -> a`) which doesnt compile?
2021-09-16 09:35:54 +0000 <__monty__> Yeah.
2021-09-16 09:36:33 +0000 <mateusz> ok, so `Test -> Char` but it doesnt sound right to me becaouse untest may also return Int which is unhandled
2021-09-16 09:36:46 +0000 <__monty__> No, it's exactly correct.
2021-09-16 09:37:02 +0000 <__monty__> Do you see how I as a user of your untest function get to constrain the return type?
2021-09-16 09:37:38 +0000 <__monty__> You seemed to think that as the definer of untest you got to fill in the `a`, but that's not the case.
2021-09-16 09:38:04 +0000 <__monty__> If you say your function returns `a` it *really* has to be able to return any type.
2021-09-16 09:38:41 +0000 <mateusz> I think I start to understand that
2021-09-16 09:38:49 +0000 <__monty__> Just like how when you say a function takes input type `a` it has to actually be able to deal with *any* value I can give it.
2021-09-16 09:38:53 +0000Everything(~Everythin@37.115.210.35) ()
2021-09-16 09:40:36 +0000merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 268 seconds)
2021-09-16 09:40:49 +0000eggplantade(~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 268 seconds)
2021-09-16 09:41:05 +0000 <mateusz> So I wonder if there you know about any formal description of this so I can revise it in moments of doubt?
2021-09-16 09:41:13 +0000nschoe(~quassel@2a04:cec0:11d0:a38e:b326:412:811:9d36) (Ping timeout: 268 seconds)
2021-09-16 09:41:13 +0000nschoe_(~quassel@178.251.84.79)
2021-09-16 09:41:29 +0000xsperry(~as@user/xsperry)
2021-09-16 09:41:30 +0000xsperry(~as@user/xsperry) (Excess Flood)
2021-09-16 09:42:40 +0000pounce(~pounce@facebook/engineering/pounce) (Ping timeout: 240 seconds)
2021-09-16 09:43:18 +0000pounce(~pounce@facebook/engineering/pounce)
2021-09-16 09:43:52 +0000max22-(~maxime@2a01cb0883359800c203f4e20803de91.ipv6.abo.wanadoo.fr) (Remote host closed the connection)
2021-09-16 09:44:37 +0000max22-(~maxime@2a01cb0883359800326db5d5b924c729.ipv6.abo.wanadoo.fr)
2021-09-16 09:47:12 +0000eggplantade(~Eggplanta@2600:1700:bef1:5e10:6430:ba41:fc15:9c04)
2021-09-16 09:47:56 +0000xsperry(~as@user/xsperry)
2021-09-16 09:48:49 +0000eggplant_(~Eggplanta@2600:1700:bef1:5e10:c461:91fb:5e87:26b7)
2021-09-16 09:50:52 +0000 <kuribas> mateusz: it's easy to confuse the type variable `a` with a supertype, or Any type. But it really is just a variable, it stands for another type.
2021-09-16 09:51:40 +0000eggplantade(~Eggplanta@2600:1700:bef1:5e10:6430:ba41:fc15:9c04) (Ping timeout: 240 seconds)
2021-09-16 09:52:24 +0000 <__monty__> Unfortunately I don't have a good reference, it's the kind of thing you internalize and forget where you learned about it, though for me that was here : )
2021-09-16 09:52:37 +0000 <kuribas> types and programming languages?
2021-09-16 09:52:42 +0000max22-(~maxime@2a01cb0883359800326db5d5b924c729.ipv6.abo.wanadoo.fr) (Remote host closed the connection)
2021-09-16 09:53:10 +0000eggplant_(~Eggplanta@2600:1700:bef1:5e10:c461:91fb:5e87:26b7) (Ping timeout: 240 seconds)
2021-09-16 09:53:34 +0000 <mateusz> thanks all for help, will look into that @kur
2021-09-16 09:54:15 +0000hololeap(~hololeap@user/hololeap) (Remote host closed the connection)
2021-09-16 09:54:28 +0000max22-(~maxime@2a01cb0883359800b93d6fac2a60b640.ipv6.abo.wanadoo.fr)
2021-09-16 09:54:46 +0000max22-(~maxime@2a01cb0883359800b93d6fac2a60b640.ipv6.abo.wanadoo.fr) (Remote host closed the connection)
2021-09-16 09:55:42 +0000hololeap(~hololeap@user/hololeap)
2021-09-16 09:57:27 +0000hannessteffenhag(~hannesste@ip4d14ffd8.dynamic.kabel-deutschland.de)
2021-09-16 09:58:07 +0000chris(~chris@81.96.113.213)
2021-09-16 09:58:11 +0000chrisGuest5493
2021-09-16 09:58:23 +0000 <__monty__> Quite a heavy reference for something like this : )
2021-09-16 10:00:40 +0000System123(~System123@net-37-179-171-3.cust.vodafonedsl.it) (Ping timeout: 240 seconds)
2021-09-16 10:10:18 +0000tromp(~textual@dhcp-077-249-230-040.chello.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2021-09-16 10:10:51 +0000 <kuribas> yeah, a basic haskell course should explain it as well.
2021-09-16 10:12:33 +0000max22-(~maxime@2a01cb08833598005b81de1e843a31cc.ipv6.abo.wanadoo.fr)
2021-09-16 10:16:10 +0000azeem(~azeem@emp-91-123.eduroam.uu.se) (Read error: Connection reset by peer)
2021-09-16 10:16:44 +0000tromp(~textual@dhcp-077-249-230-040.chello.nl)
2021-09-16 10:20:27 +0000jacks2(~bc8165b6@217.29.117.252)
2021-09-16 10:21:37 +0000 <DigitalKiwi> i missed half of that conversation and thought __monty__ said this irc channel was quite a heavy reference not tapl and i think that would be more correct lol
2021-09-16 10:21:59 +0000 <kuribas> ah right
2021-09-16 10:22:18 +0000 <DigitalKiwi> at least if i set out to read tapl i could do it in a finite amount of time
2021-09-16 10:22:42 +0000 <DigitalKiwi> >10 years probably and i'm still reading this channel
2021-09-16 10:24:28 +0000chele(~chele@user/chele)
2021-09-16 10:24:29 +0000 <kuribas> this channel good when you are stuck.
2021-09-16 10:24:43 +0000 <kuribas> But you really should read a book if you are serious with learning.
2021-09-16 10:25:03 +0000 <DigitalKiwi> is it bad when i am not stuck
2021-09-16 10:26:58 +0000thyriaen(~thyriaen@dynamic-078-055-122-076.78.55.pool.telefonica.de)
2021-09-16 10:27:43 +0000tfeb(~tfb@host81-155-127-18.range81-155.btcentralplus.com)
2021-09-16 10:28:12 +0000tfeb(~tfb@host81-155-127-18.range81-155.btcentralplus.com) (Read error: Connection reset by peer)
2021-09-16 10:32:13 +0000juhp(~juhp@128.106.188.220) (Ping timeout: 252 seconds)
2021-09-16 10:32:18 +0000Guest5493(~chris@81.96.113.213) (Remote host closed the connection)
2021-09-16 10:35:03 +0000vysn(~vysn@user/vysn)
2021-09-16 10:36:23 +0000raehik(~raehik@2a00:23c6:4c83:a901:95bf:f7ec:7b7d:c21e)
2021-09-16 10:36:50 +0000frisbro(uid518331@id-518331.helmsley.irccloud.com)
2021-09-16 10:37:48 +0000frisbro_(uid518331@id-518331.helmsley.irccloud.com)
2021-09-16 10:49:58 +0000mateusz(~mateusz@83.0.46.72.internetdsl.tpnet.pl) (Quit: Client closed)
2021-09-16 10:51:45 +0000raehik(~raehik@2a00:23c6:4c83:a901:95bf:f7ec:7b7d:c21e) (Ping timeout: 260 seconds)
2021-09-16 10:53:03 +0000raehik(~raehik@2a00:23c6:4c83:a901:95bf:f7ec:7b7d:c21e)
2021-09-16 11:00:59 +0000alx741(~alx741@181.196.68.49)
2021-09-16 11:03:45 +0000raehik(~raehik@2a00:23c6:4c83:a901:95bf:f7ec:7b7d:c21e) (Quit: WeeChat 3.2)
2021-09-16 11:04:34 +0000amahl(~amahl@dsl-jklbng12-54fbca-64.dhcp.inet.fi) (Ping timeout: 260 seconds)
2021-09-16 11:10:18 +0000neurocyte(~neurocyte@user/neurocyte) (Quit: The Lounge - https://thelounge.chat)
2021-09-16 11:12:40 +0000gentauro(~gentauro@user/gentauro) (Ping timeout: 240 seconds)
2021-09-16 11:12:46 +0000Akronymus(~Akronymus@85.31.8.180) (Quit: Client closed)
2021-09-16 11:12:58 +0000Akronymus(~Akronymus@85.31.8.180)
2021-09-16 11:14:22 +0000neurocyte(~neurocyte@185.117.68.241)
2021-09-16 11:14:22 +0000neurocyte(~neurocyte@185.117.68.241) (Changing host)
2021-09-16 11:14:22 +0000neurocyte(~neurocyte@user/neurocyte)
2021-09-16 11:16:49 +0000jespada(~jespada@2803:9800:9842:7a62:e809:3117:30c6:aea3)
2021-09-16 11:20:27 +0000Cajun(~Cajun@user/cajun) (Quit: Client closed)
2021-09-16 11:20:44 +0000System123(~System123@net-37-179-171-3.cust.vodafonedsl.it)
2021-09-16 11:22:29 +0000lavaman(~lavaman@98.38.249.169)
2021-09-16 11:27:54 +0000lavaman(~lavaman@98.38.249.169) (Ping timeout: 260 seconds)
2021-09-16 11:29:36 +0000gentauro(~gentauro@user/gentauro)
2021-09-16 11:30:25 +0000burnsidesLlama(~burnsides@dhcp168-022.wadham.ox.ac.uk)
2021-09-16 11:37:04 +0000merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2021-09-16 11:37:09 +0000Akronymus(~Akronymus@85.31.8.180) (Quit: Client closed)
2021-09-16 11:37:14 +0000zer0bitz(~zer0bitz@dsl-hkibng31-54fafc-123.dhcp.inet.fi)
2021-09-16 11:37:19 +0000Akronymus(~Akronymus@85.31.8.180)
2021-09-16 11:40:56 +0000jacks2(~bc8165b6@217.29.117.252) (Quit: http://www.okay.uz/)
2021-09-16 11:41:22 +0000[itchyjunk](~itchyjunk@user/itchyjunk/x-7353470)
2021-09-16 11:46:31 +0000__monty__(~toonn@user/toonn) (Quit: leaving)
2021-09-16 11:46:33 +0000GuestTHU16_1(~GuestTHU1@219.91.230.26)
2021-09-16 11:46:52 +0000 <GuestTHU16_1> how can the + operator be prefix
2021-09-16 11:47:01 +0000 <GuestTHU16_1> like + a b
2021-09-16 11:47:11 +0000 <sshine> (+) a b
2021-09-16 11:47:18 +0000 <sshine> > (+) 1 2
2021-09-16 11:47:20 +0000 <lambdabot> 3
2021-09-16 11:47:24 +0000 <GuestTHU16_1> ok.
2021-09-16 11:47:31 +0000caubert(~caubert@136.244.111.235) (Quit: WeeChat 3.2)
2021-09-16 11:48:02 +0000 <hpc> and for completeness, if you have a "lettery" identifier you can do a `plus` b
2021-09-16 11:48:07 +0000 <hpc> to infix it
2021-09-16 11:48:42 +0000 <_________> what about postfix ?
2021-09-16 11:48:52 +0000dschrempf(~dominik@070-207.dynamic.dsl.fonira.net) (Ping timeout: 268 seconds)
2021-09-16 11:49:06 +0000 <sshine> they were never that popular
2021-09-16 11:49:40 +0000 <GuestTHU16_1> Prelude> 3 `plus` 4
2021-09-16 11:49:41 +0000 <GuestTHU16_1> <interactive>:32:4: error:
2021-09-16 11:49:41 +0000 <GuestTHU16_1> Variable not in scope: plus :: Integer -> Integer -> t
2021-09-16 11:49:54 +0000eggplantade(~Eggplanta@2600:1700:bef1:5e10:9052:e8ea:d68a:7809)
2021-09-16 11:50:22 +0000dschrempf(~dominik@070-207.dynamic.dsl.fonira.net)
2021-09-16 11:50:30 +0000gehmehgeh(~user@user/gehmehgeh)
2021-09-16 11:50:49 +0000 <sshine> :t (":" `isPrefixOf`)
2021-09-16 11:50:50 +0000 <lambdabot> [Char] -> Bool
2021-09-16 11:51:01 +0000 <sshine> not exactly postfix, but sort of.
2021-09-16 11:51:14 +0000 <geekosaur> there's an extension for "postfix" that is pretty limited
2021-09-16 11:51:58 +0000 <sshine> yeah, I went looking for it, and the first page of search results wasn't even that useful, so I'm guessing people have stopped using it.
2021-09-16 11:52:04 +0000 <geekosaur> https://downloads.haskell.org/ghc/latest/docs/html/users_guide/exts/rebindable_syntax.html#postfix…
2021-09-16 11:52:25 +0000 <geekosaur> not sure they ever really used it
2021-09-16 11:52:40 +0000 <sshine> oh, uhm. yeah.
2021-09-16 11:52:52 +0000 <geekosaur> (also, since 7.10? that was in 6.6)
2021-09-16 11:52:56 +0000Pickchea(~private@user/pickchea)
2021-09-16 11:54:01 +0000 <sshine> > let (!) n = product [1..n] in (5 !)
2021-09-16 11:54:02 +0000 <lambdabot> 120
2021-09-16 11:54:09 +0000caubert(~caubert@136.244.111.235)
2021-09-16 11:54:13 +0000eggplantade(~Eggplanta@2600:1700:bef1:5e10:9052:e8ea:d68a:7809) (Ping timeout: 252 seconds)
2021-09-16 11:54:32 +0000 <_________> > let (+) l = sum l in ([1..5] +)
2021-09-16 11:54:34 +0000 <lambdabot> 15
2021-09-16 11:54:49 +0000 <_________> nice
2021-09-16 11:56:29 +0000System123(~System123@net-37-179-171-3.cust.vodafonedsl.it) (Ping timeout: 268 seconds)
2021-09-16 11:56:30 +0000 <sshine> _________, I've used this more to create more readable function names, e.g. (":" `isPrefixOf`) vs. isPrefixOf ":" (since it looks like "something is prefix of ":", when in fact it is ":" that is prefix of something).
2021-09-16 11:57:58 +0000 <sshine> _________, so normally you might write x `isPrefixOf` y, but in cases where you only do partial application, rather than e.g. 'any (\y -> x `isPrefixOf` y) ys' or 'any (isPrefixOf x) ys', I prefer 'any (x `isPrefixOf`) ys'.
2021-09-16 11:58:46 +0000 <sshine> _________, having actual postfix operators like '!' to signify factorial is pretty rarely useful, so you don't really see a bunch of functions grow out of that idea.
2021-09-16 11:59:13 +0000GuestTHU16_1(~GuestTHU1@219.91.230.26) (Quit: Client closed)
2021-09-16 11:59:44 +0000 <sshine> _________, have you seen the monkey operator? (:[])
2021-09-16 11:59:59 +0000 <sshine> > let monkey = (:[]) in monkey 5
2021-09-16 12:00:00 +0000 <lambdabot> [5]
2021-09-16 12:00:31 +0000dschrempf(~dominik@070-207.dynamic.dsl.fonira.net) (Quit: WeeChat 3.2.1)
2021-09-16 12:01:03 +0000Vajb(~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) (Ping timeout: 265 seconds)
2021-09-16 12:01:17 +0000Vajb(~Vajb@nbptnppvs5wp2vjps-2.v6.elisa-mobile.fi)
2021-09-16 12:02:55 +0000chris(~chris@81.96.113.213)
2021-09-16 12:02:59 +0000chrisGuest3036
2021-09-16 12:03:29 +0000 <_________> > let (+) = sum, (*) = product in ((([1,2,3] +) [6,7] :) *)
2021-09-16 12:03:30 +0000 <lambdabot> <hint>:1:14: error: parse error on input ‘,’
2021-09-16 12:03:40 +0000 <_________> > let (+) = sum in let (*) = product in ((([1,2,3] +) [6,7] :) *)
2021-09-16 12:03:42 +0000 <lambdabot> error:
2021-09-16 12:03:42 +0000 <lambdabot> • Could not deduce (Num a0)
2021-09-16 12:03:42 +0000 <lambdabot> from the context: (Foldable ((->) [a]), Num a1, Num ([a1] -> a),
2021-09-16 12:05:15 +0000max22-(~maxime@2a01cb08833598005b81de1e843a31cc.ipv6.abo.wanadoo.fr) (Ping timeout: 260 seconds)
2021-09-16 12:05:56 +0000sheddow(~sheddow@84-52-255.245.3p.ntebredband.no)
2021-09-16 12:07:08 +0000oxide(~lambda@user/oxide)
2021-09-16 12:07:22 +0000Guest3036(~chris@81.96.113.213) (Ping timeout: 252 seconds)
2021-09-16 12:08:16 +0000cuz(~user@2601:182:cc02:8b0:c414:97d1:1f4d:202f)
2021-09-16 12:09:29 +0000cuz(~user@2601:182:cc02:8b0:c414:97d1:1f4d:202f) (Remote host closed the connection)
2021-09-16 12:09:52 +0000cuz(~user@2601:182:cc02:8b0:c414:97d1:1f4d:202f)
2021-09-16 12:11:10 +0000merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 240 seconds)
2021-09-16 12:11:10 +0000Vajb(~Vajb@nbptnppvs5wp2vjps-2.v6.elisa-mobile.fi) (Read error: Connection reset by peer)
2021-09-16 12:11:22 +0000Vajb(~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi)
2021-09-16 12:14:23 +0000waleee(~waleee@2001:9b0:216:8200:d457:9189:7843:1dbd) (Quit: WeeChat 3.2.1)
2021-09-16 12:16:33 +0000hololeap(~hololeap@user/hololeap) (Ping timeout: 276 seconds)
2021-09-16 12:16:39 +0000zer0bitz_(~zer0bitz@dsl-hkibng31-54fafc-123.dhcp.inet.fi)
2021-09-16 12:17:15 +0000hololeap(~hololeap@user/hololeap)
2021-09-16 12:17:48 +0000Vajb(~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) (Read error: Connection reset by peer)
2021-09-16 12:18:38 +0000Vajb(~Vajb@nbptnppvs5wp2vjps-2.v6.elisa-mobile.fi)
2021-09-16 12:18:56 +0000zer0bitz(~zer0bitz@dsl-hkibng31-54fafc-123.dhcp.inet.fi) (Ping timeout: 265 seconds)
2021-09-16 12:23:24 +0000Vajb(~Vajb@nbptnppvs5wp2vjps-2.v6.elisa-mobile.fi) (Read error: Connection reset by peer)
2021-09-16 12:23:57 +0000Vajb(~Vajb@nbptnppvs5wp2vjps-2.v6.elisa-mobile.fi)
2021-09-16 12:25:23 +0000dsrt^(~dsrt@68.101.54.227)
2021-09-16 12:26:44 +0000 <sshine> > let (┻━┻) = intersperse 'f'; ノಠ益ಠノ = "Python" in (ノಠ益ಠノ ┻━┻)
2021-09-16 12:26:45 +0000Vajb(~Vajb@nbptnppvs5wp2vjps-2.v6.elisa-mobile.fi) (Read error: Connection reset by peer)
2021-09-16 12:26:45 +0000 <lambdabot> "Pfyftfhfofn"
2021-09-16 12:27:20 +0000Vajb(~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi)
2021-09-16 12:28:39 +0000 <Hecate> https://www.unicode.org/versions/Unicode14.0.0/ it's out!
2021-09-16 12:28:57 +0000jtomas(~jtomas@95.red-88-11-64.dynamicip.rima-tde.net)
2021-09-16 12:30:01 +0000neurocyte(~neurocyte@user/neurocyte) (Quit: The Lounge - https://thelounge.chat)
2021-09-16 12:30:42 +0000 <sshine> 🥳 𝕪𝕒𝕪!
2021-09-16 12:30:55 +0000dsrt^(~dsrt@68.101.54.227) (Remote host closed the connection)
2021-09-16 12:33:06 +0000Vajb(~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) (Read error: Connection reset by peer)
2021-09-16 12:34:07 +0000neurocyte(~neurocyte@185.117.68.241)
2021-09-16 12:34:07 +0000neurocyte(~neurocyte@185.117.68.241) (Changing host)
2021-09-16 12:34:07 +0000neurocyte(~neurocyte@user/neurocyte)
2021-09-16 12:35:33 +0000Vajb(~Vajb@85-76-8-0-nat.elisa-mobile.fi)
2021-09-16 12:35:58 +0000Vajb(~Vajb@85-76-8-0-nat.elisa-mobile.fi) (Read error: Connection reset by peer)
2021-09-16 12:35:59 +0000bitdex(~bitdex@gateway/tor-sasl/bitdex) (Quit: = "")
2021-09-16 12:36:09 +0000Vajb(~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi)
2021-09-16 12:38:03 +0000machinedgod(~machinedg@135-23-192-217.cpe.pppoe.ca)
2021-09-16 12:40:20 +0000 <sshine> wow, you can sponsor a unicode character: https://www.unicode.org/consortium/adopt-a-character.html
2021-09-16 12:42:49 +0000nedh^(~nedh@68.101.54.227)
2021-09-16 12:45:06 +0000Vajb(~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) (Read error: Connection reset by peer)
2021-09-16 12:46:04 +0000Vajb(~Vajb@nbptnppvs5wp2vjps-2.v6.elisa-mobile.fi)
2021-09-16 12:48:37 +0000xff0x(~xff0x@port-92-195-42-138.dynamic.as20676.net) (Ping timeout: 252 seconds)
2021-09-16 12:49:32 +0000juhp(~juhp@bb220-255-204-220.singnet.com.sg)
2021-09-16 12:53:13 +0000Vajb(~Vajb@nbptnppvs5wp2vjps-2.v6.elisa-mobile.fi) (Read error: Connection reset by peer)
2021-09-16 12:54:01 +0000Vajb(~Vajb@nbptnppvs5wp2vjps-2.v6.elisa-mobile.fi)
2021-09-16 12:54:48 +0000tromp(~textual@dhcp-077-249-230-040.chello.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2021-09-16 12:55:31 +0000xff0x(~xff0x@2001:1a81:526d:1c00:6ed0:c2d3:55f8:e793)
2021-09-16 12:55:37 +0000burnsidesLlama(~burnsides@dhcp168-022.wadham.ox.ac.uk) (Remote host closed the connection)
2021-09-16 12:56:00 +0000Cajun(~Cajun@user/cajun)
2021-09-16 12:56:05 +0000 <Hecate> % scanl1 (+) . map (succ . length) $ [["lol", "mdr", "haha"], ["blah", "bleh"]]
2021-09-16 12:56:05 +0000 <yahb> Hecate: [4,7]
2021-09-16 12:59:34 +0000benin036932301(~benin@183.82.205.89)
2021-09-16 12:59:53 +0000 <sshine> > ('o':) . pure . chr . foldl1 (\x y -> 10*x+y) . scanl1 (+) . map (succ . length) $ [["lol", "mdr", "haha"], ["blah", "bleh"]]
2021-09-16 12:59:54 +0000 <lambdabot> "o/"
2021-09-16 13:01:09 +0000chris(~chris@81.96.113.213)
2021-09-16 13:01:12 +0000chrisGuest7647
2021-09-16 13:02:38 +0000AlexNoo(~AlexNoo@178.34.162.211) (Quit: Leaving)
2021-09-16 13:03:26 +0000Alex_test(~al_test@178.34.162.211) (Quit: ;-)
2021-09-16 13:03:33 +0000AlexZenon(~alzenon@178.34.162.211) (Quit: ;-)
2021-09-16 13:03:56 +0000ph88(~ph88@ip5f5af6fd.dynamic.kabel-deutschland.de)
2021-09-16 13:06:40 +0000ph88^(~ph88@2a02:8109:9e00:7e5c:c17a:3fe0:849c:9e0a) (Ping timeout: 240 seconds)
2021-09-16 13:06:41 +0000Vajb(~Vajb@nbptnppvs5wp2vjps-2.v6.elisa-mobile.fi) (Read error: Connection reset by peer)
2021-09-16 13:06:55 +0000shapr(~user@pool-100-36-247-68.washdc.fios.verizon.net)
2021-09-16 13:07:30 +0000Vajb(~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi)
2021-09-16 13:09:31 +0000Vajb(~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) (Read error: Connection reset by peer)
2021-09-16 13:09:52 +0000Vajb(~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi)
2021-09-16 13:12:41 +0000hendursa2(~weechat@user/hendursaga) (Quit: hendursa2)
2021-09-16 13:12:57 +0000jstolarek(~jstolarek@ers4.neoplus.adsl.tpnet.pl) (Ping timeout: 268 seconds)
2021-09-16 13:13:13 +0000jstolarek(~jstolarek@165.231.33.108)
2021-09-16 13:13:28 +0000hendursaga(~weechat@user/hendursaga)
2021-09-16 13:13:59 +0000Vajb(~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) (Read error: Connection reset by peer)
2021-09-16 13:14:04 +0000zer0bitz_(~zer0bitz@dsl-hkibng31-54fafc-123.dhcp.inet.fi) (Ping timeout: 252 seconds)
2021-09-16 13:15:03 +0000Vajb(~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi)
2021-09-16 13:17:28 +0000Lycurgus(~juan@98.4.112.204)
2021-09-16 13:17:40 +0000vysn(~vysn@user/vysn) (Ping timeout: 268 seconds)
2021-09-16 13:18:17 +0000jstolarek(~jstolarek@165.231.33.108) (Ping timeout: 268 seconds)
2021-09-16 13:19:42 +0000jokleinn(~jokleinn@user/jokleinn)
2021-09-16 13:20:04 +0000jstolarek(~jstolarek@188.241.156.4)
2021-09-16 13:24:42 +0000goepsilongo(~goepsilon@2603-7000-ab00-62ed-217f-c4e6-d1e6-03f0.res6.spectrum.com)
2021-09-16 13:26:55 +0000burnsidesLlama(~burnsides@dhcp168-022.wadham.ox.ac.uk)
2021-09-16 13:27:07 +0000AlexZenon(~alzenon@178.34.162.211)
2021-09-16 13:27:50 +0000AlexZenon(~alzenon@178.34.162.211) (Client Quit)
2021-09-16 13:28:09 +0000hammock(~Hammock@2600:1700:19a1:3330::588) (Ping timeout: 268 seconds)
2021-09-16 13:28:09 +0000AlexZenon(~alzenon@178.34.162.211)
2021-09-16 13:28:18 +0000AlexNoo(~AlexNoo@178.34.162.211)
2021-09-16 13:29:57 +0000Alex_test(~al_test@178.34.162.211)
2021-09-16 13:30:28 +0000motherfsck(~motherfsc@user/motherfsck)
2021-09-16 13:31:19 +0000System123(~System123@ec2-52-61-197-79.us-gov-west-1.compute.amazonaws.com)
2021-09-16 13:31:50 +0000Sgeo(~Sgeo@user/sgeo)
2021-09-16 13:32:30 +0000burnsidesLlama(~burnsides@dhcp168-022.wadham.ox.ac.uk) (Ping timeout: 260 seconds)
2021-09-16 13:36:27 +0000jstolarek(~jstolarek@188.241.156.4) (Read error: Connection reset by peer)
2021-09-16 13:37:06 +0000tromp(~textual@dhcp-077-249-230-040.chello.nl)
2021-09-16 13:39:03 +0000jstolarek(~jstolarek@ers4.neoplus.adsl.tpnet.pl)
2021-09-16 13:41:21 +0000tito(tito@tilde.team)
2021-09-16 13:43:23 +0000Guest7647(~chris@81.96.113.213) (Remote host closed the connection)
2021-09-16 13:49:02 +0000gehmehgeh(~user@user/gehmehgeh) (Quit: Leaving)
2021-09-16 13:49:23 +0000max22-(~maxime@2a01cb0883359800cbea6a523dcdbf78.ipv6.abo.wanadoo.fr)
2021-09-16 13:50:14 +0000jokleinn(~jokleinn@user/jokleinn) (Ping timeout: 260 seconds)
2021-09-16 13:50:21 +0000 <kuribas> We are getting this error on macOs: Undefined symbols for architecture x86_64: > "___darwin_check_fd_set_overflow", referenced from: > _awaitEvent in libHSrts.a(Select.o) > ld: symbol(s) not found for architecture x86_64 > clang: error: linker command failed with exit code 1 (use -v to see invocation) > `gcc' failed in phase `Linker'. (Exit code: 1)
2021-09-16 13:53:21 +0000 <maerwald> kuribas: https://gitlab.haskell.org/ghc/ghc/-/issues/19950
2021-09-16 13:53:43 +0000 <maerwald> seems you're not running 8.10.7
2021-09-16 13:55:17 +0000 <kuribas> ghc?
2021-09-16 13:55:27 +0000 <maerwald> yeah
2021-09-16 13:56:11 +0000 <kuribas> 8.10.7
2021-09-16 13:56:17 +0000 <kuribas> 8.10.6 sorry
2021-09-16 13:56:20 +0000 <maerwald> yeah
2021-09-16 13:56:44 +0000chris(~chris@81.96.113.213)
2021-09-16 13:56:47 +0000chrisGuest9212
2021-09-16 13:57:07 +0000Guest9212(~chris@81.96.113.213) (Read error: Connection reset by peer)
2021-09-16 13:58:37 +0000chris(~chris@81.96.113.213)
2021-09-16 13:58:41 +0000chrisGuest3568
2021-09-16 13:59:43 +0000 <kuribas> isn't it risky to run bleeding edge?
2021-09-16 13:59:52 +0000 <kuribas> this is what I don't like about stack.
2021-09-16 14:01:02 +0000 <maerwald> kuribas: you can use my stack ghc install hooks :p
2021-09-16 14:01:15 +0000 <maerwald> but it's not upstreamed
2021-09-16 14:01:31 +0000ubert1(~Thunderbi@178.115.48.20.wireless.dyn.drei.com)
2021-09-16 14:01:46 +0000juhp_(~juhp@bb220-255-204-220.singnet.com.sg)
2021-09-16 14:02:22 +0000ubert(~Thunderbi@178.165.161.81.wireless.dyn.drei.com) (Ping timeout: 252 seconds)
2021-09-16 14:02:22 +0000ubert1ubert
2021-09-16 14:02:47 +0000juhp_(~juhp@bb220-255-204-220.singnet.com.sg) (Read error: Connection reset by peer)
2021-09-16 14:02:49 +0000jespada(~jespada@2803:9800:9842:7a62:e809:3117:30c6:aea3) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2021-09-16 14:03:18 +0000sm2n_sm2n
2021-09-16 14:03:19 +0000juhp(~juhp@bb220-255-204-220.singnet.com.sg) (Read error: Connection reset by peer)
2021-09-16 14:03:27 +0000juhp(~juhp@bb220-255-204-220.singnet.com.sg)
2021-09-16 14:04:05 +0000 <maerwald> allows you to provide a shell script that performs installation/discovery of ghc
2021-09-16 14:04:08 +0000System123(~System123@ec2-52-61-197-79.us-gov-west-1.compute.amazonaws.com) (Ping timeout: 268 seconds)
2021-09-16 14:04:27 +0000 <maerwald> so the shell script gets "need 8.10.6" as input and you can just install 8.10.7 instead
2021-09-16 14:04:58 +0000 <maerwald> micro version barely matters for dependency resolution anyway
2021-09-16 14:06:36 +0000nedh^(~nedh@68.101.54.227) (Ping timeout: 268 seconds)
2021-09-16 14:06:41 +0000 <maerwald> https://downloads.haskell.org/~ghcup/unofficial-bindists/stack/2.7.3.1/
2021-09-16 14:06:47 +0000 <maerwald> example hook https://paste.tomsmeding.com/NI4H4xT3
2021-09-16 14:06:58 +0000 <maerwald> needs to be placed in ~/.stack/hooks/
2021-09-16 14:07:22 +0000merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2021-09-16 14:08:35 +0000oxide(~lambda@user/oxide) (Quit: oxide)
2021-09-16 14:08:53 +0000 <Drew[m]> I want to see if a package can build on a platform it doesn't currently support, but the test suite absolutely cannot be built on this thanks to some dependencies platform. Is it the default behavior of cabal to try to resolve test suite dependencies even if I specifically ask to build just the package library component?
2021-09-16 14:09:04 +0000 <Drew[m]> Because that's what this package is currently doing
2021-09-16 14:09:22 +0000 <maerwald> Drew[m]: maybe there's stuff in cabal.project?
2021-09-16 14:09:46 +0000cfricke(~cfricke@user/cfricke) (Quit: WeeChat 3.2.1)
2021-09-16 14:10:52 +0000ph88(~ph88@ip5f5af6fd.dynamic.kabel-deutschland.de) (Ping timeout: 245 seconds)
2021-09-16 14:11:10 +0000 <Drew[m]> the cabal.project file lists the test suite dependency package that can't be build under "packages"
2021-09-16 14:11:53 +0000mc47(~mc47@xmonad/TheMC47) (Remote host closed the connection)
2021-09-16 14:11:55 +0000 <Drew[m]> Should that matter if I specifically ask to build a specific component of a different package in the project?
2021-09-16 14:12:09 +0000 <maerwald> all depends
2021-09-16 14:12:21 +0000 <maerwald> hard to say without seeing the project
2021-09-16 14:13:56 +0000 <Drew[m]> The project is reflex-dom
2021-09-16 14:13:58 +0000 <Drew[m]> https://github.com/reflex-frp/reflex-dom
2021-09-16 14:14:38 +0000 <Drew[m]> From the top level folder I'm trying to execute `cabal build reflex-dom-core:lib:reflex-dom-core -f +use-warp --dry-run`
2021-09-16 14:14:59 +0000 <Drew[m]> I'm not sure my component identifier syntax is right
2021-09-16 14:15:48 +0000 <maerwald> `--disable-tests`?
2021-09-16 14:17:12 +0000ph88(~ph88@ip5f5af6fd.dynamic.kabel-deutschland.de)
2021-09-16 14:18:41 +0000 <Drew[m]> As in `cabal build reflex-dom-core:lib:reflex-dom-core -f +use-warp --disable-tests`?
2021-09-16 14:18:45 +0000shriekingnoise(~shrieking@186.137.144.80)
2021-09-16 14:18:47 +0000 <maerwald> yeah
2021-09-16 14:20:02 +0000nschoe_(~quassel@178.251.84.79) (Quit: https://quassel-irc.org - Chat comfortably. Anywhere.)
2021-09-16 14:20:21 +0000nschoe(~quassel@178.251.84.79)
2021-09-16 14:20:33 +0000 <Drew[m]> I just tried it and it's still failing in dependency resolution, referring to dependencies that don't seem to belong to `reflex-dom-core`'s library
2021-09-16 14:20:35 +0000 <Drew[m]> https://paste.tomsmeding.com/0YiZEKmR
2021-09-16 14:20:56 +0000Akronymus(~Akronymus@85.31.8.180) (Quit: Client closed)
2021-09-16 14:21:30 +0000cuz(~user@2601:182:cc02:8b0:c414:97d1:1f4d:202f) (Ping timeout: 260 seconds)
2021-09-16 14:22:07 +0000 <Drew[m]> So here's a thing, there's a project file: cabal.project-nogtk
2021-09-16 14:22:12 +0000 <Drew[m]> It turns off some flags
2021-09-16 14:22:19 +0000 <Drew[m]> If you use it, it works
2021-09-16 14:22:39 +0000 <maerwald> that file just removes the test stuff from packages
2021-09-16 14:22:42 +0000 <Drew[m]> What I want to know is how those flags are disabling this dependency
2021-09-16 14:23:36 +0000 <Drew[m]> So those package dependencies have to be satisfied even if I'm building a different package in the project?
2021-09-16 14:23:44 +0000 <maerwald> usually not
2021-09-16 14:24:02 +0000Guest3568(~chris@81.96.113.213) (Remote host closed the connection)
2021-09-16 14:24:37 +0000sheddow(~sheddow@84-52-255.245.3p.ntebredband.no) (Ping timeout: 256 seconds)
2021-09-16 14:24:42 +0000eggplantade(~Eggplanta@2600:1700:bef1:5e10:854d:ae90:d2a1:51ab)
2021-09-16 14:24:48 +0000wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
2021-09-16 14:24:48 +0000wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Changing host)
2021-09-16 14:24:48 +0000wroathe(~wroathe@user/wroathe)
2021-09-16 14:25:05 +0000 <infinisil> A couple days ago I asked for help about a problem where a program would take multiple minutes to complete a very small amount of work, but turning on profiling made it finish instantly, leaving me unable to profile it, merijn was involved in the discussion
2021-09-16 14:25:40 +0000jespada(~jespada@2803:9800:9842:7a62:95e0:d2b5:ae88:676)
2021-09-16 14:25:43 +0000 <infinisil> Update for that: It turns out https://hackage.haskell.org/package/concise-0.1.0.1/docs/Control-Lens-Cons-Extras.html was the cause of it, which uses a combination of NOINLINE and rewrite rules
2021-09-16 14:26:29 +0000 <infinisil> I submitted a fix for the library that uses this here, which has more discussion on this problem: https://github.com/frasertweedale/hs-jose/pull/103
2021-09-16 14:29:10 +0000eggplantade(~Eggplanta@2600:1700:bef1:5e10:854d:ae90:d2a1:51ab) (Ping timeout: 240 seconds)
2021-09-16 14:30:06 +0000ArsenArsen[test]
2021-09-16 14:30:21 +0000Arsen[test]Arsen
2021-09-16 14:30:42 +0000ArsenArsen_test[m]
2021-09-16 14:30:51 +0000Arsen_test[m]group
2021-09-16 14:30:59 +0000groupArsen
2021-09-16 14:32:40 +0000fendor(~fendor@83-131-155-114.adsl.net.t-com.hr)
2021-09-16 14:33:26 +0000 <Franciman> haskell sux
2021-09-16 14:33:36 +0000 <Franciman> sorry I had to get a fast answer
2021-09-16 14:33:37 +0000 <Drew[m]> maerwald: curious! I wish I could figure out why
2021-09-16 14:33:40 +0000 <Franciman> ok it work
2021-09-16 14:33:43 +0000 <Franciman> :P
2021-09-16 14:34:11 +0000cuz(~user@38.140.58.234)
2021-09-16 14:36:27 +0000hnOsmium0001(uid453710@id-453710.hampstead.irccloud.com)
2021-09-16 14:37:20 +0000nedh^(~nedh@68.101.54.227)
2021-09-16 14:38:03 +0000goepsilongo(~goepsilon@2603-7000-ab00-62ed-217f-c4e6-d1e6-03f0.res6.spectrum.com) (Quit: Textual IRC Client: www.textualapp.com)
2021-09-16 14:38:30 +0000jess(~jess@libera/staff/jess) ()
2021-09-16 14:39:38 +0000chris(~chris@81.96.113.213)
2021-09-16 14:39:43 +0000chrisGuest5190
2021-09-16 14:41:42 +0000xstill(~xstill@fimu/xstill)
2021-09-16 14:41:45 +0000merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 268 seconds)
2021-09-16 14:42:20 +0000jlamothe(~jlamothe@104.158.48.100) (Quit: leaving)
2021-09-16 14:42:48 +0000 <xstill> hi, is there any chance downloads.haskell.org/debian will contain bullseye binaries any time soon?
2021-09-16 14:43:29 +0000Guest5190(~chris@81.96.113.213) (Read error: Connection reset by peer)
2021-09-16 14:43:45 +0000chris(~chris@81.96.113.213)
2021-09-16 14:43:49 +0000chrisGuest9509
2021-09-16 14:47:54 +0000 <kuribas> Franciman: it does... but other language suck more...
2021-09-16 14:48:02 +0000 <kuribas> maerwaldthanks!
2021-09-16 14:49:51 +0000doyougnu(~user@c-73-25-202-122.hsd1.or.comcast.net)
2021-09-16 14:50:23 +0000neo1(~neo3@cpe-292712.ip.primehome.com) (Ping timeout: 268 seconds)
2021-09-16 14:52:01 +0000theang(~theang@2a00:f41:58f0:244b:4742:c02a:6877:e413) (Ping timeout: 268 seconds)
2021-09-16 14:52:18 +0000theang(~theang@fef109.internetdsl.tpnet.pl)
2021-09-16 14:52:40 +0000Pickchea(~private@user/pickchea) (Ping timeout: 260 seconds)
2021-09-16 14:54:48 +0000dschrempf(~dominik@070-207.dynamic.dsl.fonira.net)
2021-09-16 14:56:58 +0000proofofkeags_(~proofofke@97-118-134-2.hlrn.qwest.net) (Ping timeout: 260 seconds)
2021-09-16 14:57:24 +0000Franciman(~Franciman@openglass.it) (Remote host closed the connection)
2021-09-16 15:00:51 +0000cheater1__(~Username@user/cheater)
2021-09-16 15:00:51 +0000cheater(~Username@user/cheater) (Ping timeout: 265 seconds)
2021-09-16 15:00:55 +0000cheater1__cheater
2021-09-16 15:07:27 +0000Xe(~cadey@tailscale/xe) (Quit: WeeChat 3.2)
2021-09-16 15:07:27 +0000Ranhir(~Ranhir@157.97.53.139) (Quit: KVIrc 5.0.0 Aria http://www.kvirc.net/)
2021-09-16 15:07:42 +0000Xe(~cadey@tailscale/xe)
2021-09-16 15:07:51 +0000shaprhops randomly
2021-09-16 15:08:21 +0000Ranhir(~Ranhir@157.97.53.139)
2021-09-16 15:09:28 +0000juhp(~juhp@bb220-255-204-220.singnet.com.sg) (Quit: juhp)
2021-09-16 15:12:46 +0000 <sshine> /nick hopr
2021-09-16 15:13:50 +0000zmt00(~zmt00@user/zmt00)
2021-09-16 15:14:01 +0000Franciman(~Franciman@openglass.it)
2021-09-16 15:14:25 +0000jstolarek(~jstolarek@ers4.neoplus.adsl.tpnet.pl) (Ping timeout: 252 seconds)
2021-09-16 15:16:27 +0000pavonia(~user@user/siracusa) (Quit: Bye!)
2021-09-16 15:17:40 +0000wroathe(~wroathe@user/wroathe) (Ping timeout: 240 seconds)
2021-09-16 15:17:55 +0000juhp(~juhp@bb220-255-204-220.singnet.com.sg)
2021-09-16 15:21:00 +0000chele(~chele@user/chele) (Read error: Connection reset by peer)
2021-09-16 15:21:09 +0000dschrempf(~dominik@070-207.dynamic.dsl.fonira.net) (Ping timeout: 265 seconds)
2021-09-16 15:21:11 +0000chele(~chele@user/chele)
2021-09-16 15:21:33 +0000ec_(~ec@gateway/tor-sasl/ec)
2021-09-16 15:22:09 +0000tromp(~textual@dhcp-077-249-230-040.chello.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2021-09-16 15:34:06 +0000fendor(~fendor@83-131-155-114.adsl.net.t-com.hr) (Remote host closed the connection)
2021-09-16 15:34:28 +0000fendor(~fendor@83-131-155-114.adsl.net.t-com.hr)
2021-09-16 15:35:00 +0000wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
2021-09-16 15:35:01 +0000wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Changing host)
2021-09-16 15:35:01 +0000wroathe(~wroathe@user/wroathe)
2021-09-16 15:35:31 +0000Lycurgus(~juan@98.4.112.204) (Quit: Exeunt)
2021-09-16 15:39:56 +0000mikoto-chan(~mikoto-ch@ip-83-134-2-136.dsl.scarlet.be)
2021-09-16 15:40:00 +0000wroathe(~wroathe@user/wroathe) (Ping timeout: 265 seconds)
2021-09-16 15:42:19 +0000eggplantade(~Eggplanta@2600:1700:bef1:5e10:854d:ae90:d2a1:51ab)
2021-09-16 15:42:25 +0000proofofkeags_(~proofofke@205.209.28.54)
2021-09-16 15:43:15 +0000ec_(~ec@gateway/tor-sasl/ec) (Ping timeout: 276 seconds)
2021-09-16 15:44:02 +0000zebrag(~chris@user/zebrag)
2021-09-16 15:46:50 +0000jokleinn(~jokleinn@user/jokleinn)
2021-09-16 15:48:08 +0000favonia(~favonia@user/favonia) (Ping timeout: 268 seconds)
2021-09-16 15:53:50 +0000ec_(~ec@gateway/tor-sasl/ec)
2021-09-16 15:54:08 +0000spruit11_(~quassel@2a02:a467:ccd6:1:563:f225:f6bf:7d85)
2021-09-16 15:57:36 +0000spruit11(~quassel@2a02:a467:ccd6:1:8499:aaa7:da86:787a) (Ping timeout: 268 seconds)
2021-09-16 16:01:38 +0000[itchyjunk](~itchyjunk@user/itchyjunk/x-7353470) (Quit: Leaving)
2021-09-16 16:01:56 +0000jokleinn(~jokleinn@user/jokleinn) (Quit: WeeChat 3.2)
2021-09-16 16:03:47 +0000lbseale(~lbseale@user/ep1ctetus)
2021-09-16 16:04:58 +0000_ht(~quassel@82-169-194-8.biz.kpn.net)
2021-09-16 16:05:14 +0000akronymus[m](~akronymus@2001:470:69fc:105::f7be) ()
2021-09-16 16:07:40 +0000jokleinn(~jokleinn@user/jokleinn)
2021-09-16 16:07:52 +0000wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
2021-09-16 16:07:52 +0000wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Changing host)
2021-09-16 16:07:52 +0000wroathe(~wroathe@user/wroathe)
2021-09-16 16:08:02 +0000fendor(~fendor@83-131-155-114.adsl.net.t-com.hr) (Ping timeout: 265 seconds)
2021-09-16 16:10:33 +0000ec_(~ec@gateway/tor-sasl/ec) (Ping timeout: 276 seconds)
2021-09-16 16:10:50 +0000slowButPresent(~slowButPr@user/slowbutpresent)
2021-09-16 16:17:05 +0000tromp(~textual@dhcp-077-249-230-040.chello.nl)
2021-09-16 16:17:28 +0000ec_(~ec@gateway/tor-sasl/ec)
2021-09-16 16:18:54 +0000Guest9509(~chris@81.96.113.213) (Remote host closed the connection)
2021-09-16 16:20:16 +0000enicar(~enikar@user/enikar)
2021-09-16 16:21:55 +0000hyiltiz(~quassel@31.220.5.250) (Ping timeout: 260 seconds)
2021-09-16 16:26:02 +0000chris(~chris@81.96.113.213)
2021-09-16 16:26:02 +0000chrisGuest1324
2021-09-16 16:26:42 +0000favonia(~favonia@user/favonia)
2021-09-16 16:28:48 +0000 <Drew[m]> Ok so after doing my own test, it turns out that by default cabal automatically checks the dependencies of all packages in a project when resolving dependencies to build just one
2021-09-16 16:29:15 +0000 <Drew[m]> And I need to figure out a way to say I don't want that
2021-09-16 16:30:16 +0000Guest1324(~chris@81.96.113.213) (Ping timeout: 252 seconds)
2021-09-16 16:37:48 +0000enicar(~enikar@user/enikar) (Quit: WeeChat 3.2.1)
2021-09-16 16:38:00 +0000nschoe(~quassel@178.251.84.79) (Ping timeout: 265 seconds)
2021-09-16 16:38:17 +0000merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2021-09-16 16:39:44 +0000dschrempf(~dominik@070-207.dynamic.dsl.fonira.net)
2021-09-16 16:40:27 +0000ec_(~ec@gateway/tor-sasl/ec) (Ping timeout: 276 seconds)
2021-09-16 16:42:14 +0000fendor(~fendor@83-131-155-114.adsl.net.t-com.hr)
2021-09-16 16:42:58 +0000hyiltiz(~quassel@31.220.5.250)
2021-09-16 16:43:45 +0000MQ-17J(~MQ-17J@8.21.10.6)
2021-09-16 16:44:40 +0000mikoto-chan(~mikoto-ch@ip-83-134-2-136.dsl.scarlet.be) (Ping timeout: 260 seconds)
2021-09-16 16:45:44 +0000ec_(~ec@gateway/tor-sasl/ec)
2021-09-16 16:46:45 +0000mikoto-chan(~mikoto-ch@ip-83-134-2-136.dsl.scarlet.be)
2021-09-16 16:47:34 +0000tdammers(~tdammers@77.109.72.213.res.static.edpnet.net) (Ping timeout: 260 seconds)
2021-09-16 16:48:17 +0000justsomeguy(~justsomeg@user/justsomeguy)
2021-09-16 16:50:32 +0000Teacup(~teacup@user/teacup) (Quit: Teacup)
2021-09-16 16:50:53 +0000Cajun(~Cajun@user/cajun) (Quit: Client closed)
2021-09-16 16:53:25 +0000choucavalier(~choucaval@peanutbuttervibes.com)
2021-09-16 16:54:40 +0000choucavalier(~choucaval@peanutbuttervibes.com) (Changing host)
2021-09-16 16:54:40 +0000choucavalier(~choucaval@user/choucavalier)
2021-09-16 16:56:36 +0000jstolarek(~jstolarek@ers4.neoplus.adsl.tpnet.pl)
2021-09-16 16:56:57 +0000timCF(~timCF@m91-129-108-244.cust.tele2.ee)
2021-09-16 16:58:02 +0000jokleinn(~jokleinn@user/jokleinn) (Ping timeout: 268 seconds)
2021-09-16 16:59:25 +0000 <timCF> Hello! Is there any good combinator libraries for Aeson to transform/compose `Value` AST data? For example I need to apply filter to `Value` in case where it's an object and get new object `Value` where `Null` value fields are removed. Maybe I can use `lens-aeson` for this, but I don't know how exactly
2021-09-16 17:00:00 +0000chele(~chele@user/chele) (Remote host closed the connection)
2021-09-16 17:00:00 +0000 <sm> congrats infinisil
2021-09-16 17:00:27 +0000tdammers(~tdammers@77.109.72.177.res.static.edpnet.net)
2021-09-16 17:01:00 +0000 <infinisil> :D
2021-09-16 17:02:59 +0000jokleinn(~jokleinn@user/jokleinn)
2021-09-16 17:04:22 +0000MQ-17J(~MQ-17J@8.21.10.6) (Ping timeout: 260 seconds)
2021-09-16 17:04:40 +0000MQ-17J(~MQ-17J@8.21.10.6)
2021-09-16 17:05:35 +0000econo(uid147250@user/econo)
2021-09-16 17:07:12 +0000zebrag(~chris@user/zebrag) (Quit: Konversation terminated!)
2021-09-16 17:08:40 +0000dschrempf(~dominik@070-207.dynamic.dsl.fonira.net) (Ping timeout: 240 seconds)
2021-09-16 17:09:46 +0000benin036932301(~benin@183.82.205.89) (Read error: Connection reset by peer)
2021-09-16 17:10:08 +0000fendor_(~fendor@83-131-155-114.adsl.net.t-com.hr)
2021-09-16 17:10:52 +0000fendor(~fendor@83-131-155-114.adsl.net.t-com.hr) (Read error: Connection reset by peer)
2021-09-16 17:11:41 +0000 <carbolymer> how can I make this work: https://bpa.st/U5FA ?
2021-09-16 17:12:09 +0000zebrag(~chris@user/zebrag)
2021-09-16 17:12:10 +0000azimut_(~azimut@gateway/tor-sasl/azimut)
2021-09-16 17:12:19 +0000wroathe(~wroathe@user/wroathe) (Ping timeout: 265 seconds)
2021-09-16 17:12:40 +0000merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 260 seconds)
2021-09-16 17:12:57 +0000azimut(~azimut@gateway/tor-sasl/azimut) (Ping timeout: 276 seconds)
2021-09-16 17:13:05 +0000Teacup(~teacup@user/teacup)
2021-09-16 17:14:10 +0000cuz(~user@38.140.58.234) (Ping timeout: 240 seconds)
2021-09-16 17:15:25 +0000tzh(~tzh@c-24-21-73-154.hsd1.wa.comcast.net)
2021-09-16 17:16:50 +0000 <carbolymer> why ghc tries to decude (Exception e10) when there's a constraint on exception from E.try already
2021-09-16 17:18:05 +0000 <sm> plot twist! "Happily, I am involved with a new build system, the next generation of Buck." --https://neilmitchell.blogspot.com/2021/09/huge-project-build-systems.html
2021-09-16 17:18:09 +0000wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
2021-09-16 17:18:10 +0000wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Changing host)
2021-09-16 17:18:10 +0000wroathe(~wroathe@user/wroathe)
2021-09-16 17:18:33 +0000 <geekosaur> carbolymer, that usually means it can't unify e10 with what you expect it to
2021-09-16 17:19:00 +0000 <carbolymer> yeah, but why, and can I work around that?
2021-09-16 17:19:14 +0000 <geekosaur> but I'm not familiar with protolude or can-i-haz so I can't help much
2021-09-16 17:22:28 +0000fendor_(~fendor@83-131-155-114.adsl.net.t-com.hr) (Ping timeout: 265 seconds)
2021-09-16 17:23:26 +0000wroathe(~wroathe@user/wroathe) (Ping timeout: 265 seconds)
2021-09-16 17:23:57 +0000 <sm> incidentally, https://github.com/bazelbuild/starlark looks kind of useful, I wonder if there's any start at a haskell implementation
2021-09-16 17:25:24 +0000chris(~chris@81.96.113.213)
2021-09-16 17:25:27 +0000chrisGuest2044
2021-09-16 17:27:15 +0000ec_(~ec@gateway/tor-sasl/ec) (Ping timeout: 276 seconds)
2021-09-16 17:27:22 +0000Guest2044(~chris@81.96.113.213) (Remote host closed the connection)
2021-09-16 17:28:06 +0000justsomeguy(~justsomeg@user/justsomeguy) (Quit: WeeChat 3.2)
2021-09-16 17:33:11 +0000Erutuon(~Erutuon@user/erutuon)
2021-09-16 17:34:18 +0000ec_(~ec@gateway/tor-sasl/ec)
2021-09-16 17:38:28 +0000favonia(~favonia@user/favonia) (Ping timeout: 252 seconds)
2021-09-16 17:38:40 +0000nschoe(~quassel@2a01:e0a:8e:a190:e304:f7fc:fa6b:13a4)
2021-09-16 17:38:45 +0000nschoe(~quassel@2a01:e0a:8e:a190:e304:f7fc:fa6b:13a4) (Client Quit)
2021-09-16 17:39:01 +0000 <sclv> Drew[m]: why are you in that situation to begin with?
2021-09-16 17:39:56 +0000 <sclv> ah i see
2021-09-16 17:40:18 +0000 <sclv> so, if the test deps are in test stanzas, and you explicitly disable testing, it won't solve for the test deps
2021-09-16 17:42:08 +0000 <sclv> otherwise, just change the project file to not include the stuff you don't want to build
2021-09-16 17:42:51 +0000chris(~chris@81.96.113.213)
2021-09-16 17:42:54 +0000chrisGuest2003
2021-09-16 17:44:27 +0000waleee(~waleee@2001:9b0:216:8200:d457:9189:7843:1dbd)
2021-09-16 17:46:15 +0000jokleinn(~jokleinn@user/jokleinn) (Quit: WeeChat 3.2)
2021-09-16 17:47:19 +0000Guest2003(~chris@81.96.113.213) (Ping timeout: 252 seconds)
2021-09-16 17:48:02 +0000cuz(~user@38.140.58.234)
2021-09-16 17:50:17 +0000Cajun(~Cajun@user/cajun)
2021-09-16 17:51:46 +0000timCF(~timCF@m91-129-108-244.cust.tele2.ee) (Quit: leaving)
2021-09-16 17:52:55 +0000cuz(~user@38.140.58.234) (Ping timeout: 265 seconds)
2021-09-16 17:55:17 +0000dschrempf(~dominik@070-207.dynamic.dsl.fonira.net)
2021-09-16 17:55:47 +0000tromp(~textual@dhcp-077-249-230-040.chello.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2021-09-16 17:55:49 +0000 <dminuoso> @tell timCF You can work on Value directly, it's just an ADT.
2021-09-16 17:55:49 +0000 <lambdabot> Consider it noted.
2021-09-16 17:57:05 +0000cuz(~user@38.140.58.234)
2021-09-16 17:59:06 +0000ec_(~ec@gateway/tor-sasl/ec) (Ping timeout: 276 seconds)
2021-09-16 18:00:56 +0000favonia(~favonia@user/favonia)
2021-09-16 18:01:09 +0000timCF(~timCF@m91-129-108-244.cust.tele2.ee)
2021-09-16 18:03:45 +0000 <timCF> Is there some class similar to `Num`, but safe to use with `Natural` numbers? For example subtract method should be something like `(-) :: a -> a -> Either Error a`?
2021-09-16 18:04:06 +0000 <geekosaur> not currently
2021-09-16 18:05:38 +0000 <timCF> probably I'll do my own locally in project then :)
2021-09-16 18:05:43 +0000lep(~lep@94.31.80.176) ()
2021-09-16 18:05:52 +0000ec_(~ec@gateway/tor-sasl/ec)
2021-09-16 18:06:32 +0000ubert(~Thunderbi@178.115.48.20.wireless.dyn.drei.com) (Remote host closed the connection)
2021-09-16 18:06:51 +0000ubert(~Thunderbi@178.115.48.20.wireless.dyn.drei.com)
2021-09-16 18:07:06 +0000 <dminuoso> timCF: Regarding the earlier Value question, you could then write a simple recursive function.
2021-09-16 18:10:25 +0000alx741(~alx741@181.196.68.49) (Ping timeout: 252 seconds)
2021-09-16 18:10:41 +0000 <timCF> Yeah, already did it) Just thought it could be done "smarter" with some sort of generic lens/prism magic https://github.com/tkachuk-labs/bitfinex-client/blob/3b96cff21cd06a8f1c44e7657a17e6a9ce67d21f/src/…
2021-09-16 18:11:08 +0000 <dminuoso> Nothing as concise
2021-09-16 18:11:59 +0000 <dminuoso> You could perhaps do something with Plated?
2021-09-16 18:12:18 +0000 <dminuoso> If lens-aeson has an instance for that
2021-09-16 18:12:37 +0000 <dminuoso> Oh it does!
2021-09-16 18:13:10 +0000 <dminuoso> Though I think it would rather require writing a custom Plated instance
2021-09-16 18:13:16 +0000 <kuribas> timCF: golfing, are we?
2021-09-16 18:14:36 +0000 <timCF> kuribas: golfing?
2021-09-16 18:14:59 +0000 <kuribas> https://en.wikipedia.org/wiki/Code_golf
2021-09-16 18:15:20 +0000 <carbolymer> geekosaur: I've removed can-i-haz and Protolude for readability, maybe you have any ideas now: https://stackoverflow.com/questions/69213328/lift-io-exception-into-monaderror-with-automatic-mapp…
2021-09-16 18:15:54 +0000Pickchea(~private@user/pickchea)
2021-09-16 18:16:14 +0000ubert(~Thunderbi@178.115.48.20.wireless.dyn.drei.com) (Ping timeout: 260 seconds)
2021-09-16 18:16:35 +0000 <dminuoso> timCF: If at all, it seems `rewrite` or `transformOf` together with `plate` would be the way to go.
2021-09-16 18:17:38 +0000 <timCF> kuribas: well, seems like I'm not that good in Haskell yet to do golfing)
2021-09-16 18:17:46 +0000 <dminuoso> timCF: Ah I think I got it.
2021-09-16 18:18:12 +0000seventhCrow(crow@gateway/vpn/protonvpn/seventhcrow)
2021-09-16 18:18:23 +0000 <geekosaur> carbolymer, I think multiparameter type classes don't work that way, you really need either functional dependencies or type families to make them work the way you expect
2021-09-16 18:18:43 +0000 <carbolymer> hmm
2021-09-16 18:19:10 +0000lavaman(~lavaman@98.38.249.169)
2021-09-16 18:19:44 +0000 <geekosaur> and just because you have only one instance doesn't mean there can't be others (typeclasses operate under an open world assumption because separate compilation means someone could theoretically add an additional instance later)
2021-09-16 18:19:49 +0000 <carbolymer> that would enforce only one mapping allowed a -> b in Injection instance
2021-09-16 18:19:56 +0000 <carbolymer> I guess I can live with that
2021-09-16 18:20:15 +0000 <geekosaur> and only the linker would know, not the conmpiler
2021-09-16 18:20:17 +0000 <carbolymer> geekosaur: exactly, I think I start seeing it now
2021-09-16 18:20:37 +0000 <dminuoso> timCF: If you want this without the explicit recursion, you can use plain `rewrite`
2021-09-16 18:21:02 +0000 <awpr> carbolymer: the other potential answer is that the error is really more of a warning, and you can turn on `AllowAmbiguousTypes` and `TypeApplications` to use it
2021-09-16 18:21:25 +0000 <timCF> dminuoso: I'll take a look to what actually `plate` is first I guess) I feel like I'm missing a lot of profit ignoring lens-related stuff "for simplicity" in spite of programming in Haskell for already 2 years
2021-09-16 18:21:44 +0000 <carbolymer> awpr: is AllowAmbiguousTypes a safe extension to just turn it on and go with it hoping that all the magic will happen?
2021-09-16 18:21:58 +0000 <kuribas> timCF: simple is better
2021-09-16 18:22:07 +0000 <awpr> the error is just saying it can't figure out what exception type it should `try` on based on the argument and return types, and call sites will need help in the form of `TypeApplications`
2021-09-16 18:22:27 +0000 <dminuoso> timCF: So maybe something like `rewrite (\case of Object o -> HM.filter (/= Null) o; Array v -> V.filter (/= Null) v; r -> r ) tree)`
2021-09-16 18:22:46 +0000 <awpr> I generally don't hesitate to turn on `AllowAmbiguousTypes`; it basically just means "hey, you can't use this without `TypeApplications`, are you sure that's what you wanted?"
2021-09-16 18:22:56 +0000kuribas(~user@ptr-25vy0i96fc65i21clnv.18120a2.ip6.access.telenet.be) (Remote host closed the connection)
2021-09-16 18:23:04 +0000 <carbolymer> awpr: sounds useful
2021-09-16 18:23:08 +0000 <dminuoso> timCF: Plated is just a typeclass in which you can have a `Traversal' a a` that knows how to extract self-similar children.
2021-09-16 18:23:14 +0000rond_(~rond_@2a02:a31a:a23c:f480:2fd7:e087:5546:a438)
2021-09-16 18:23:19 +0000 <dminuoso> Together with a bunch of combinators that let you sort of recursion-style work with that
2021-09-16 18:23:37 +0000 <dminuoso> Like `rewrite`
2021-09-16 18:24:26 +0000 <timCF> dminuoso: looks cool, thanks!
2021-09-16 18:24:39 +0000alx741(~alx741@181.196.68.9)
2021-09-16 18:25:33 +0000 <dminuoso> So for instance, to turn a tree of integers into a list, you can just write `universe tree`
2021-09-16 18:26:39 +0000 <dminuoso> But this is only an almost meaningless example. Plated is very powerful to work with such tree-like data.
2021-09-16 18:27:29 +0000chris(~chris@81.96.113.213)
2021-09-16 18:27:33 +0000chrisGuest3304
2021-09-16 18:28:39 +0000cuz(~user@38.140.58.234) (Remote host closed the connection)
2021-09-16 18:28:48 +0000cuz(~user@38.140.58.234)
2021-09-16 18:30:18 +0000 <Cajun> `universe tree` sounds deeply metaphorical :P
2021-09-16 18:32:04 +0000Guest3304(~chris@81.96.113.213) (Ping timeout: 265 seconds)
2021-09-16 18:34:32 +0000zer0bitz(~zer0bitz@dsl-hkibng31-54fafc-123.dhcp.inet.fi)
2021-09-16 18:34:44 +0000timCF(~timCF@m91-129-108-244.cust.tele2.ee) (Quit: leaving)
2021-09-16 18:34:54 +0000dhouthoo(~dhouthoo@178-117-36-167.access.telenet.be) (Quit: WeeChat 3.2)
2021-09-16 18:35:03 +0000timCF(~timCF@m91-129-108-244.cust.tele2.ee)
2021-09-16 18:35:17 +0000timCF(~timCF@m91-129-108-244.cust.tele2.ee) (Client Quit)
2021-09-16 18:36:10 +0000wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
2021-09-16 18:36:10 +0000wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Changing host)
2021-09-16 18:36:10 +0000wroathe(~wroathe@user/wroathe)
2021-09-16 18:40:48 +0000wroathe(~wroathe@user/wroathe) (Ping timeout: 268 seconds)
2021-09-16 18:43:06 +0000vaucouleur(~vaucouleu@78.194.70.105) (Read error: Connection reset by peer)
2021-09-16 18:43:14 +0000abhixec(~abhixec@c-67-169-139-16.hsd1.ca.comcast.net)
2021-09-16 18:43:57 +0000ec_(~ec@gateway/tor-sasl/ec) (Ping timeout: 276 seconds)
2021-09-16 18:45:36 +0000rond_(~rond_@2a02:a31a:a23c:f480:2fd7:e087:5546:a438) (Quit: Client closed)
2021-09-16 18:48:56 +0000eggplantade(~Eggplanta@2600:1700:bef1:5e10:854d:ae90:d2a1:51ab) (Remote host closed the connection)
2021-09-16 18:52:42 +0000eggplantade(~Eggplanta@2600:1700:bef1:5e10:854d:ae90:d2a1:51ab)
2021-09-16 18:53:44 +0000Franciman(~Franciman@openglass.it) (Remote host closed the connection)
2021-09-16 18:54:09 +0000ec_(~ec@gateway/tor-sasl/ec)
2021-09-16 18:56:22 +0000nedh^(~nedh@68.101.54.227) (Ping timeout: 260 seconds)
2021-09-16 18:59:11 +0000nvmd(~nvmd@user/nvmd) (Read error: Connection reset by peer)
2021-09-16 19:01:04 +0000cheater(~Username@user/cheater) (Ping timeout: 265 seconds)
2021-09-16 19:01:05 +0000cheater1__(~Username@user/cheater)
2021-09-16 19:01:09 +0000cheater1__cheater
2021-09-16 19:01:14 +0000ephemient(uid407513@id-407513.lymington.irccloud.com) (Quit: Connection closed for inactivity)
2021-09-16 19:03:25 +0000nvmd(~nvmd@user/nvmd)
2021-09-16 19:03:32 +0000hololeap(~hololeap@user/hololeap) (Remote host closed the connection)
2021-09-16 19:04:57 +0000hololeap(~hololeap@user/hololeap)
2021-09-16 19:06:40 +0000abhixec(~abhixec@c-67-169-139-16.hsd1.ca.comcast.net) (Remote host closed the connection)
2021-09-16 19:06:52 +0000favonia(~favonia@user/favonia) (Ping timeout: 265 seconds)
2021-09-16 19:09:44 +0000merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2021-09-16 19:09:50 +0000dschrempf(~dominik@070-207.dynamic.dsl.fonira.net) (Quit: WeeChat 3.2.1)
2021-09-16 19:12:49 +0000eggplantade(~Eggplanta@2600:1700:bef1:5e10:854d:ae90:d2a1:51ab) (Remote host closed the connection)
2021-09-16 19:13:09 +0000jtomas(~jtomas@95.red-88-11-64.dynamicip.rima-tde.net) (Ping timeout: 265 seconds)
2021-09-16 19:13:51 +0000ec_(~ec@gateway/tor-sasl/ec) (Ping timeout: 276 seconds)
2021-09-16 19:15:38 +0000 <awpr> informal opinion-gathering: would you be put off from using a pretty-printing library if its instance for String printed it as a list of Chars? I'm torn on whether to implement the typeclass trickery to special-case Strings among other lists -- it complicates the class a bit, and I'm tempted to leave it out to subtly discourage using String
2021-09-16 19:17:14 +0000Lycurgus(~juan@98.4.112.204)
2021-09-16 19:18:57 +0000lavaman(~lavaman@98.38.249.169) (Ping timeout: 265 seconds)
2021-09-16 19:20:45 +0000ec_(~ec@gateway/tor-sasl/ec)
2021-09-16 19:21:01 +0000jtomas(~jtomas@95.red-88-11-64.dynamicip.rima-tde.net)
2021-09-16 19:25:40 +0000pavonia(~user@user/siracusa)
2021-09-16 19:27:20 +0000 <dminuoso> I would be, yes.
2021-09-16 19:27:48 +0000eggplantade(~Eggplanta@2600:1700:bef1:5e10:854d:ae90:d2a1:51ab)
2021-09-16 19:27:48 +0000 <dminuoso> It depends a bit on the ergonmoics of the library
2021-09-16 19:29:49 +0000 <dminuoso> Actually let me go back and rephrase.
2021-09-16 19:29:56 +0000gehmehgeh(~user@user/gehmehgeh)
2021-09-16 19:30:10 +0000 <dminuoso> Personally I dont use typeclass instances much with `prettyprinter`, its mostly custom `ppr*` functions because most things dont have a canonical representation.
2021-09-16 19:30:28 +0000 <dminuoso> In that sense, having a dedicated pprText and pprString function would probably be fine.
2021-09-16 19:30:55 +0000wrengr_awaywrengr
2021-09-16 19:31:26 +0000 <geekosaur> in the only program I have that does prettyprinting I use custom functions as well
2021-09-16 19:33:12 +0000 <geekosaur> come to think of it, two programs and the other one uses custom functions as well (DebugEvent in xmonad-contrib)
2021-09-16 19:33:53 +0000 <awpr> so the main thing it provides is "debug-style" derived instances printing types as mostly-valid-Haskell syntax, along with structured diffing for tests. if you're carefully constructing user-facing output documents, you probably wouldn't use this, unless the "users" are people inspecting test failures or are Haskell developers
2021-09-16 19:34:30 +0000 <awpr> the present issue is that it'd print String fields in records as lists of Char, for example (but Text as really nicely formatted string literals)
2021-09-16 19:34:59 +0000favonia(~favonia@user/favonia)
2021-09-16 19:35:04 +0000 <geekosaur> I'd actually prefer to support both forms
2021-09-16 19:35:06 +0000zer0bitz(~zer0bitz@dsl-hkibng31-54fafc-123.dhcp.inet.fi) (Ping timeout: 260 seconds)
2021-09-16 19:35:36 +0000 <geekosaur> although admittedly the main reason is things like (Mega)Parsec that use lists when they ought to be using Sets
2021-09-16 19:36:10 +0000tdammers(~tdammers@77.109.72.177.res.static.edpnet.net) (Ping timeout: 252 seconds)
2021-09-16 19:37:06 +0000 <awpr> it'd be even more effort to support both, I'd have to grow a configuration mechanism just for that individual choice
2021-09-16 19:37:37 +0000 <geekosaur> that's one advantage of ppr* functions though, I can just use the one that fits the purpose
2021-09-16 19:38:13 +0000 <awpr> yeah, you should use explicit functions if you're hand-crafting documents for well-maintained user-facing output
2021-09-16 19:38:37 +0000 <geekosaur> come to think of it, String's already going through this with Show because of people who want it to display Unicode "properly"
2021-09-16 19:41:10 +0000kimjetwav(~user@2607:fea8:235f:9730:7652:9a19:d3a:6562) (Ping timeout: 260 seconds)
2021-09-16 19:42:27 +0000Franciman(~Franciman@mx1.fracta.dev)
2021-09-16 19:42:40 +0000merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 240 seconds)
2021-09-16 19:43:01 +0000tdidrfyls^(~tdidrfyls@68.101.54.227)
2021-09-16 19:43:45 +0000ec_(~ec@gateway/tor-sasl/ec) (Ping timeout: 276 seconds)
2021-09-16 19:43:58 +0000mikoto-chan(~mikoto-ch@ip-83-134-2-136.dsl.scarlet.be) (Ping timeout: 260 seconds)
2021-09-16 19:47:58 +0000eggplantade(~Eggplanta@2600:1700:bef1:5e10:854d:ae90:d2a1:51ab) (Remote host closed the connection)
2021-09-16 19:48:41 +0000tdammers(~tdammers@77.109.72.177.res.static.edpnet.net)
2021-09-16 19:50:31 +0000ec_(~ec@gateway/tor-sasl/ec)
2021-09-16 19:53:10 +0000tromp(~textual@dhcp-077-249-230-040.chello.nl)
2021-09-16 19:54:26 +0000tromp(~textual@dhcp-077-249-230-040.chello.nl) (Client Quit)
2021-09-16 19:55:01 +0000System123(~System123@ec2-52-61-197-79.us-gov-west-1.compute.amazonaws.com)
2021-09-16 19:57:40 +0000l4mee(~l4mee@93.49.6.163)
2021-09-16 19:57:56 +0000mikoto-chan(~mikoto-ch@83.137.2.242)
2021-09-16 19:58:53 +0000l4mee(~l4mee@93.49.6.163) (Quit: l4mee)
2021-09-16 19:59:54 +0000 <awpr> hmm, yeah, at the moment I just have it doing decimal escapes the same way Show currently does
2021-09-16 20:04:46 +0000jstolarek(~jstolarek@ers4.neoplus.adsl.tpnet.pl) (Ping timeout: 252 seconds)
2021-09-16 20:06:08 +0000Lord_of_Life(~Lord@user/lord-of-life/x-2819915) (Quit: Laa shay'a waqi'un moutlaq bale kouloun moumkine)
2021-09-16 20:06:52 +0000wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
2021-09-16 20:06:53 +0000wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Changing host)
2021-09-16 20:06:53 +0000wroathe(~wroathe@user/wroathe)
2021-09-16 20:06:58 +0000Gurkenglas(~Gurkengla@dslb-002-207-014-195.002.207.pools.vodafone-ip.de) (Ping timeout: 252 seconds)
2021-09-16 20:07:08 +0000Lord_of_Life(~Lord@user/lord-of-life/x-2819915)
2021-09-16 20:08:37 +0000 <awpr> it's a bit tricky, since depending on the system locale, the runtime might just blow up if you try to output non-ASCII characters, so if it unconditionally includes those, it'll not work in certain locales, but if it's conditional, you have to do IO to figure out whether it's supported and then plumb that around everywhere
2021-09-16 20:09:10 +0000jtomas(~jtomas@95.red-88-11-64.dynamicip.rima-tde.net) (Ping timeout: 252 seconds)
2021-09-16 20:09:58 +0000 <Cajun> well you could do what one of those networking packages does and use `unsafePerformIO` to get an `IORef` instead of an `IO (IORef)` which will be used as a default config every time its requested
2021-09-16 20:10:35 +0000eggplantade(~Eggplanta@2600:1700:bef1:5e10:854d:ae90:d2a1:51ab)
2021-09-16 20:11:58 +0000 <awpr> yeah, I guess so, but global unsafePerformIOs make me feel a bit dirty. and it's still just a best guess, since what's actually relevant IIUC is the encoding of the particular handle the text will be output to -- which is _probably_ the system locale, but maybe not always
2021-09-16 20:12:59 +0000tromp(~textual@dhcp-077-249-230-040.chello.nl)
2021-09-16 20:13:00 +0000sneedsfeed(~sneedsfee@rrcs-173-95-122-169.midsouth.biz.rr.com)
2021-09-16 20:14:23 +0000 <sneedsfeed> In imperative programming I rely a lot on adding random little printouts into loops to see whats going on in there. Is there anything even sort of analogous to that when writing recursive functions?
2021-09-16 20:14:44 +0000 <geekosaur> I don't think the runtime supports per-handle locales (yet?)
2021-09-16 20:15:05 +0000 <awpr> sneedsfeed: yes, Debug.Trace.trace; it can be a bit subtle understanding when they actually happen if you're not used to lazy evaluation, though
2021-09-16 20:15:06 +0000 <geekosaur> sneedsfeed, there is Debug.Trace
2021-09-16 20:15:37 +0000Lord_of_Life(~Lord@user/lord-of-life/x-2819915) (Quit: Laa shay'a waqi'un moutlaq bale kouloun moumkine)
2021-09-16 20:16:02 +0000 <Cajun> you may not always want to fallback to using Debug.Trace unless you really have no idea whats happening, most of the time you can reason about what something does. there are times when its really useful though, i just havent used it much myself
2021-09-16 20:16:05 +0000 <awpr> geekosaur: hmm, I'll have to read the source
2021-09-16 20:16:37 +0000Lord_of_Life(~Lord@user/lord-of-life/x-2819915)
2021-09-16 20:16:53 +0000 <geekosaur> I didn't see anything in System.IO; there might be some lower level stuff in GHC.IO.Handle though
2021-09-16 20:17:06 +0000zmt00(~zmt00@user/zmt00) (Ping timeout: 260 seconds)
2021-09-16 20:17:15 +0000 <awpr> there are multiple fields in Handle that look like they're meant to support handle-granularity text encodings
2021-09-16 20:17:26 +0000 <Cajun> awpr: well you can provide both methods, passing around some manager to each function (this is tarting to sound like Reader though). heres the code i was thinking of: https://paste.tomsmeding.com/o4vzbVzg
2021-09-16 20:17:28 +0000 <sneedsfeed> Cajun thats probably true.
2021-09-16 20:18:14 +0000 <awpr> yes, that's possible, it's just that it doesn't actually fix the issue for real
2021-09-16 20:18:41 +0000 <awpr> so far I've just dodged the issue by sticking to decimal escapes
2021-09-16 20:19:48 +0000vysn(~vysn@user/vysn)
2021-09-16 20:19:59 +0000_ht(~quassel@82-169-194-8.biz.kpn.net) (Remote host closed the connection)
2021-09-16 20:20:07 +0000 <awpr> seems like the root of the problem is that the way Haskell libraries are currently set up has transparent locale-sensitivity only up to the text encoding level, and not above, with no good story for locale-sensitive /content/ that I'm aware of
2021-09-16 20:20:40 +0000 <awpr> which basically just means outputting non-ASCII characters is banned unless you're willing to crash on basic locales
2021-09-16 20:20:53 +0000chexum(~quassel@gateway/tor-sasl/chexum) (Remote host closed the connection)
2021-09-16 20:20:59 +0000 <awpr> (or explicitly UTF-8 them and output bytes rather than text)
2021-09-16 20:21:02 +0000smuses unsafePerformIO to get info for debug tracing (color support, --debug flag, etc), it works well
2021-09-16 20:21:06 +0000chexum(~quassel@gateway/tor-sasl/chexum)
2021-09-16 20:24:24 +0000eggplantade(~Eggplanta@2600:1700:bef1:5e10:854d:ae90:d2a1:51ab) (Remote host closed the connection)
2021-09-16 20:26:28 +0000tromp(~textual@dhcp-077-249-230-040.chello.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2021-09-16 20:27:18 +0000ec_(~ec@gateway/tor-sasl/ec) (Ping timeout: 276 seconds)
2021-09-16 20:27:42 +0000kimjetwav(~user@2607:fea8:235f:9730:162d:fa69:3f15:a6a5)
2021-09-16 20:30:43 +0000 <awpr> I guess nothing's stopping me from adding a config record, and having the debug utilities infer the config by default
2021-09-16 20:31:13 +0000ec_(~ec@gateway/tor-sasl/ec)
2021-09-16 20:31:20 +0000 <awpr> just concerned it'll open the floodgates to an enormous config record with a bunch of random fields for every type, if I'm not careful of how it's designed
2021-09-16 20:35:14 +0000 <Cale> awpr: Just be careful about which things need what config, and make types accordingly. Then you might end up with a config record consisting of several other config records, and it's actually enormous at the top level, but gets split up into smaller types quickly.
2021-09-16 20:35:39 +0000 <awpr> but this is in the context of a typeclass method
2021-09-16 20:35:41 +0000 <Cale> (but I only read your last few messages, so I might be missing context)
2021-09-16 20:35:47 +0000 <geekosaur> there's also a Map indexed by Typeable
2021-09-16 20:36:05 +0000 <sneedsfeed> I just found this. You guys should consider pointing every newby you encounter at this. https://colah.github.io/posts/2015-02-DataList-Illustrated/
2021-09-16 20:36:07 +0000 <geekosaur> more precisely TypeRep
2021-09-16 20:36:32 +0000 <awpr> geekosaur: yeah, I tried that approach for overriding individual instances, but decided it was too much and was just complicating things more than I wanted
2021-09-16 20:38:31 +0000 <awpr> it turns out the locale-sensitive escaping logic would live entirely in renderers and not in the classes, though, so there are finitely many constructs to configure at the point where I'd actually need the configuration, and I can probably get away with zero configuration for the instances
2021-09-16 20:43:46 +0000kuribas(~user@ptr-25vy0i9fqiblx2l1e59.18120a2.ip6.access.telenet.be)
2021-09-16 20:44:26 +0000 <kuribas> Are there ways to have multifunctors? Like three or more functors in one type?
2021-09-16 20:44:51 +0000 <awpr> like Bifunctor for >2?
2021-09-16 20:45:13 +0000 <kuribas> yeah :)
2021-09-16 20:45:20 +0000 <kuribas> NFunctor?
2021-09-16 20:45:52 +0000 <awpr> not aware of one, but you can have standalone functions to map over earlier type parameters
2021-09-16 20:46:03 +0000 <kuribas> perhaps with newtypes to swap type variables?
2021-09-16 20:46:19 +0000 <awpr> yeah, that's one approach I played with a while back. it's... okay
2021-09-16 20:46:47 +0000 <awpr> gets a bit tedious, but IIRC it largely works
2021-09-16 20:48:40 +0000favonia(~favonia@user/favonia) (Ping timeout: 268 seconds)
2021-09-16 20:49:41 +0000 <Cale> kuribas: There is a way, by generalising Functor to be between an arbitrary pair of categories
2021-09-16 20:50:10 +0000 <awpr> this is an aspect of something I wish we had a better answer for in Haskell -- there are infinitely many variations on functors that we occasionally want, it's a huge pain to write special case libraries for each one, but writing a sufficiently general thing that covers all functors makes use sites so complicated that it just results in getting fed up with all the kind instantiation and doing something else
2021-09-16 20:50:47 +0000 <ProofTechnique> I'm _certain_ there's a Trifunctor on Hackage somewhere
2021-09-16 20:51:01 +0000 <awpr> how about Triskaidekafunctor
2021-09-16 20:51:10 +0000 <Cale> I don't think it's all that big a deal, honestly
2021-09-16 20:51:24 +0000 <Cale> If you have that many type parameters, you'd probably prefer to name your operations more clearly
2021-09-16 20:51:43 +0000 <ProofTechnique> ^this
2021-09-16 20:51:57 +0000 <Cale> fmap3of7 is not very cool
2021-09-16 20:52:28 +0000 <kuribas> hmm, it's worse, I am thinking about a higher kinded bifunctor now...
2021-09-16 20:52:44 +0000 <Cale> But yeah, you can just do enough runNat's ;)
2021-09-16 20:52:45 +0000 <ProofTechnique> Being a Functor is boring. Practically everything is a Functor. Trifunctors are thrice as boring, and who needs that?
2021-09-16 20:53:00 +0000 <awpr> kuribas: like https://hackage.haskell.org/package/ten-0.1.0.1/docs/Data-Ten-Functor.html#t:Functor10 but Bifunctor?
2021-09-16 20:53:04 +0000 <kuribas> Cale: how so?
2021-09-16 20:53:36 +0000 <kuribas> "If you have that many type parameters, you'd probably prefer to name your operations more clearly"
2021-09-16 20:54:18 +0000 <Cale> https://github.com/ekmett/hask/blob/master/src/Hask/Category.hs#L329
2021-09-16 20:54:32 +0000 <Cale> kuribas: Because the parameters probably have meaning to you
2021-09-16 20:54:46 +0000 <kuribas> right, they have
2021-09-16 20:55:29 +0000tromp(~textual@dhcp-077-249-230-040.chello.nl)
2021-09-16 20:55:40 +0000 <ProofTechnique> "I wrote Dodecafunctor, but I use id in nearly every position"
2021-09-16 20:56:00 +0000 <Cale> ProofTechnique: seventhOfTwelve
2021-09-16 20:56:06 +0000 <kuribas> maybe labeled functors?
2021-09-16 20:56:41 +0000 <Cale> (like first and second for Bifunctor)
2021-09-16 20:57:23 +0000 <kuribas> For example, I model some sort of subtyping with functors. Like "Device fields", where Device contains command fields, fields are specific to the type of Device.
2021-09-16 20:58:21 +0000 <kuribas> Or just (Device ()) if I don't care about the special fields.
2021-09-16 20:58:29 +0000 <ProofTechnique> Questions like these are why we have lenses now
2021-09-16 20:58:58 +0000 <kuribas> ProofTechnique: that sounds orthogonal.
2021-09-16 20:59:32 +0000 <kuribas> Well, I guess I don't need the functor instance really...
2021-09-16 20:59:39 +0000 <kuribas> I can use the LabelOptic instead.
2021-09-16 20:59:41 +0000 <dsal> Lenses give you named profunctors on arbitrary things.
2021-09-16 20:59:44 +0000 <awpr> a polymorphic lens or other optic can target whichever type parameter it wants, have a nice name, and give you all the available functionality of the suite of functor-ish instances
2021-09-16 20:59:54 +0000 <kuribas> yeah true.
2021-09-16 21:00:07 +0000jstolarek(~jstolarek@ers4.neoplus.adsl.tpnet.pl)
2021-09-16 21:00:10 +0000 <kuribas> Are there higher rank lenses?
2021-09-16 21:00:16 +0000 <monochrom> I don't fear seventhOfTwelve. What I fear is there are almost 2^12 siblings of it.
2021-09-16 21:00:54 +0000 <awpr> kuribas: like `(forall x. m x -> f (n x)) -> s -> f t`?
2021-09-16 21:01:15 +0000 <kuribas> awpr: yeah
2021-09-16 21:01:22 +0000 <awpr> ooh I just realized GHC 9.2 makes those not suck
2021-09-16 21:01:33 +0000 <awpr> I've been tempted to add them to `ten`, but haven't yet
2021-09-16 21:02:21 +0000 <awpr> I may even have a commented out `Lens10` type alias with a comment like "uh, is this useful?"
2021-09-16 21:03:02 +0000zmt00(~zmt00@user/zmt00)
2021-09-16 21:03:28 +0000Lord_of_Life_(~Lord@user/lord-of-life/x-2819915)
2021-09-16 21:03:32 +0000 <awpr> (background: composing those without quick look impredicativity doesn't work, it'd need a newtype to guard the forall. with quick look, maybe it works)
2021-09-16 21:04:10 +0000Lord_of_Life(~Lord@user/lord-of-life/x-2819915) (Ping timeout: 252 seconds)
2021-09-16 21:04:27 +0000jokleinn(~jokleinn@user/jokleinn)
2021-09-16 21:05:04 +0000 <kuribas> I was just thinking how to model clojure style "data API", where you put all information in data. It seems to map to HKD data. For example you fill a HKD with a parser description. Then use the HKD to "run" each parser to Identity.
2021-09-16 21:05:50 +0000 <awpr> not familiar with the clojure side of that, but it sure sounds like `traverse10` to me
2021-09-16 21:06:14 +0000Lord_of_Life_Lord_of_Life
2021-09-16 21:06:54 +0000 <kuribas> like: https://hackage.haskell.org/package/hkd-0.1/docs/Data-HKD.html
2021-09-16 21:07:19 +0000 <awpr> yeah, same idea. I like mine better :)
2021-09-16 21:08:08 +0000 <awpr> in particular I have support for getting access to the constraints that are common to all fields
2021-09-16 21:08:21 +0000 <dsal> awpr: I'm not smart enough to understand ten. Do you have an explanation for dummies?
2021-09-16 21:08:40 +0000takuan(~takuan@178-116-218-225.access.telenet.be) (Remote host closed the connection)
2021-09-16 21:09:01 +0000 <awpr> yeah the docs are still not super friendly to newcomers to the library, I'd like to improve that
2021-09-16 21:09:05 +0000 <Cajun> how is HKD different from First Class Families?
2021-09-16 21:09:19 +0000 <Cajun> they seem similar in concept, maybe i just dont understand the idea behind HKD
2021-09-16 21:09:28 +0000 <dsal> awpr: I guess it's just a type functor. I don't spend too much time there.
2021-09-16 21:09:33 +0000 <dsal> Whence the name?
2021-09-16 21:10:28 +0000 <awpr> dsal: yeah, pretty much. in practice I've seen it come up when wanting a lot of variants of the same record type and ways to manipulate them generically, like "MyRecord Parser -> Parser (MyRecord Identity)"
2021-09-16 21:10:46 +0000 <ProofTechnique> I was gonna say "how about even one example?" 😄 I get HKD well enough to use it in anger (well, barbies, anyway), but I don't even know where to start with ten
2021-09-16 21:10:52 +0000 <kuribas> awpr: how is it different from HKD?
2021-09-16 21:11:07 +0000 <awpr> kuribas: exactly the same core idea, but more functionality
2021-09-16 21:11:08 +0000 <kuribas> awpr: to me it looks like the same think with a different name.
2021-09-16 21:11:28 +0000burnsidesLlama(~burnsides@dhcp168-022.wadham.ox.ac.uk)
2021-09-16 21:12:11 +0000 <kuribas> hmm, ok
2021-09-16 21:13:47 +0000 <kuribas> it's always nice in theory, but the code seems to become hairy quickly.
2021-09-16 21:13:56 +0000 <kuribas> for example beam.
2021-09-16 21:14:32 +0000 <ProofTechnique> dsal: Evidently the name comes from its being a functor from the category of objects with one (1) type parameter to the category of objects with zero (0)
2021-09-16 21:14:34 +0000eggplantade(~Eggplanta@2600:1700:bef1:5e10:854d:ae90:d2a1:51ab)
2021-09-16 21:14:50 +0000 <dsal> ProofTechnique: Ah. Thanks.
2021-09-16 21:15:31 +0000 <dsal> Needs more abstraction. Next time, call it LilNasFunctorX
2021-09-16 21:15:50 +0000 <ProofTechnique> Lil Nat Z
2021-09-16 21:15:50 +0000 <awpr> lol I get the sense I should demote the current description to a category theory section and start over
2021-09-16 21:16:49 +0000burnsidesLlama(~burnsides@dhcp168-022.wadham.ox.ac.uk) (Ping timeout: 252 seconds)
2021-09-16 21:16:57 +0000 <ProofTechnique> I'll see if I can use it next time I write a CLI tool 🙂
2021-09-16 21:17:35 +0000 <ProofTechnique> Config construction is most of what I've used HKD for, thus far
2021-09-16 21:17:39 +0000jstolarek(~jstolarek@ers4.neoplus.adsl.tpnet.pl) (Ping timeout: 268 seconds)
2021-09-16 21:17:48 +0000newbie(~newbie@80-196-109-198-dynamic.dk.customer.tdc.net)
2021-09-16 21:17:51 +0000hyiltiz(~quassel@31.220.5.250) (Ping timeout: 265 seconds)
2021-09-16 21:17:57 +0000 <awpr> kuribas: yeah, it can get confusing. I did try to iron out a lot of the scarier issues, but there are still a lot of types and type parameters and quantifiers floating around. it's certainly not functionality for zero complexity cost, it's more on the heavyweight side
2021-09-16 21:18:14 +0000 <newbie> Hi, I have a question regarding '>>=' of Either. If I want to apply it to a tuple containing Either instead i.e (Either SomeData a, String), how can I lift '>>=' such that it operates on tuples?
2021-09-16 21:19:04 +0000 <Rembane> :t first (>>=)
2021-09-16 21:19:05 +0000 <lambdabot> Monad m => (m a, d) -> ((a -> m b) -> m b, d)
2021-09-16 21:19:22 +0000 <Cajun> :t first
2021-09-16 21:19:23 +0000 <lambdabot> Arrow a => a b c -> a (b, d) (c, d)
2021-09-16 21:19:30 +0000 <Rembane> That wasn't the clearest type signature, but it's one way to do it.
2021-09-16 21:19:32 +0000 <dsal> @hoogle first
2021-09-16 21:19:32 +0000 <Cajun> i see arrows im scared
2021-09-16 21:19:32 +0000 <lambdabot> Control.Arrow first :: Arrow a => a b c -> a (b, d) (c, d)
2021-09-16 21:19:32 +0000 <lambdabot> Data.Bifunctor first :: Bifunctor p => (a -> b) -> p a c -> p b c
2021-09-16 21:19:32 +0000 <lambdabot> Text.PrettyPrint.Annotated.HughesPJ first :: Doc a -> Doc a -> Doc a
2021-09-16 21:19:47 +0000 <dsal> The Bifunctor one is what your probably probably thinks of.
2021-09-16 21:19:48 +0000 <awpr> :t Data.Bifunctor.first -- a less scary one, slightly
2021-09-16 21:19:49 +0000 <lambdabot> Bifunctor p => (a -> b) -> p a c -> p b c
2021-09-16 21:19:56 +0000 <Cajun> oh its bifunctor, thats way less scary
2021-09-16 21:20:12 +0000 <dsal> newbie: You could use regular functor if you swapped the tuple around.
2021-09-16 21:20:41 +0000 <Rembane> :t swap
2021-09-16 21:20:42 +0000 <lambdabot> (a, b) -> (b, a)
2021-09-16 21:21:03 +0000 <dsal> I'd probably try to actually just use it in that direction instead of doing a `. swap`
2021-09-16 21:21:33 +0000 <newbie> That seems easier than i thought. Thanks guys, i'll try to implement it :)
2021-09-16 21:21:41 +0000 <ProofTechnique> More descriptive, for sure
2021-09-16 21:21:45 +0000cuz(~user@38.140.58.234) (Ping timeout: 268 seconds)
2021-09-16 21:22:35 +0000max22-(~maxime@2a01cb0883359800cbea6a523dcdbf78.ipv6.abo.wanadoo.fr) (Quit: Leaving)
2021-09-16 21:22:47 +0000shailangsa(~shailangs@host86-186-132-44.range86-186.btcentralplus.com) ()
2021-09-16 21:23:58 +0000mjs2600(~mjs2600@c-24-91-3-49.hsd1.vt.comcast.net) (Ping timeout: 250 seconds)
2021-09-16 21:27:06 +0000ec_(~ec@gateway/tor-sasl/ec) (Ping timeout: 276 seconds)
2021-09-16 21:28:22 +0000chris(~chris@81.96.113.213)
2021-09-16 21:28:26 +0000chrisGuest7922
2021-09-16 21:29:15 +0000 <ldlework> Is "Reflex" react for haskell?
2021-09-16 21:29:20 +0000 <ldlework> I can't quite tell
2021-09-16 21:29:52 +0000 <kuribas> rather react is pseudo FRP for javascript.
2021-09-16 21:30:11 +0000 <ldlework> so Reflex is a generic framework for doing FRP in haskell?
2021-09-16 21:30:25 +0000 <ldlework> Is it for web-development, or like, more general than that
2021-09-16 21:31:04 +0000 <kuribas> I am not that familiar with it, but I'd say it's mostly for the web, yes...
2021-09-16 21:31:32 +0000ec_(~ec@gateway/tor-sasl/ec)
2021-09-16 21:32:40 +0000Guest7922(~chris@81.96.113.213) (Ping timeout: 240 seconds)
2021-09-16 21:33:41 +0000tdidrfyls^(~tdidrfyls@68.101.54.227) (Ping timeout: 268 seconds)
2021-09-16 21:34:21 +0000 <sm> lots of reflex packages: https://hackage.haskell.org/packages/search?terms=reflex
2021-09-16 21:34:21 +0000 <Boarders> is there a nice way to do your own custom errors in a alex+happy parser?
2021-09-16 21:34:37 +0000 <sm> wow. I guess reflex works
2021-09-16 21:36:44 +0000 <newbie> Hi again, I could not make it work. I do realize something is very wrong with the type signatures i pass around, just not how to fix it. I have created a pastebin with a minimized problem: https://pastebin.com/Pc8KA4dv
2021-09-16 21:37:11 +0000 <newbie> Question from before: I have a question regarding '>>=' of Either. If I want to apply it to a tuple containing Either instead i.e (Either SomeData a, String), how can I lift '>>=' such that it operates on tuples?
2021-09-16 21:37:26 +0000cuz(~user@38.140.58.234)
2021-09-16 21:37:29 +0000 <newbie> Namely to define ">>=" for Test without patternmatching on Either
2021-09-16 21:38:22 +0000 <kuribas> newbie: what is you monad doing with those integers?
2021-09-16 21:38:25 +0000 <kuribas> collecting them?
2021-09-16 21:38:59 +0000 <newbie> Just collecting them
2021-09-16 21:39:12 +0000hexfive(~eric@50.35.83.177)
2021-09-16 21:39:14 +0000merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2021-09-16 21:39:58 +0000waleee(~waleee@2001:9b0:216:8200:d457:9189:7843:1dbd) (Ping timeout: 252 seconds)
2021-09-16 21:40:12 +0000 <newbie> I just realize '>>=' for either would never concatenate the integer list, thus it would never work
2021-09-16 21:40:20 +0000hexfive(~eric@50.35.83.177) (Client Quit)
2021-09-16 21:40:55 +0000 <kuribas> then ExceptT SomeData (ReaderT String (WriterT [Integer])) ?
2021-09-16 21:41:11 +0000 <kuribas> erm Writer, not WriterT
2021-09-16 21:41:27 +0000 <kuribas> or ExceptT SomeData (ReaderT String ([Integer],))
2021-09-16 21:41:51 +0000waleee(~waleee@h-98-128-228-119.na.cust.bahnhof.se)
2021-09-16 21:42:29 +0000 <newbie> Damn okay, that seems way to complicated to me
2021-09-16 21:42:58 +0000cuz(~user@38.140.58.234) (Ping timeout: 260 seconds)
2021-09-16 21:43:01 +0000 <newbie> Is pattern matching in declarations of 'bind' necessarily a bad idea?
2021-09-16 21:43:34 +0000 <kuribas> newbie: just use GeneralizedNewtypeDeriving.
2021-09-16 21:43:42 +0000 <kuribas> No need to write any instances.
2021-09-16 21:43:46 +0000 <ldlework> newbie: is the goal to make a Test Monad where you can compose a bunch of tests together and get some structure with all the results as Eithers
2021-09-16 21:44:06 +0000 <ldlework> or to short circuit on the first test
2021-09-16 21:44:09 +0000 <ldlework> that fails
2021-09-16 21:44:35 +0000 <newbie> It should short-circuit on the first test that fails
2021-09-16 21:44:41 +0000 <dsal> > Right [1] <> Right [2]
2021-09-16 21:44:43 +0000 <lambdabot> Right [1]
2021-09-16 21:44:46 +0000favonia(~favonia@user/favonia)
2021-09-16 21:44:59 +0000 <dsal> Huh. That's interesting.
2021-09-16 21:45:06 +0000 <dsal> > Just [1] <> Just [2]
2021-09-16 21:45:08 +0000 <lambdabot> Just [1,2]
2021-09-16 21:45:18 +0000 <dsal> Who thought that was a good idea?
2021-09-16 21:45:43 +0000 <ldlework> dsal: there might be multiple monads
2021-09-16 21:45:55 +0000 <ldlework> wait no, i'm dumb
2021-09-16 21:46:03 +0000 <newbie> It's for a school assignment, so the declarations is static. I have made a solution that works using pattern matching in ">>=" declaration of 'Test' , however I just wanted to see if I could utilize monads some more
2021-09-16 21:46:23 +0000System12_(~System123@net-37-179-171-3.cust.vodafonedsl.it)
2021-09-16 21:46:46 +0000 <ldlework> newbie: they have you do haskell at school?
2021-09-16 21:46:55 +0000 <newbie> Oh yes
2021-09-16 21:47:08 +0000 <dsal> ldlework: It's surprising when `Maybe` and `Left x` behave differently.
2021-09-16 21:47:14 +0000 <dsal> Er, `Either x`
2021-09-16 21:47:25 +0000 <ldlework> newbie: dope
2021-09-16 21:47:49 +0000wroathe(~wroathe@user/wroathe) (Ping timeout: 265 seconds)
2021-09-16 21:47:54 +0000jokleinn(~jokleinn@user/jokleinn) (Quit: WeeChat 3.2)
2021-09-16 21:48:04 +0000 <newbie> We have 3 weeks of Haskell, 3 weeks of Erlang and then an exam where you have to write a pretty big program in both within a week
2021-09-16 21:48:59 +0000 <kuribas> 3 weeks is very short
2021-09-16 21:49:30 +0000System123(~System123@ec2-52-61-197-79.us-gov-west-1.compute.amazonaws.com) (Ping timeout: 260 seconds)
2021-09-16 21:49:47 +0000 <ldlework> I'm only like 6 days in :P
2021-09-16 21:49:56 +0000 <newbie> I wish we had some more weeks ya, Haskell is a language I really have wanted to learn for years
2021-09-16 21:50:04 +0000 <ldlework> oh, that's the length of the whole program?!
2021-09-16 21:50:24 +0000 <ldlework> i thought you were saying you had three weeks under your belt
2021-09-16 21:50:36 +0000 <ldlework> newbie: I think >=> can come into play here
2021-09-16 21:50:41 +0000 <newbie> Oh no, that is the program/course
2021-09-16 21:51:22 +0000System12_(~System123@net-37-179-171-3.cust.vodafonedsl.it) (Ping timeout: 260 seconds)
2021-09-16 21:51:37 +0000 <newbie> Got any ideas about how?
2021-09-16 21:51:50 +0000favonia(~favonia@user/favonia) (Ping timeout: 260 seconds)
2021-09-16 21:52:15 +0000jokleinn(~jokleinn@user/jokleinn)
2021-09-16 21:52:46 +0000 <ldlework> newbie: still thinking about it
2021-09-16 21:53:10 +0000michalz(~michalz@185.246.204.61) (Remote host closed the connection)
2021-09-16 21:53:19 +0000Pickchea(~private@user/pickchea) (Quit: Leaving)
2021-09-16 21:53:54 +0000 <kuribas> newbie: can you explain the problem?
2021-09-16 21:54:00 +0000 <ldlework> it kind of feels wierd
2021-09-16 21:54:06 +0000 <ldlework> because the function is inside the Test Monad
2021-09-16 21:54:25 +0000 <ldlework> what are the semantics of >>= supposed to be
2021-09-16 21:54:41 +0000 <ldlework> it feels like the thing desired is some associativity
2021-09-16 21:54:57 +0000 <ldlework> t1 <> t2 <> t3 == some Either
2021-09-16 21:55:05 +0000 <kuribas> :t runReaderT . runExceptT
2021-09-16 21:55:07 +0000 <lambdabot> ExceptT e (ReaderT r m) a -> r -> m (Either e a)
2021-09-16 21:55:20 +0000 <ldlework> Ah I don't know the Reader monad yet
2021-09-16 21:55:34 +0000 <ldlework> I should finish HFFP..
2021-09-16 21:55:38 +0000 <kuribas> substitute m = ([Integer],)
2021-09-16 21:55:42 +0000ec_(~ec@gateway/tor-sasl/ec) (Ping timeout: 276 seconds)
2021-09-16 21:55:49 +0000 <kuribas> that's your monad.
2021-09-16 21:56:01 +0000sleym(~sleym@195.181.171.237)
2021-09-16 21:56:05 +0000 <kuribas> Not sure it's the one you need for the problem though...
2021-09-16 21:56:34 +0000 <kuribas> Also, appending lists is very inefficient.
2021-09-16 21:57:31 +0000 <ldlework> kuribas: without Reader would it be enough to implement Monoid for Test?
2021-09-16 21:57:42 +0000slowButPresent(~slowButPr@user/slowbutpresent) (Quit: leaving)
2021-09-16 21:58:08 +0000 <ldlework> run the test, return either a Left failure, or a Right Integer composed with a recursive call to the rest of the tests
2021-09-16 21:58:28 +0000sleym(~sleym@195.181.171.237) (Client Quit)
2021-09-16 21:59:03 +0000 <ldlework> t1 <> t2 == Either (SomeData a) [Integer]
2021-09-16 21:59:35 +0000 <kuribas> ldlework: I have no idea what this function is supposed to do...
2021-09-16 21:59:43 +0000 <ldlework> which one
2021-09-16 21:59:48 +0000 <kuribas> What's SomeData? What's String?
2021-09-16 21:59:57 +0000 <kuribas> The one from newbie
2021-09-16 22:00:00 +0000 <ldlework> kuribas: it's in his pastebin
2021-09-16 22:00:11 +0000 <ldlework> I think SomeData is a catch all for reporting errors
2021-09-16 22:00:16 +0000 <ldlework> the successes are single integers
2021-09-16 22:00:28 +0000 <newbie> SomeData is a catch for all reporting errors
2021-09-16 22:00:29 +0000 <ldlework> the result should either be a Left SomeData a, or a Right [Integer]
2021-09-16 22:00:46 +0000 <newbie> Test does a computation given the "string input"
2021-09-16 22:00:50 +0000 <ldlework> so it feels like all you need is monoid
2021-09-16 22:01:25 +0000 <newbie> And side effects is passed into the [Integer] : 0 = no side effect, 1 = side effect
2021-09-16 22:01:34 +0000jokleinn(~jokleinn@user/jokleinn) (Quit: WeeChat 3.2)
2021-09-16 22:02:24 +0000ec_(~ec@gateway/tor-sasl/ec)
2021-09-16 22:03:01 +0000 <kuribas> That sounds more like sequence...
2021-09-16 22:03:14 +0000shailangsa(~shailangs@host86-186-132-44.range86-186.btcentralplus.com)
2021-09-16 22:04:03 +0000 <kuribas> :t sequence
2021-09-16 22:04:04 +0000 <lambdabot> (Traversable t, Monad m) => t (m a) -> m (t a)
2021-09-16 22:04:54 +0000favonia(~favonia@user/favonia)
2021-09-16 22:04:58 +0000 <kuribas> you run all the tests, and collect the errors.
2021-09-16 22:05:27 +0000 <kuribas> newbie's description isn't very clear...
2021-09-16 22:05:35 +0000 <kuribas> Why does he need monad here?
2021-09-16 22:05:35 +0000tromp(~textual@dhcp-077-249-230-040.chello.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2021-09-16 22:05:48 +0000 <kuribas> Does the result of one test depends on the other test?
2021-09-16 22:05:55 +0000 <monochrom> This is a school assignment right? Could we see the verbatim school assignment, not your interpretation?
2021-09-16 22:06:15 +0000 <monochrom> Because my data shows that students always misinterpret everything on the assignment handout.
2021-09-16 22:06:30 +0000 <monochrom> Or at least those students who actually need help.
2021-09-16 22:07:11 +0000 <newbie> It is my bad, I tried to obfuscate the types and assignment since one of my teachers is admin in here
2021-09-16 22:07:40 +0000 <newbie> I'll try to come up with a better explanation, 1 sec
2021-09-16 22:08:05 +0000 <geekosaur> heh
2021-09-16 22:08:17 +0000 <monochrom> Oh, I don't think they will mind you asking, as long as the answerers, in turn, are careful about what help to provide.
2021-09-16 22:08:23 +0000 <monochrom> err
2021-09-16 22:08:31 +0000 <monochrom> nah, no typo.
2021-09-16 22:11:35 +0000 <ProofTechnique> I barely did my own homework, I'm not about to start giving away answers for other people's 😄
2021-09-16 22:11:42 +0000 <monochrom> haha
2021-09-16 22:11:47 +0000OscarH(~OscarH@054449d6.skybroadband.com) (Ping timeout: 245 seconds)
2021-09-16 22:11:59 +0000 <hpc> irc is the original proof of work protocol
2021-09-16 22:13:18 +0000merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 260 seconds)
2021-09-16 22:13:53 +0000slowButPresent(~slowButPr@user/slowbutpresent)
2021-09-16 22:14:38 +0000Erutuon(~Erutuon@user/erutuon) (Quit: WeeChat 2.8)
2021-09-16 22:16:16 +0000 <newbie> I created a formulation more 1:1 with my assignment
2021-09-16 22:16:17 +0000 <newbie> https://pastebin.com/KPZQDeyN
2021-09-16 22:17:03 +0000 <newbie> Oh lord, bad formatting. This one is better https://pastebin.com/JHKrCSHJ
2021-09-16 22:17:09 +0000wroathe(~wroathe@c-75-72-98-163.hsd1.mn.comcast.net)
2021-09-16 22:17:09 +0000wroathe(~wroathe@c-75-72-98-163.hsd1.mn.comcast.net) (Changing host)
2021-09-16 22:17:09 +0000wroathe(~wroathe@user/wroathe)
2021-09-16 22:18:02 +0000 <newbie> I have included my working solution using pattern matching - however I wish to avoid that somehow since it seems kinda un-Haskell'y
2021-09-16 22:18:27 +0000 <kuribas> err, what is unhaskelly about it?
2021-09-16 22:18:44 +0000 <awpr> :t first
2021-09-16 22:18:45 +0000 <Cajun> i find guards to be more non-idiomatic than pattern matching
2021-09-16 22:18:45 +0000 <lambdabot> Arrow a => a b c -> a (b, d) (c, d)
2021-09-16 22:18:48 +0000 <awpr> :t fst
2021-09-16 22:18:49 +0000 <lambdabot> (a, b) -> a
2021-09-16 22:18:50 +0000 <monochrom> I bet it means "writing code by hand".
2021-09-16 22:18:59 +0000gehmehgeh(~user@user/gehmehgeh) (Quit: Leaving)
2021-09-16 22:18:59 +0000seventhCrow(crow@gateway/vpn/protonvpn/seventhcrow) (Remote host closed the connection)
2021-09-16 22:19:25 +0000seventhCrow(crow@gateway/vpn/protonvpn/seventhcrow)
2021-09-16 22:19:33 +0000 <newbie> My teacher seems to want us to utilize Monads in every possible case
2021-09-16 22:20:01 +0000 <monochrom> Well that's one of the possible misinterpretations I was talking about.
2021-09-16 22:20:44 +0000 <monochrom> I completely never worried about how you changed type names away from the original assignment. I'm sure you didn't goof that part.
2021-09-16 22:21:10 +0000favonia(~favonia@user/favonia) (Ping timeout: 252 seconds)
2021-09-16 22:21:10 +0000 <monochrom> But what your actual job is, every student who seek help always misinterpret that.
2021-09-16 22:22:40 +0000 <monochrom> In particular since the tuple order is (Either SomeError a, [String]) rather than ([String], Either SomeError a), you will not be able to "utilize Monads" to the fullest extent.
2021-09-16 22:22:55 +0000 <monochrom> s/you will not/no one will/
2021-09-16 22:23:39 +0000 <awpr> it almost looks like it's designed to force you to implement it directly instead of with easy DerivingVia trickery
2021-09-16 22:24:17 +0000 <awpr> ...although maybe if a student knows to use DerivingVia and what via type would get the right result, they should be able to do that :)
2021-09-16 22:24:55 +0000 <monochrom> Concretely, there are two points on why the not-working version is not working.
2021-09-16 22:25:33 +0000 <monochrom> "f (first t)" is a type error after you find out correctly the type of t. It doesn't fit there.
2021-09-16 22:25:52 +0000 <newbie> I see, thank you guys. It is still somewhat hard to comprehend Haskell within the first week of learning it, which is why I wanted to find out if I could do something smarter than what I did
2021-09-16 22:26:17 +0000 <kuribas> newbie: I don't think you're supposed to do something smart.
2021-09-16 22:26:23 +0000 <ProofTechnique> (I'm mostly just mystified by the lack of Functor and Applicative instances)
2021-09-16 22:26:27 +0000 <monochrom> And if you look at the working version, you find that you don't unconditionally do "runTest (f whatever)". You do it only under one condition.
2021-09-16 22:26:48 +0000 <monochrom> In the not-working version, you're doing it unconditionally.
2021-09-16 22:27:08 +0000 <awpr> never hurts to learn by practicing though, even if the assignment is perfectly content with being implemented by direct pattern matching
2021-09-16 22:27:45 +0000 <newbie> The conditional thing actually makes sense
2021-09-16 22:27:50 +0000 <kuribas> awpr: it hurts if they try to do advanced stuff, when they don't grasp the simple stuff.
2021-09-16 22:28:04 +0000 <kuribas> Doing pattern matching is fine.
2021-09-16 22:28:17 +0000jokleinn(~jokleinn@user/jokleinn)
2021-09-16 22:28:28 +0000 <awpr> depends on what "hurts" means. "my brain hurts" maybe, but if they figure it out after a few hours of trying by choice / for fun, then that's learning
2021-09-16 22:28:30 +0000 <newbie> awpr: Exactly: I already have a working solution for the assignment, so trying to explore other options and learn from that is very nice
2021-09-16 22:29:43 +0000 <ProofTechnique> The only stylistic thing you _could_ do (and you definitely don't _need_ to) is to reorder the cases and replace your `(Left a, x) -> (Left a, x)` with something like `err -> err`, since you don't need to inspect or do anything with any of the components
2021-09-16 22:30:01 +0000 <newbie> At least that is how I learn. Next time I experience a similar problem I will not spend hours wondering about it
2021-09-16 22:30:30 +0000 <newbie> ProofTechnique: Oh ya ofc, thanks : )
2021-09-16 22:31:43 +0000 <kuribas> newbie: well, the short way would be to use the monad stack.
2021-09-16 22:32:36 +0000 <ProofTechnique> Simply replace all this completely readable pattern matching with an inscrutable transformer stack!
2021-09-16 22:33:00 +0000 <ProofTechnique> That'll show the TA what's what :D
2021-09-16 22:33:59 +0000 <kuribas> ProofTechnique: he wanted to know what's after the manual implementation :-)
2021-09-16 22:34:28 +0000 <newbie> I do not know what that is lol
2021-09-16 22:35:05 +0000 <kuribas> newbie: composition of monads.
2021-09-16 22:35:19 +0000 <monochrom> They just mean there is a way to refactor Env -> (Either SomeError a, [String]) into 3 pieces, and then it won't suck.
2021-09-16 22:35:54 +0000 <kuribas> well, then I can be lazy, and let the compiler infer the instances.
2021-09-16 22:36:03 +0000 <newbie> So a monad stack is utilizing MonadTransformers?
2021-09-16 22:36:09 +0000 <kuribas> yes
2021-09-16 22:36:49 +0000 <kuribas> you "stack" the monad transformers on top of each other, hence "monad stack".
2021-09-16 22:36:59 +0000 <monochrom> My POV is that if you do that, there are 2 annoying newtype wrappers that get into the way, it will still be ugly.
2021-09-16 22:37:10 +0000 <kuribas> monochrom: coerce?
2021-09-16 22:37:26 +0000 <newbie> Ah nice, makes sense
2021-09-16 22:37:34 +0000 <monochrom> Ugh do you teach coerce in a course? Any course?
2021-09-16 22:37:36 +0000 <ProofTechnique> If you want the compiler to write code for you, just ask the nearest Simon to do it instead
2021-09-16 22:37:44 +0000 <newbie> I think I have to work a little more with monads before utilizing Monad Transformers tho
2021-09-16 22:37:52 +0000 <kuribas> monochrom: of course not
2021-09-16 22:38:51 +0000 <ProofTechnique> Oh, that reminds me: Seeing as it's school season again, we should get a list of active courses and their problem sets so we can get ahead of the questions :)
2021-09-16 22:39:42 +0000pfurla_pfurla
2021-09-16 22:40:19 +0000 <ProofTechnique> Professors of IRC, post your syllabus so we can prepare maximally cryptic pointfree solutions to homework questions
2021-09-16 22:40:31 +0000 <newbie> :D
2021-09-16 22:40:34 +0000 <monochrom> haha
2021-09-16 22:41:01 +0000 <monochrom> I don't think pointfree is all that hot any more.
2021-09-16 22:41:02 +0000 <awpr> we can insert 0-width spaces to fingerprint our solutions
2021-09-16 22:41:12 +0000 <geekosaur> ContT
2021-09-16 22:41:15 +0000 <monochrom> The rage is with either linear types or type-level tricks.
2021-09-16 22:41:19 +0000 <hpc> zygohistomorphic prepromorphisms?
2021-09-16 22:41:50 +0000 <ldlework> i usually let hlint eta reduce my stuff
2021-09-16 22:42:01 +0000 <ldlework> dunno if it's a good habit yet
2021-09-16 22:42:32 +0000 <dsal> hlint has some good suggestions and some really weird ones.
2021-09-16 22:42:36 +0000 <monochrom> There was once I inserted or delete spaces or puntuations to fingerprint my solutions.
2021-09-16 22:42:41 +0000 <dsal> The trick is to find two people who can agree on either of those categories.
2021-09-16 22:43:16 +0000 <monochrom> I had 6 TAs, 1 of them was leaking my solution to help students cheat, I wanted to find out who.
2021-09-16 22:43:16 +0000 <awpr> "use operator sections" on alphanumeric names is a particularly weird one
2021-09-16 22:43:20 +0000 <ProofTechnique> "It's very simple. Just start with `data family Homework a` ..."
2021-09-16 22:44:14 +0000 <monochrom> So when I sent solutions to TAs for preparation, each TA received a different addition or deletion of spaces or puntuations.
2021-09-16 22:44:16 +0000 <ldlework> awpr: do you ever do that yourself?
2021-09-16 22:44:25 +0000 <ldlework> sometimes I have done (`foo` val)
2021-09-16 22:44:25 +0000 <dsal> I do that some sometimes.
2021-09-16 22:44:47 +0000 <awpr> if HLint bugs me about it I'll generally just do it, but stream of consciousness I tend to end up writing `flip foo val`
2021-09-16 22:44:52 +0000 <monochrom> So when the cheating student submitted my solution obtained through a TA, I was able to identify the TA.
2021-09-16 22:44:53 +0000 <dsal> hlint author hates flip
2021-09-16 22:45:09 +0000 <monochrom> The students and the TA were successfully convicted.
2021-09-16 22:45:10 +0000 <ProofTechnique> Those are some bush league cheaters, sheesh. Imagine copying and pasting like a rube :/
2021-09-16 22:45:45 +0000 <awpr> sounds like some old spy story where an agency intentionally leaked subtly different information to their agents to find out who was leaking
2021-09-16 22:45:52 +0000 <ldlework> i think sectioning is cool, because flipping is like a "natural need" based on the nature of what we're doing
2021-09-16 22:45:58 +0000 <monochrom> awpr, I think "map (`mod` 7) [a,b,c]" is fairly OK.
2021-09-16 22:46:02 +0000 <ldlework> so it's nice to have a tiny sugar for it
2021-09-16 22:46:17 +0000 <ldlework> yeah that
2021-09-16 22:46:25 +0000kuribas(~user@ptr-25vy0i9fqiblx2l1e59.18120a2.ip6.access.telenet.be) (Quit: ERC (IRC client for Emacs 26.3))
2021-09-16 22:46:27 +0000 <awpr> monochrom: yeah, it's perfectly fine IMO, just not sure I see the need to have a linter forbid the alternative for all prefix functions
2021-09-16 22:46:49 +0000 <monochrom> all (`elem` ['a'..'z']) mystring
2021-09-16 22:46:56 +0000 <ldlework> is hlint configurable in that sense?
2021-09-16 22:46:57 +0000 <monochrom> at which point it read like English
2021-09-16 22:46:59 +0000 <ldlework> like eslint
2021-09-16 22:47:04 +0000 <monochrom> at which point it read like COBOL, too
2021-09-16 22:47:09 +0000hyiltiz(~quassel@31.220.5.250)
2021-09-16 22:47:19 +0000newbie(~newbie@80-196-109-198-dynamic.dk.customer.tdc.net) (Remote host closed the connection)
2021-09-16 22:47:20 +0000 <ProofTechnique> flip is a subtle poison. I use it, too, but it gets out of hand so fast if you let it :D
2021-09-16 22:47:23 +0000 <awpr> yeah, those uses and plenty of others do look better than with flip, IMO
2021-09-16 22:47:44 +0000 <monochrom> Oh yeah, hlint is opinion, not linter. False advertising.
2021-09-16 22:48:19 +0000 <monochrom> "map (\x -> mod x 7)" is fine. Everyone does not have to code like a smart*ss.
2021-09-16 22:48:40 +0000 <ldlework> i have an irrational aversion to haskell's lambdas
2021-09-16 22:49:11 +0000 <ProofTechnique> 80% of my interaction with hlint is idly writing `fmap foo`, seeing it's not the shape I want, sticking `sequence .` on the front and being chided for forgetting that every single problem reduces to `traverse`
2021-09-16 22:49:15 +0000 <ldlework> for some reason I wish you could either `x -> f x` or `(x, y) -> f x y`
2021-09-16 22:49:41 +0000bontaq(~user@ool-45779fe5.dyn.optonline.net)
2021-09-16 22:49:49 +0000 <awpr> backslash is a lambda letter with a missing leg
2021-09-16 22:50:00 +0000 <monochrom> You will want |->, which is what mathematicians do.
2021-09-16 22:50:06 +0000 <ldlework> yeah but the parser isn't strong enough to not require parens everywhere
2021-09-16 22:50:14 +0000 <ldlework> or grammar or whatever
2021-09-16 22:50:20 +0000 <ProofTechnique> Turn on UnicodeSyntax and ensure that no one will ever work with you. Problem solved
2021-09-16 22:50:25 +0000 <ldlework> haha
2021-09-16 22:50:30 +0000 <monochrom> Why do you have an irrational aversion to parentheses?
2021-09-16 22:50:42 +0000 <awpr> time for Lisp exposure therapy
2021-09-16 22:50:42 +0000 <ldlework> monochrom: just those ones, with the \ it just gets noisy
2021-09-16 22:50:49 +0000 <ldlework> i come from a lisp background!
2021-09-16 22:50:49 +0000tommd(~tommd@75-164-130-101.ptld.qwest.net)
2021-09-16 22:51:02 +0000 <ldlework> well, i mean, i have lots of lisp experience!
2021-09-16 22:51:07 +0000 <monochrom> "map ((x,y) |-> f x y)" is fine.
2021-09-16 22:51:19 +0000 <ldlework> afterall, it is an irrational aversion
2021-09-16 22:51:21 +0000 <monochrom> "map (x,y) |-> f x y" is the confusing one. You need parentheses.
2021-09-16 22:51:42 +0000bitdex(~bitdex@gateway/tor-sasl/bitdex)
2021-09-16 22:51:54 +0000 <ProofTechnique> Be a monster and turn on BlockArguments just for `map do \(x, y) -> f x y`
2021-09-16 22:52:34 +0000 <awpr> from a parsing perspective, it might be helpful to have the lambda up front to avoid parsing as an expression and then backtracking. I don't remember if patterns have a separate grammar from expressions, though -- seems like they should with ViewPatterns, AsPatterns, etc.
2021-09-16 22:52:40 +0000 <dsal> Agda manages to let you just use λ
2021-09-16 22:53:02 +0000 <ProofTechnique> Sure, but it's spelled \Gl, which is a lot
2021-09-16 22:53:08 +0000 <ldlework> be like python and just type `lambda` everywhere
2021-09-16 22:53:18 +0000 <monochrom> patterns have to have a separate grammar from expressions.
2021-09-16 22:53:24 +0000 <dsal> I use λ as a parameter in a thing that uses AWS lambda.
2021-09-16 22:53:30 +0000 <monochrom> "f * g" is an expression, but not a pattern.
2021-09-16 22:53:33 +0000 <ldlework> nerd
2021-09-16 22:54:09 +0000 <awpr> I mean, it could parse as a pattern and get rejected by some sanity check, if you really wanted to unify them. but yeah, I agree they should be separate
2021-09-16 22:55:24 +0000 <monochrom> But yeah language designers try to stay within LALR(k) or something for parser efficiency.
2021-09-16 22:55:30 +0000ec_(~ec@gateway/tor-sasl/ec) (Ping timeout: 276 seconds)
2021-09-16 22:55:46 +0000 <ProofTechnique> The sanity check that rejects it is having a separate grammar :)
2021-09-16 22:56:24 +0000 <monochrom> which is arguably silly for a language that goes on to do exponential-time type inference.
2021-09-16 22:56:48 +0000 <monochrom> Cubic-time parsing is nothing compared to type inference.
2021-09-16 22:57:33 +0000 <awpr> even worse is GHC.Generics generating pathological cases for type inference to deal with :)
2021-09-16 22:57:42 +0000 <awpr> or rather DeriveGeneric
2021-09-16 22:58:02 +0000 <ProofTechnique> I would hope the n is quite a bit smaller in the type inference case than in the parsing case, but then I remember deriving chicanery
2021-09-16 23:02:37 +0000ec_(~ec@gateway/tor-sasl/ec)
2021-09-16 23:04:46 +0000 <ldlework> anyone know how to use time in hylogen/hylide?
2021-09-16 23:05:34 +0000wroathe(~wroathe@user/wroathe) (Ping timeout: 260 seconds)
2021-09-16 23:05:54 +0000 <ldlework> nm just got it working
2021-09-16 23:07:21 +0000wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
2021-09-16 23:07:21 +0000wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Changing host)
2021-09-16 23:07:21 +0000wroathe(~wroathe@user/wroathe)
2021-09-16 23:07:30 +0000 <ProofTechnique> I have never seen that library before, but it looks very cool
2021-09-16 23:10:32 +0000aegon(~mike@174.127.249.180)
2021-09-16 23:11:13 +0000 <aegon> is do notation left or right associative in desugaring? bind and >> are left but do is right or am i wrong about right and right is left o_o
2021-09-16 23:12:06 +0000amahl(~amahl@dsl-jklbng12-54fbca-64.dhcp.inet.fi) (Ping timeout: 260 seconds)
2021-09-16 23:12:08 +0000wroathe(~wroathe@user/wroathe) (Ping timeout: 268 seconds)
2021-09-16 23:12:40 +0000 <awpr> seems effectively right-associative, in that the stuff after a do-statement is all contained inside the lambda that's given to the first >>=
2021-09-16 23:13:32 +0000 <ldlework> Where `c` is a `Vec4 a a a a` I wonder how to translate `fract(c.xxxw + K.xyzw)` into hylogen
2021-09-16 23:13:48 +0000[itchyjunk](~itchyjunk@user/itchyjunk/x-7353470)
2021-09-16 23:13:50 +0000 <awpr> the left associativity of >>= is a different matter -- it controls what happens when you write `x >>= f >>= g`, namely that it's the only associativity that typechecks that expression
2021-09-16 23:13:56 +0000wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
2021-09-16 23:13:56 +0000wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Changing host)
2021-09-16 23:13:56 +0000wroathe(~wroathe@user/wroathe)
2021-09-16 23:14:15 +0000 <ldlework> aka swizzling
2021-09-16 23:14:24 +0000mjs2600(~mjs2600@c-24-91-3-49.hsd1.vt.comcast.net)
2021-09-16 23:14:37 +0000 <awpr> meanwhile if you have unparenthesized lambdas, associativity doesn't come into play, it's just the parsing of the lambda eating the rest of the expression
2021-09-16 23:15:06 +0000 <aegon> awpr: thats the source of a bunch of accidently quadradic perf problems if i'm understanding hte reading correct though
2021-09-16 23:15:55 +0000 <awpr> having left-associated binds? yeah, it can be slower for some monads, but just moving the parens around doesn't type-check anymore
2021-09-16 23:17:03 +0000 <aegon> ldlework: i'm just seeing hylogen but it looks like there are a bunch of swizzle funcs already defined here https://hackage.haskell.org/package/hylogen-0.1.5.1/docs/Hylogen-Types-Vec.html
2021-09-16 23:17:10 +0000 <ldlework> i just found those!
2021-09-16 23:17:13 +0000 <ldlework> thank you aegon
2021-09-16 23:17:22 +0000 <aegon> np!
2021-09-16 23:18:27 +0000 <aegon> awpr: thanks for the insight, gonna play around with paren places in ghci to see more what you mean
2021-09-16 23:19:10 +0000 <awpr> `x >>= f >>= g` <-> `x >>= (f >=> g)`
2021-09-16 23:19:43 +0000 <aegon> :t (>=>)
2021-09-16 23:19:44 +0000 <lambdabot> Monad m => (a -> m b) -> (b -> m c) -> a -> m c
2021-09-16 23:19:53 +0000 <awpr> <-> `x >>= \y -> f y >>= g`
2021-09-16 23:20:49 +0000 <awpr> tbh I never actually thought about successive >>=s being a potential performance issue until now. will have to keep that in mind and remember to use the fish operator version
2021-09-16 23:23:27 +0000ec_(~ec@gateway/tor-sasl/ec) (Ping timeout: 276 seconds)
2021-09-16 23:23:44 +0000xsperry(~as@user/xsperry) (Remote host closed the connection)
2021-09-16 23:24:08 +0000 <aegon> i haven't run into anyone suggesting (>=>) in the posts as a way to guard against it, thats kinda neat
2021-09-16 23:27:47 +0000Lycurgus(~juan@98.4.112.204) (Quit: Exeunt)
2021-09-16 23:30:41 +0000retroid_(~retro@176.255.22.194)
2021-09-16 23:31:08 +0000 <ProofTechnique> How does that get rid of binds?
2021-09-16 23:31:30 +0000 <awpr> it right-associates them so you don't repeatedly re-traverse the same structure you just built
2021-09-16 23:31:37 +0000retro_(~retro@176.255.22.194) (Ping timeout: 252 seconds)
2021-09-16 23:32:16 +0000 <awpr> I think the docs of `Codensity` in `kan-extensions` describe the issue pretty well
2021-09-16 23:32:42 +0000 <ProofTechnique> I've only ever seen this bind performance thing come up in the context of free monads, but I'll go read kan-extensions for the details :)
2021-09-16 23:33:53 +0000ec_(~ec@gateway/tor-sasl/ec)
2021-09-16 23:34:20 +0000 <ProofTechnique> Oh, lol, the linked paper is exactly "Asymptotic Improvement of Computations over Free Monads" :D
2021-09-16 23:36:36 +0000ec_(~ec@gateway/tor-sasl/ec) (Client Quit)
2021-09-16 23:38:21 +0000 <ProofTechnique> Oh, gosh, GHC 6.6. I think 6.8.3 was the first GHC I used. The years do fly by
2021-09-16 23:38:23 +0000 <monochrom> Yeah it's mainly for free monads that are coded up as an ADT.
2021-09-16 23:38:47 +0000 <ldlework> Looks like Hylogen is abandoned and it only has minimal support. Dang!
2021-09-16 23:38:50 +0000chris(~chris@81.96.113.213)
2021-09-16 23:38:54 +0000chrisGuest640
2021-09-16 23:39:00 +0000 <monochrom> But even then I am skeptical about how often it hurts. It is not like you have left recursion all that often.
2021-09-16 23:39:42 +0000 <ldlework> my dreams of fast game-of-life in haskell are dying ^_^
2021-09-16 23:40:01 +0000 <ProofTechnique> Revive it!
2021-09-16 23:40:28 +0000 <ProofTechnique> I'm very much looking forward to delimited continuations to happen so I can try out eff without Herculean effort
2021-09-16 23:41:05 +0000tdidrfyls^(~tdidrfyls@68.101.54.227)
2021-09-16 23:41:10 +0000 <ProofTechnique> Polysemy is still very nice, but eff has that sports car sheen
2021-09-16 23:42:34 +0000MQ-17J(~MQ-17J@8.21.10.6) (Ping timeout: 252 seconds)
2021-09-16 23:45:22 +0000geekosaur(~geekosaur@xmonad/geekosaur) (Read error: Connection reset by peer)
2021-09-16 23:45:44 +0000geekosaur(~geekosaur@xmonad/geekosaur)
2021-09-16 23:46:39 +0000 <ldlework> https://github.com/jaredloomis/andromeda
2021-09-16 23:46:43 +0000 <ldlework> this library isn't on hackage
2021-09-16 23:46:46 +0000 <ldlework> how do i install it?
2021-09-16 23:48:10 +0000hyiltiz(~quassel@31.220.5.250) (Ping timeout: 265 seconds)
2021-09-16 23:49:55 +0000System123(~System123@net-37-179-171-3.cust.vodafonedsl.it)
2021-09-16 23:50:04 +0000geekosaur(~geekosaur@xmonad/geekosaur) (Killed (NickServ (GHOST command used by allbery_b)))
2021-09-16 23:50:04 +0000allbery_b(~geekosaur@xmonad/geekosaur)
2021-09-16 23:50:07 +0000allbery_bgeekosaur
2021-09-16 23:50:29 +0000 <aegon> ldlework: with stack you specify the git repo as an external source in your stack.yaml then add the dependency to your package.yaml, with cabal you...
2021-09-16 23:51:05 +0000 <geekosaur> you can also download it and use "cabal install" without naming a package, usually
2021-09-16 23:51:13 +0000 <ProofTechnique> https://cabal.readthedocs.io/en/3.4/cabal-project.html#specifying-packages-from-remote-version-con…
2021-09-16 23:51:16 +0000 <ldlework> i'm using NixOS and the only good info I can find is using cabal
2021-09-16 23:51:24 +0000 <geekosaur> from the directory with the cabal file (or cabal.project file)
2021-09-16 23:52:03 +0000 <ProofTechnique> Idlework: Are you looking to install it in your global package set, or in a project shell? Are you using haskell.nix?
2021-09-16 23:52:33 +0000 <aegon> ldlework: https://cabal.readthedocs.io/en/latest/cabal-project.html#specifying-packages-from-remote-version-…
2021-09-16 23:52:37 +0000 <ProofTechnique> Essentially you just want to write an overlay (or maybe the fancy thing is flakes now) to override `haskellPackages` and add it to the set
2021-09-16 23:53:01 +0000 <ProofTechnique> How to do that nicely depends a little bit on your setup
2021-09-16 23:55:25 +0000mikoto-chan(~mikoto-ch@83.137.2.242) (Ping timeout: 265 seconds)
2021-09-16 23:56:52 +0000System123(~System123@net-37-179-171-3.cust.vodafonedsl.it) (Ping timeout: 265 seconds)
2021-09-16 23:57:10 +0000MQ-17J(~MQ-17J@d192-24-122-179.try.wideopenwest.com)
2021-09-16 23:59:04 +0000justsomeguy(~justsomeg@user/justsomeguy)
2021-09-16 23:59:40 +0000 <ldlework> ProofTechnique: here is the repo I'm working with https://github.com/dustinlacewell/andromeda-hs