2020/12/17

2020-12-17 00:01:02 +0100royal_screwup21(52254809@gateway/web/cgi-irc/kiwiirc.com/ip.82.37.72.9) (Quit: Connection closed)
2020-12-17 00:01:26 +0100royal_screwup21(52254809@gateway/web/cgi-irc/kiwiirc.com/ip.82.37.72.9)
2020-12-17 00:01:46 +0100eyenx(~eyenxeyen@unaffiliated/eye/x-1653358) (Remote host closed the connection)
2020-12-17 00:03:00 +0100eyenx(~eyenxeyen@unaffiliated/eye/x-1653358)
2020-12-17 00:03:38 +0100shatriff(~vitaliish@176-52-216-242.irishtelecom.com) (Remote host closed the connection)
2020-12-17 00:04:15 +0100shatriff(~vitaliish@176-52-216-242.irishtelecom.com)
2020-12-17 00:06:31 +0100royal_screwup21(52254809@gateway/web/cgi-irc/kiwiirc.com/ip.82.37.72.9) (Ping timeout: 268 seconds)
2020-12-17 00:09:07 +0100coot(~coot@37.30.50.101.nat.umts.dynamic.t-mobile.pl) (Quit: coot)
2020-12-17 00:10:27 +0100hseg(~gesh@IGLD-84-228-238-87.inter.net.il) (Ping timeout: 260 seconds)
2020-12-17 00:11:18 +0100hseg(~gesh@IGLD-84-228-238-87.inter.net.il)
2020-12-17 00:14:53 +0100nbloomf(~nbloomf@2600:1700:ad14:3020:a8dc:3f5a:f8f1:dbd6)
2020-12-17 00:16:26 +0100dbmikus(~dbmikus@c-174-49-172-14.hsd1.pa.comcast.net) (Ping timeout: 265 seconds)
2020-12-17 00:16:37 +0100erolm_a(~erolm_a@62.19.36.64) (Ping timeout: 256 seconds)
2020-12-17 00:16:59 +0100erolm_a(~erolm_a@62.19.36.64)
2020-12-17 00:18:25 +0100evanjs(~evanjs@075-129-098-007.res.spectrum.com) (Quit: ZNC 1.8.2 - https://znc.in)
2020-12-17 00:18:39 +0100matryoshka(~matryoshk@184.75.223.227)
2020-12-17 00:19:37 +0100evanjs(~evanjs@075-129-098-007.res.spectrum.com)
2020-12-17 00:19:50 +0100christo(~chris@81.96.113.213) (Remote host closed the connection)
2020-12-17 00:20:22 +0100christo(~chris@81.96.113.213)
2020-12-17 00:21:24 +0100 <fuzzypixelz> how would I "split" a string into a list based on a seperating char?
2020-12-17 00:21:41 +0100 <hpc> @hoogle split
2020-12-17 00:21:41 +0100 <lambdabot> Data.ByteString split :: Word8 -> ByteString -> [ByteString]
2020-12-17 00:21:41 +0100 <lambdabot> Data.ByteString.Char8 split :: Char -> ByteString -> [ByteString]
2020-12-17 00:21:41 +0100 <lambdabot> Data.ByteString.Lazy split :: Word8 -> ByteString -> [ByteString]
2020-12-17 00:21:47 +0100hseg_(~gesh@IGLD-84-228-238-87.inter.net.il)
2020-12-17 00:21:48 +0100 <koz_> fuzzypixelz: What do you want done when two separating chars are adjacent?
2020-12-17 00:22:01 +0100 <hpc> too many splits
2020-12-17 00:22:16 +0100dhouthoo(~dhouthoo@ptr-eitgbj2w0uu6delkbrh.18120a2.ip6.access.telenet.be) (Quit: WeeChat 2.9)
2020-12-17 00:22:19 +0100fendor(~fendor@178.165.130.183.wireless.dyn.drei.com) (Remote host closed the connection)
2020-12-17 00:22:31 +0100 <fuzzypixelz> koz_: I'm just trying to parse a file where each line has a number into a list
2020-12-17 00:23:06 +0100 <koz_> What do your lines look like?
2020-12-17 00:23:10 +0100Ariakenom(~Ariakenom@2001:9b1:efb:fc00:f919:1b80:2acc:f96c) (Ping timeout: 268 seconds)
2020-12-17 00:24:20 +0100 <fuzzypixelz> koz_: each line a 4-6 digit intger
2020-12-17 00:24:24 +0100 <fuzzypixelz> nothing more
2020-12-17 00:24:36 +0100 <koz_> :t lines
2020-12-17 00:24:37 +0100hseg(~gesh@IGLD-84-228-238-87.inter.net.il) (Ping timeout: 246 seconds)
2020-12-17 00:24:38 +0100 <lambdabot> String -> [String]
2020-12-17 00:25:06 +0100christo(~chris@81.96.113.213) (Ping timeout: 272 seconds)
2020-12-17 00:25:14 +0100 <fuzzypixelz> aha
2020-12-17 00:25:57 +0100danvet(~Daniel@2a02:168:57f4:0:efd0:b9e5:5ae6:c2fa) (Ping timeout: 260 seconds)
2020-12-17 00:28:54 +0100evanjs(~evanjs@075-129-098-007.res.spectrum.com) (Quit: ZNC 1.8.2 - https://znc.in)
2020-12-17 00:29:34 +0100hseg_(~gesh@IGLD-84-228-238-87.inter.net.il) (Ping timeout: 256 seconds)
2020-12-17 00:30:36 +0100evanjs(~evanjs@075-129-098-007.res.spectrum.com)
2020-12-17 00:34:52 +0100Ariakenom_(~Ariakenom@2001:9b1:efb:fc00:3541:7c48:4826:58c0) (Quit: Leaving)
2020-12-17 00:34:54 +0100nyd(~nyd@unaffiliated/elysian) (Ping timeout: 256 seconds)
2020-12-17 00:35:37 +0100RENNNN(~sobhan@gentoo/developer/sobhan)
2020-12-17 00:36:04 +0100 <koz_> :t catMaybes
2020-12-17 00:36:05 +0100 <lambdabot> [Maybe a] -> [a]
2020-12-17 00:36:09 +0100evanjs(~evanjs@075-129-098-007.res.spectrum.com) (Quit: ZNC 1.8.2 - https://znc.in)
2020-12-17 00:36:09 +0100 <koz_> Nyaa.
2020-12-17 00:37:40 +0100 <RENNNN> Hi, I'm trying to find all the nodes such that there exists a path from $ to all those nodes in graph, but i'm having difficulty choosing a datatype. is there an easy, O(n) way to do this?
2020-12-17 00:37:48 +0100 <RENNNN> i'm having trouble dealing with loops
2020-12-17 00:38:14 +0100 <koz_> $ is what in this case?
2020-12-17 00:38:26 +0100 <koz_> How is your graph represented?
2020-12-17 00:38:46 +0100 <RENNNN> that's the thing, i haven't even started
2020-12-17 00:38:46 +0100 <fuzzypixelz> I would often want to loop over two list "at the same time"
2020-12-17 00:39:02 +0100olligobber(olligobber@gateway/vpn/privateinternetaccess/olligobber)
2020-12-17 00:39:08 +0100 <monochrom> fuzzypixelz: You can consider zip and zipWith
2020-12-17 00:39:09 +0100 <fuzzypixelz> as in for i in list1 ... for j in list2 ... do something with i, j
2020-12-17 00:39:14 +0100 <koz_> RENNNN: A lot depends on your choice of representation.
2020-12-17 00:39:21 +0100evanjs(~evanjs@075-129-098-007.res.spectrum.com)
2020-12-17 00:39:27 +0100 <koz_> fuzzypixelz: Yep, zipWith or zip are your best friends here.
2020-12-17 00:39:31 +0100 <fuzzypixelz> monochrom: no like a cartesian product
2020-12-17 00:39:42 +0100 <fuzzypixelz> all possible pairs
2020-12-17 00:39:48 +0100 <koz_> fuzzypixelz: (,) <$> list1 <*> list2
2020-12-17 00:39:50 +0100ishutin(~Ishutin@178-164-206-88.pool.digikabel.hu)
2020-12-17 00:40:07 +0100 <RENNNN> koz_, i have it as an adjacency list
2020-12-17 00:40:11 +0100 <koz_> There ya go, all possible pairs.
2020-12-17 00:40:16 +0100 <monochrom> RENNNN: Data.Graph comes with GHC. It has the "reachable" function.
2020-12-17 00:40:21 +0100 <fuzzypixelz> how does that even work!
2020-12-17 00:40:26 +0100 <fuzzypixelz> :)
2020-12-17 00:40:32 +0100 <koz_> fuzzypixelz: The Applicative instance for list?
2020-12-17 00:40:59 +0100 <fuzzypixelz> koz_: uhh, yes? if that's what it's called
2020-12-17 00:41:01 +0100 <monochrom> > (,) <$> [1,2,3] <*> "abc"
2020-12-17 00:41:03 +0100 <lambdabot> [(1,'a'),(1,'b'),(1,'c'),(2,'a'),(2,'b'),(2,'c'),(3,'a'),(3,'b'),(3,'c')]
2020-12-17 00:41:28 +0100 <koz_> fuzzypixelz: Just by the way it defines 'pure' and '<*>'.
2020-12-17 00:41:32 +0100 <monochrom> tl;dr []'s <*> does cartesian product
2020-12-17 00:41:33 +0100 <koz_> (and the laws)
2020-12-17 00:41:54 +0100 <monochrom> List comprehension does, too. [(a,b) | a<-[1,2,3], b<-"abc"]
2020-12-17 00:42:27 +0100 <RENNNN> monochrom, it doesn't support edge weights
2020-12-17 00:42:29 +0100evanjs(~evanjs@075-129-098-007.res.spectrum.com) (Client Quit)
2020-12-17 00:42:39 +0100 <monochrom> []'s monadness does too. [1,2,3] >>= \a -> "abc" >>= \b -> return (a,b)
2020-12-17 00:43:24 +0100ishutin_(~Ishutin@94-21-55-45.pool.digikabel.hu) (Ping timeout: 256 seconds)
2020-12-17 00:44:06 +0100christo(~chris@81.96.113.213)
2020-12-17 00:44:40 +0100evanjs(~evanjs@075-129-098-007.res.spectrum.com)
2020-12-17 00:45:46 +0100Gigabitten(~Somn@098-127-002-172.res.spectrum.com)
2020-12-17 00:48:06 +0100nineonin_(~nineonine@50.216.62.2)
2020-12-17 00:48:06 +0100nineonine(~nineonine@50.216.62.2) (Remote host closed the connection)
2020-12-17 00:49:34 +0100dhil(~dhil@78.156.97.38) (Ping timeout: 260 seconds)
2020-12-17 00:52:44 +0100ransom_(~c4264035@8.48.134.25) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2020-12-17 00:54:08 +0100star_cloud(~star_clou@ec2-34-220-44-120.us-west-2.compute.amazonaws.com) (Ping timeout: 265 seconds)
2020-12-17 00:57:42 +0100ubert(~Thunderbi@p200300ecdf3514a6e6b318fffe838f33.dip0.t-ipconnect.de) (Ping timeout: 260 seconds)
2020-12-17 00:58:03 +0100 <fuzzypixelz> can I sort of map read :: Int on a list? I hope I'm making sense
2020-12-17 00:58:24 +0100 <fuzzypixelz> oh wait I'm silly
2020-12-17 00:58:51 +0100 <monochrom> map read ["123", "456"] :: [Int]
2020-12-17 00:58:52 +0100 <fuzzypixelz> >map (\x -> read x :: Int) ["13", "42", "2020"]
2020-12-17 00:58:59 +0100 <monochrom> That too.
2020-12-17 00:59:40 +0100 <fuzzypixelz> how can you put the :: [Int] at the end?
2020-12-17 00:59:45 +0100 <monochrom> Or you don't even need to worry about it. If you give that [Int] to some function that requires [Int], type inference will know.
2020-12-17 00:59:58 +0100 <fuzzypixelz> it is supposed to be at the end of any expression?
2020-12-17 01:00:10 +0100Gurkenglas(~Gurkengla@unaffiliated/gurkenglas) (Ping timeout: 256 seconds)
2020-12-17 01:00:19 +0100 <monochrom> yes up to parenthesizing
2020-12-17 01:00:44 +0100 <monochrom> Perhaps think of :: as very low priority.
2020-12-17 01:00:49 +0100 <monochrom> err, low precedence
2020-12-17 01:00:58 +0100merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 256 seconds)
2020-12-17 01:01:04 +0100elliott__(~elliott@pool-108-51-101-42.washdc.fios.verizon.net)
2020-12-17 01:03:13 +0100kupi(uid212005@gateway/web/irccloud.com/x-jxedmdsaplwusuum) (Quit: Connection closed for inactivity)
2020-12-17 01:03:15 +0100Adluc(~Adluc@2a01:430:17:1::ffff:328) (Quit: ZNC - http://znc.in)
2020-12-17 01:03:15 +0100hexo-(~hexo@83.167.228.130) (Quit: ZNC - http://znc.in)
2020-12-17 01:03:23 +0100cosimone_(~cosimone@5.171.25.104)
2020-12-17 01:03:45 +0100cosimone(~cosimone@93-47-228-249.ip115.fastwebnet.it) (Ping timeout: 240 seconds)
2020-12-17 01:03:52 +0100LKoen(~LKoen@29.248.88.92.rev.sfr.net) (Quit: “It’s only logical. First you learn to talk, then you learn to think. Too bad it’s not the other way round.”)
2020-12-17 01:04:35 +0100cosimone_cosimone
2020-12-17 01:05:24 +0100 <monochrom> > (((((\x -> x) :: a -> a) :: [a] -> [a]) :: [[a]] -> [[a]]) :: [[Int] -> [[Int]]) []
2020-12-17 01:05:26 +0100 <lambdabot> <hint>:1:80: error: <hint>:1:80: error: parse error on input ‘)’
2020-12-17 01:05:30 +0100 <monochrom> Darn
2020-12-17 01:06:11 +0100Trixar_za(~Trixar_za@185.103.96.147) (Remote host closed the connection)
2020-12-17 01:06:41 +0100 <monochrom> > (((((\x -> x) :: a -> a) :: [a] -> [a]) :: [[a]] -> [[a]]) :: [[Int]] -> [[Int]]) []
2020-12-17 01:06:43 +0100 <lambdabot> []
2020-12-17 01:06:44 +0100 <monochrom> :)
2020-12-17 01:06:57 +0100drincruz(~adriancru@ool-44c748be.dyn.optonline.net) (Ping timeout: 268 seconds)
2020-12-17 01:08:21 +0100 <monochrom> Ah, I had [[Int] lacking one ]
2020-12-17 01:08:41 +0100justanotheruser(~justanoth@unaffiliated/justanotheruser) (Read error: Connection reset by peer)
2020-12-17 01:09:27 +0100 <fuzzypixelz> uhh, suppose I have functions f1, f2, and f3
2020-12-17 01:09:55 +0100 <fuzzypixelz> and I want to say f is the function that applies f3 then f2 then f1
2020-12-17 01:10:13 +0100 <monochrom> f = f1 . f2 . f3 ?
2020-12-17 01:10:28 +0100 <monochrom> becuase then f x = f1 (f2 (f3 x))
2020-12-17 01:10:30 +0100 <fuzzypixelz> okay... the dot operator is new to me
2020-12-17 01:10:43 +0100Gigabitten(~Somn@098-127-002-172.res.spectrum.com) (Remote host closed the connection)
2020-12-17 01:10:49 +0100 <monochrom> You can also just write f x = f1 (f2 (f3 x)) and KISS
2020-12-17 01:11:21 +0100 <monochrom> Haskell's f . g is math's f ∘ g
2020-12-17 01:11:25 +0100evanjs(~evanjs@075-129-098-007.res.spectrum.com) (Quit: ZNC 1.8.2 - https://znc.in)
2020-12-17 01:11:28 +0100patrickp(~patrickp@windows98.dev) (Quit: Ping timeout (120 seconds))
2020-12-17 01:11:32 +0100 <fuzzypixelz> oh yes, I just wanted to define a function and not apply it
2020-12-17 01:11:48 +0100mouseghost(~draco@wikipedia/desperek) (Quit: mew wew)
2020-12-17 01:11:54 +0100 <fuzzypixelz> I took up programming because I was tired of doing maths :|
2020-12-17 01:12:00 +0100 <fuzzypixelz> something like that
2020-12-17 01:12:24 +0100patrickp(~patrickp@windows98.dev)
2020-12-17 01:12:35 +0100nrmt^(nrm@ip98-184-89-2.mc.at.cox.net) ()
2020-12-17 01:12:39 +0100evanjs(~evanjs@075-129-098-007.res.spectrum.com)
2020-12-17 01:14:00 +0100 <hpc> you may find that you're tired of doing calculation, and math (via programming) is a breath of fresh air ;)
2020-12-17 01:14:04 +0100shatriff(~vitaliish@176-52-216-242.irishtelecom.com) (Ping timeout: 260 seconds)
2020-12-17 01:16:51 +0100wonko7(~wonko7@lns-bzn-55-82-255-183-4.adsl.proxad.net) (Ping timeout: 265 seconds)
2020-12-17 01:18:53 +0100livvy(~livvy@gateway/tor-sasl/livvy) (Remote host closed the connection)
2020-12-17 01:21:05 +0100Adluc(~Adluc@83.167.228.130)
2020-12-17 01:22:23 +0100 <dolio> Not designing with automatic calculation in mind is one of the fundamental problems with most math.
2020-12-17 01:22:25 +0100texasmynsted(~texasmyns@99.96.221.112) (Ping timeout: 264 seconds)
2020-12-17 01:23:30 +0100 <boxscape> understandable considering a lot of it was invented before there were practical automata
2020-12-17 01:23:39 +0100texasmynsted(~texasmyns@99.96.221.112)
2020-12-17 01:23:49 +0100elliott__(~elliott@pool-108-51-101-42.washdc.fios.verizon.net) (Quit: WeeChat 2.9)
2020-12-17 01:24:02 +0100cads(~cads@ip-64-72-99-232.lasvegas.net) (Ping timeout: 256 seconds)
2020-12-17 01:24:13 +0100cads2(~cads@ip-64-72-99-232.lasvegas.net) (Ping timeout: 268 seconds)
2020-12-17 01:24:25 +0100 <dolio> For instance, some of the HoTT people proved "homotopy canonicity" of one of the theories. Canonicity is the thing that computer folks care about, because it says that when you define `M : Nat`, the computer will actually calculate a numeral for you. Homotopy canonicity says that every term is path-equivalent to a numeral, which only tells you that if you already know the answer you want, whatever the computer calculates will be provably equal to the
2020-12-17 01:24:25 +0100 <dolio> answer.
2020-12-17 01:24:45 +0100devdsp(~devdsp@178.162.212.214)
2020-12-17 01:25:17 +0100nbloomf(~nbloomf@2600:1700:ad14:3020:a8dc:3f5a:f8f1:dbd6) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2020-12-17 01:25:31 +0100cantstanya(~chatting@gateway/tor-sasl/cantstanya) (Remote host closed the connection)
2020-12-17 01:27:47 +0100elliott__(~elliott@pool-108-51-101-42.washdc.fios.verizon.net)
2020-12-17 01:27:56 +0100cantstanya(~chatting@gateway/tor-sasl/cantstanya)
2020-12-17 01:28:07 +0100 <boxscape> so then someone had to invent cubical type theory?
2020-12-17 01:28:19 +0100 <dolio> Yes, that was invented by people who actually cared about computation.
2020-12-17 01:28:27 +0100is_null(~jpic@pdpc/supporter/professional/is-null) (Ping timeout: 265 seconds)
2020-12-17 01:29:59 +0100 <dolio> Being prior to automata isn't a very good excuse, really, because it generally seems that it's only been a problem since around the late 1800s or early 1900s, which is roughly the same time people started really getting into automata.
2020-12-17 01:29:59 +0100hexo-(~hexo@83.167.228.130)
2020-12-17 01:30:10 +0100 <boxscape> hm, interesting
2020-12-17 01:30:32 +0100 <boxscape> is the problem you're referring to basically having non-constructive proofs?
2020-12-17 01:30:37 +0100 <dolio> Yeah.
2020-12-17 01:31:22 +0100 <fuzzypixelz> why can't I use foldl on a tuple?
2020-12-17 01:31:36 +0100 <monochrom> You can. At least I can.
2020-12-17 01:31:37 +0100solonarv(~solonarv@astrasbourg-157-1-27-135.w90-40.abo.wanadoo.fr) (Ping timeout: 268 seconds)
2020-12-17 01:31:45 +0100 <chibi_> Say, what's the best way to program haskell on vim?
2020-12-17 01:31:50 +0100 <monochrom> So your problem is probably elsewhere.
2020-12-17 01:31:51 +0100 <fuzzypixelz> >foldl (*) 1 (2, 4, 6)
2020-12-17 01:32:01 +0100nbloomf(~nbloomf@2600:1700:ad14:3020:a8dc:3f5a:f8f1:dbd6)
2020-12-17 01:32:04 +0100 <boxscape> > foldl (*) 1 (2, 4, 6)
2020-12-17 01:32:06 +0100 <lambdabot> error:
2020-12-17 01:32:06 +0100 <lambdabot> • Could not deduce (Foldable ((,,) Integer Integer))
2020-12-17 01:32:06 +0100 <monochrom> Oh, that. Tuple != List
2020-12-17 01:32:07 +0100 <lambdabot> arising from a use of ‘foldl’
2020-12-17 01:32:14 +0100 <monochrom> Use [2, 4, 6]
2020-12-17 01:32:21 +0100 <fuzzypixelz> uhh
2020-12-17 01:32:27 +0100 <chibi_> All the guides I see online, even those published this same year are already outdated and don't with the latest version of ghc.
2020-12-17 01:32:37 +0100 <fuzzypixelz> that's the only way to get a product of the elements?
2020-12-17 01:33:07 +0100 <boxscape> fuzzypixelz basically, foldl is for containers that contain elements of a single type, but tuples can contain elements of different types
2020-12-17 01:33:09 +0100 <monochrom> No, 2*4*6 too
2020-12-17 01:33:47 +0100 <boxscape> fuzzypixelz so you can do it with any such container, e.g. Data.Set and Data.Vector
2020-12-17 01:33:52 +0100 <monochrom> I trust that you don't have a 10000-tuple, you merely have say a 4-tuple, so don't perfection-OCD it, just write "f (a,b,c,d) = a*b*c*d" and be done.
2020-12-17 01:34:10 +0100 <fuzzypixelz> I though the type system can infer that my tuple has elements of the same type
2020-12-17 01:34:16 +0100merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-12-17 01:34:28 +0100 <koz_> chibi_: I use ALE.
2020-12-17 01:34:31 +0100 <koz_> (and Neoformat)
2020-12-17 01:34:33 +0100 <monochrom> The type system can. But no function uses that information.
2020-12-17 01:34:36 +0100 <koz_> It does basically everything I care about.
2020-12-17 01:34:46 +0100elliott__(~elliott@pool-108-51-101-42.washdc.fios.verizon.net) (Quit: WeeChat 2.9)
2020-12-17 01:34:55 +0100 <koz_> It requires some config adjustment but it works pretty well.
2020-12-17 01:35:07 +0100__monty__(~toonn@unaffiliated/toonn) (Quit: leaving)
2020-12-17 01:35:16 +0100 <c_wraith> fuzzypixelz: that's the opposite of how it works. The type system sees that a tuple is allowed to have different types for each element, therefore things that process a tuple aren't allowed to assume they are the same.
2020-12-17 01:35:18 +0100is_null(~jpic@pdpc/supporter/professional/is-null)
2020-12-17 01:35:36 +0100 <boxscape> fuzzypixelz I think you could technically make a foldable instance for (a,a,a,a) (i.e. for a 4-tuple where every element has the same type), but I suppose it doesn't exist in the base library because it's not a typical use case
2020-12-17 01:35:44 +0100 <boxscape> or wait
2020-12-17 01:35:51 +0100 <boxscape> you could only with a newtype around it
2020-12-17 01:36:00 +0100johnw(~johnw@haskell/developer/johnw) (Quit: ZNC - http://znc.in)
2020-12-17 01:36:04 +0100 <dolio> No, Foldable's argument is * -> *.
2020-12-17 01:36:04 +0100elliott__(~elliott@pool-108-51-101-42.washdc.fios.verizon.net)
2020-12-17 01:36:17 +0100Kaeipi(~Kaiepi@47.54.252.148) (Remote host closed the connection)
2020-12-17 01:36:24 +0100 <boxscape> write but like `newtype Tuple4 a = Tuple4 (a,a,a,a)` should work
2020-12-17 01:36:26 +0100 <c_wraith> of course... libraries can do wacky things
2020-12-17 01:36:27 +0100 <c_wraith> > productOf each (2, 4, 7)
2020-12-17 01:36:29 +0100 <boxscape> s/write/right
2020-12-17 01:36:29 +0100 <lambdabot> 56
2020-12-17 01:36:31 +0100 <boxscape> -.-
2020-12-17 01:36:37 +0100Kaeipi(~Kaiepi@47.54.252.148)
2020-12-17 01:36:53 +0100nineonine(~nineonine@S01061cabc0b095f3.vf.shawcable.net)
2020-12-17 01:37:00 +0100koz_. o O ( Tuple4 = Fourple? )
2020-12-17 01:37:01 +0100 <monochrom> Oh, so you just need lens.
2020-12-17 01:37:10 +0100 <boxscape> koz_ quadruple
2020-12-17 01:37:16 +0100 <c_wraith> lens's Each class, in particular.
2020-12-17 01:37:19 +0100 <koz_> boxscape: I know, let me have my fun. :P
2020-12-17 01:37:23 +0100 <c_wraith> Which has instances for tuples of all the same type
2020-12-17 01:37:44 +0100 <boxscape> koz_ we had this discussion in ##adventofcode-spoilers the other day about thruple and triple
2020-12-17 01:38:04 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:d958:171:8e7f:eb0c) (Remote host closed the connection)
2020-12-17 01:38:17 +0100 <monochrom> Is thruple a Thursday tuple? :)
2020-12-17 01:38:18 +0100 <koz_> boxscape: Colour me unsurprised.
2020-12-17 01:38:29 +0100 <koz_> monochrom: Maybe in some households.
2020-12-17 01:39:12 +0100Entertainment(~entertain@104.246.132.210) (Ping timeout: 272 seconds)
2020-12-17 01:39:38 +0100merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 268 seconds)
2020-12-17 01:40:37 +0100 <chibi_> koz_: I'll try those two out, thanks
2020-12-17 01:40:47 +0100 <chibi_> Anything else you'd reccomend?
2020-12-17 01:40:52 +0100nineonin_(~nineonine@50.216.62.2) (Ping timeout: 268 seconds)
2020-12-17 01:41:15 +0100 <koz_> chibi_: I don't really need anything else. I use cabal-fmt and ormolu (cabal-fmt also needs some config twiddling, but not much) with Neoformat.
2020-12-17 01:41:34 +0100elfets(~elfets@ip-37-201-23-96.hsi13.unitymediagroup.de) (Quit: Leaving)
2020-12-17 01:41:50 +0100Noldorin(~noldorin@unaffiliated/noldorin)
2020-12-17 01:42:17 +0100 <chibi_> koz_: Gotcha, thankye.
2020-12-17 01:42:29 +0100 <dolio> I use hasktags. I think that's the only thing that isn't default vim.
2020-12-17 01:42:33 +0100 <koz_> You're welcome. If you want my config, I'm happy to share.
2020-12-17 01:42:52 +0100 <koz_> (I make use of local configs, but if you want all the same settings everywhere it'd work too)
2020-12-17 01:44:08 +0100plutoniix(~q@node-uqx.pool-125-24.dynamic.totinternet.net) (Quit: Leaving)
2020-12-17 01:44:18 +0100mounty(~mounty@2001:8000:2f59:0:e5bf:1b14:94d8:de8b) (Quit: Konversation terminated!)
2020-12-17 01:47:02 +0100cr3(~cr3@192-222-143-195.qc.cable.ebox.net) (Quit: leaving)
2020-12-17 01:47:02 +0100erolm_a(~erolm_a@62.19.36.64) (Read error: Connection reset by peer)
2020-12-17 01:47:46 +0100Vulfe(~vulfe@75-28-176-196.lightspeed.evtnil.sbcglobal.net)
2020-12-17 01:48:13 +0100mounty(~mounty@2001:8000:2f59:0:7042:17ea:748b:dc0c)
2020-12-17 01:49:47 +0100 <fuzzypixelz> Anyone want to give feedback/comments/criticism/remarks on my AOC day 1 solution? https://bpa.st/U74Q
2020-12-17 01:50:22 +0100 <fuzzypixelz> First time writing something in Haskell that isn't a "oh look at this fancy trick" example
2020-12-17 01:50:40 +0100 <fuzzypixelz> thanks in advance
2020-12-17 01:50:46 +0100 <fuzzypixelz> :)
2020-12-17 01:51:07 +0100da39a3ee5e6b4b0d(~da39a3ee5@2403:6200:8876:cecf:313a:ef0a:c021:651e)
2020-12-17 01:53:30 +0100merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-12-17 01:54:54 +0100 <ChaiTRex> fuzzypixelz: It seems like you might be able to reuse a number, like if you had 2 and 1009, you would find 2 + 1009 + 1009 == 2020.
2020-12-17 01:55:10 +0100 <ChaiTRex> I think `Num a` implies `Eq a`.
2020-12-17 01:55:39 +0100 <koala_man> fuzzypixelz: did you consider doing it in a single list comprehension, a la [ x*y*z | x <- list, y <- list, z <- list, x+y+z == 2020]?
2020-12-17 01:56:11 +0100 <ChaiTRex> No, I was wrong, `Num a` doesn't imply `Eq a`.
2020-12-17 01:56:36 +0100nbloomf(~nbloomf@2600:1700:ad14:3020:a8dc:3f5a:f8f1:dbd6) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2020-12-17 01:56:48 +0100 <fuzzypixelz> koala_man: I wanted to get the entries too, didn't realize I had no use for them until the end
2020-12-17 01:57:15 +0100 <fuzzypixelz> ChaiTRex: ghc genrated the type signatures
2020-12-17 01:57:42 +0100 <koala_man> could obviously have been (x,y,z) if you wanted them individually as well, and it would save an explicit filter
2020-12-17 01:58:30 +0100 <fuzzypixelz> well yeah, there is no need for the filering part as I can see
2020-12-17 01:58:31 +0100 <ChaiTRex> Oh, OK.
2020-12-17 01:59:20 +0100merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 256 seconds)
2020-12-17 01:59:43 +0100 <ridcully> i'd extract the read part (separate it from generating the combinations). also can you do it agnostic of generating combinations for 2 and 3 elements?
2020-12-17 02:00:30 +0100softwarm(4408f588@ip68-8-245-136.sd.sd.cox.net) (Ping timeout: 245 seconds)
2020-12-17 02:01:47 +0100royal_screwup21(52254809@gateway/web/cgi-irc/kiwiirc.com/ip.82.37.72.9)
2020-12-17 02:02:05 +0100 <fuzzypixelz> ridcully: I struggled to get the cartesian product part independent of the number of elements
2020-12-17 02:02:20 +0100 <fuzzypixelz> ridcully: but the rest should be okay
2020-12-17 02:03:13 +0100 <glguy> fuzzypixelz, I didn't generate the triples ahead of time so that I could prune some of them out as I went. Doing the read :: String -> Int ahead of time will keep you from duplicating that work once for each triple
2020-12-17 02:03:21 +0100 <ChaiTRex> fuzzypixelz: One way to eliminate a bunch of nested parentheses like `putStr (solution (lines contents))` is to use `.`s between each function and `$` in front of the argument, like `putStr . solution . lines $ content`.
2020-12-17 02:03:21 +0100 <ChaiTRex> Then it's sort of like an assembly line, where `content` goes through `lines`, then `solution`, then `putStr`.
2020-12-17 02:03:50 +0100 <chibi_> You can even not include the argument if you write the function out pointfree and just have a composition.
2020-12-17 02:03:54 +0100 <glguy> fuzzypixelz, your solution returns triples that can reuse the same element from the list multiple times
2020-12-17 02:03:59 +0100 <chibi_> Though that depends on what exactly you're doing.
2020-12-17 02:04:11 +0100stevenxl(uid133530@gateway/web/irccloud.com/x-dagdxzdthcnbrsqa) (Quit: Connection closed for inactivity)
2020-12-17 02:04:22 +0100nineonine(~nineonine@S01061cabc0b095f3.vf.shawcable.net) (Remote host closed the connection)
2020-12-17 02:04:23 +0100jpds(~jpds@gateway/tor-sasl/jpds) (Remote host closed the connection)
2020-12-17 02:04:38 +0100gehmehgeh(~ircuser1@gateway/tor-sasl/gehmehgeh) (Quit: Leaving)
2020-12-17 02:04:56 +0100nineonine(~nineonine@50.216.62.2)
2020-12-17 02:05:15 +0100 <glguy> https://github.com/glguy/advent2020/blob/master/execs/Day01.hs -- this solution doesn't bother generating the triples at all
2020-12-17 02:05:17 +0100jpds(~jpds@gateway/tor-sasl/jpds)
2020-12-17 02:06:08 +0100royal_screwup21(52254809@gateway/web/cgi-irc/kiwiirc.com/ip.82.37.72.9) (Ping timeout: 256 seconds)
2020-12-17 02:06:31 +0100elliott__(~elliott@pool-108-51-101-42.washdc.fios.verizon.net) (Quit: WeeChat 2.9)
2020-12-17 02:06:45 +0100cantstanya(~chatting@gateway/tor-sasl/cantstanya) (Remote host closed the connection)
2020-12-17 02:08:20 +0100mputz(~Thunderbi@dslb-088-064-063-125.088.064.pools.vodafone-ip.de) (Ping timeout: 272 seconds)
2020-12-17 02:08:21 +0100Tario(~Tario@201.192.165.173) (Read error: Connection reset by peer)
2020-12-17 02:08:23 +0100eruditass(uid248673@gateway/web/irccloud.com/x-mzencwftwbmswmrc)
2020-12-17 02:09:26 +0100Tario(~Tario@201.192.165.173)
2020-12-17 02:11:21 +0100cantstanya(~chatting@gateway/tor-sasl/cantstanya)
2020-12-17 02:12:01 +0100fuzzypixelz(~fuzzypixe@eth-west-pareq2-46-193-4-100.wb.wifirst.net) (Quit: fuzzypixelz)
2020-12-17 02:14:41 +0100Vulfe(~vulfe@75-28-176-196.lightspeed.evtnil.sbcglobal.net) (Remote host closed the connection)
2020-12-17 02:16:33 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:2075:545b:f2d1:a150)
2020-12-17 02:16:54 +0100lazyshrk(~lazyshrk@128.199.58.13) (Quit: ZNC 1.8.2 - https://znc.in)
2020-12-17 02:17:12 +0100alx741(~alx741@186.178.110.61) (Ping timeout: 272 seconds)
2020-12-17 02:17:34 +0100lazyshrk(~lazyshrk@128.199.58.13)
2020-12-17 02:19:08 +0100Vulfe_(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00)
2020-12-17 02:19:36 +0100ransom_(~c4264035@70-59-9-132.hlrn.qwest.net)
2020-12-17 02:20:18 +0100bitmagie(~Thunderbi@200116b8065b450029a1f7959c8665e8.dip.versatel-1u1.de)
2020-12-17 02:21:34 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:2075:545b:f2d1:a150) (Ping timeout: 268 seconds)
2020-12-17 02:22:28 +0100Merfont(~Kaiepi@47.54.252.148)
2020-12-17 02:22:48 +0100Kaeipi(~Kaiepi@47.54.252.148) (Remote host closed the connection)
2020-12-17 02:23:12 +0100joaj(~joaj@2001:818:e326:8200:5273:55b7:3a86:e6ca) (Ping timeout: 260 seconds)
2020-12-17 02:24:02 +0100Vulfe_(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00) (Ping timeout: 268 seconds)
2020-12-17 02:24:43 +0100nbloomf(~nbloomf@2600:1700:ad14:3020:a8dc:3f5a:f8f1:dbd6)
2020-12-17 02:24:50 +0100da39a3ee5e6b4b0d(~da39a3ee5@2403:6200:8876:cecf:313a:ef0a:c021:651e) (*.net *.split)
2020-12-17 02:24:50 +0100mounty(~mounty@2001:8000:2f59:0:7042:17ea:748b:dc0c) (*.net *.split)
2020-12-17 02:24:50 +0100Noldorin(~noldorin@unaffiliated/noldorin) (*.net *.split)
2020-12-17 02:24:51 +0100xff0x(~fox@2001:1a81:5229:f800:6bf4:ad68:acd0:bb77) (*.net *.split)
2020-12-17 02:24:51 +0100jespada(~jespada@90.254.245.49) (*.net *.split)
2020-12-17 02:24:51 +0100weechat_1(~mingc@2400:8902::f03c:91ff:feb7:8e82) (*.net *.split)
2020-12-17 02:24:51 +0100hnOsmium0001(uid453710@gateway/web/irccloud.com/x-esxplnjepcfjthew) (*.net *.split)
2020-12-17 02:24:51 +0100bitmapper(uid464869@gateway/web/irccloud.com/x-zzifphhwbirnbmhh) (*.net *.split)
2020-12-17 02:24:51 +0100amerigo(uid331857@gateway/web/irccloud.com/x-rgqindfclfxyvhfd) (*.net *.split)
2020-12-17 02:24:51 +0100fissureman(~quassel@c-73-163-84-25.hsd1.dc.comcast.net) (*.net *.split)
2020-12-17 02:24:51 +0100tabaqui(~tabaqui@2604:a880:800:c1::21b:3001) (*.net *.split)
2020-12-17 02:24:51 +0100DigitalKiwi(~kiwi@unaffiliated/digitalkiwi) (*.net *.split)
2020-12-17 02:24:51 +0100teddyc(theodorc@cassarossa.samfundet.no) (*.net *.split)
2020-12-17 02:24:51 +0100entropygain(levitate@unaffiliated/entropygain) (*.net *.split)
2020-12-17 02:24:51 +0100grol_(~quassel@2620:11e:1000:2:250:56ff:fea4:7) (*.net *.split)
2020-12-17 02:24:51 +0100NinjaTrappeur(~ninja@unaffiliated/ninjatrappeur) (*.net *.split)
2020-12-17 02:24:51 +0100emmanuel_erc(~user@2604:2000:1382:ce03::9af) (*.net *.split)
2020-12-17 02:24:51 +0100Raito_Bezarius(~Raito@unaffiliated/raito-bezarius/x-8764578) (*.net *.split)
2020-12-17 02:24:51 +0100benschza(~quassel@2604:1380:2000:cf00::1) (*.net *.split)
2020-12-17 02:24:51 +0100TheScoop(~TheScoop@unaffiliated/tryte) (*.net *.split)
2020-12-17 02:24:51 +0100lolmac(sid171216@gateway/web/irccloud.com/x-etsrrrsvkbkttjng) (*.net *.split)
2020-12-17 02:24:51 +0100betawaffle(sid2730@gateway/web/irccloud.com/x-nwsshpoaasjiiopc) (*.net *.split)
2020-12-17 02:24:52 +0100tinwood(~tinwood@general.default.akavanagh.uk0.bigv.io) (*.net *.split)
2020-12-17 02:24:52 +0100coeus(~coeus@p200300d0271c3b00114a6166d66724be.dip0.t-ipconnect.de) (*.net *.split)
2020-12-17 02:24:52 +0100mcfilib(sid302703@gateway/web/irccloud.com/x-pupkwpbkjgigplfb) (*.net *.split)
2020-12-17 02:24:52 +0100glowpelt(~myst@focks.pw) (*.net *.split)
2020-12-17 02:24:52 +0100nurupo(~nurupo.ga@unaffiliated/nurupo) (*.net *.split)
2020-12-17 02:24:52 +0100aizen_s(sid462968@gateway/web/irccloud.com/x-ighywpehicgiourx) (*.net *.split)
2020-12-17 02:24:52 +0100PoliticsII______(sid193551@gateway/web/irccloud.com/x-ifhtanwghthhvmbn) (*.net *.split)
2020-12-17 02:24:52 +0100benl23(sid284234@gateway/web/irccloud.com/x-hgqgnkygwwcwddwc) (*.net *.split)
2020-12-17 02:24:52 +0100yogani(sid42623@gateway/web/irccloud.com/x-xwocvhxoqauihzue) (*.net *.split)
2020-12-17 02:24:52 +0100ManiacTwister(~Twister@2a01:4f8:171:4de::40:2) (*.net *.split)
2020-12-17 02:24:52 +0100tnks(sid412124@gateway/web/irccloud.com/x-zbyszpuhbbhjdzks) (*.net *.split)
2020-12-17 02:24:52 +0100heyj(sid171370@gateway/web/irccloud.com/x-ofkusdzepocmjaiw) (*.net *.split)
2020-12-17 02:24:52 +0100typetetris(sid275937@gateway/web/irccloud.com/x-msdsoshziggpwxpy) (*.net *.split)
2020-12-17 02:24:52 +0100simony(sid226116@gateway/web/irccloud.com/x-keowsotekzgqfqdf) (*.net *.split)
2020-12-17 02:24:52 +0100dgpratt(sid193493@gateway/web/irccloud.com/x-eisigjveajsvarno) (*.net *.split)
2020-12-17 02:24:52 +0100moobar(sid171730@gateway/web/irccloud.com/x-svksvglonzzyzxxy) (*.net *.split)
2020-12-17 02:24:52 +0100ReinH__(sid179972@gateway/web/irccloud.com/x-ujhxicmjajcluchu) (*.net *.split)
2020-12-17 02:24:52 +0100jakalx(~jakalx@base.jakalx.net) (*.net *.split)
2020-12-17 02:24:52 +0100debugloop(~danieln@unaffiliated/debugloop) (*.net *.split)
2020-12-17 02:24:52 +0100krjst(~krjst@2604:a880:800:c1::16b:8001) (*.net *.split)
2020-12-17 02:24:52 +0100Ferdirand(~max@2001:4c78:2012:5000::2) (*.net *.split)
2020-12-17 02:24:52 +0100lightandlight(sid135476@gateway/web/irccloud.com/x-iidtschrmhcqrxgl) (*.net *.split)
2020-12-17 02:24:52 +0100J_Arcane(sid119274@gateway/web/irccloud.com/x-efprusjudjcoflyt) (*.net *.split)
2020-12-17 02:24:52 +0100rodlogic__(sid214676@gateway/web/irccloud.com/x-egfcshsulxcglqnw) (*.net *.split)
2020-12-17 02:24:52 +0100dsturnbull(sid347899@gateway/web/irccloud.com/x-xmzhvaiswgjcomqa) (*.net *.split)
2020-12-17 02:24:52 +0100topos(sid467876@gateway/web/irccloud.com/x-mqpmkdyaexkjdklr) (*.net *.split)
2020-12-17 02:24:53 +0100jackdk(sid373013@gateway/web/irccloud.com/x-arnfpemfesqxinsb) (*.net *.split)
2020-12-17 02:24:53 +0100yorick(~yorick@oftn/oswg-member/yorick) (*.net *.split)
2020-12-17 02:24:53 +0100i7c(8Tki2L7DF5@unaffiliated/i7c) (*.net *.split)
2020-12-17 02:24:53 +0100miklcct(quasselcor@2001:19f0:7001:5ad:5400:2ff:feb6:50d7) (*.net *.split)
2020-12-17 02:24:53 +0100zyeri(zyeri@tilde.team/users/zyeri) (*.net *.split)
2020-12-17 02:24:53 +0100infinisil(~infinisil@NixOS/user/infinisil) (*.net *.split)
2020-12-17 02:24:53 +0100denucat(teqwve@2001:bc8:28d6::2) (*.net *.split)
2020-12-17 02:24:53 +0100dumptruckman(dumptruckm@2600:3c02::f03c:91ff:fe6e:2cfd) (*.net *.split)
2020-12-17 02:24:53 +0100ego(~ego@parallaxcorporation.xyz) (*.net *.split)
2020-12-17 02:24:53 +0100bspar(~bspar@2604:a880:0:1010::776:e001) (*.net *.split)
2020-12-17 02:24:53 +0100idupree(~quassel@2604:a880:400:d0::9bb:2001) (*.net *.split)
2020-12-17 02:24:53 +0100lpsmith(~lpsmith@unaffiliated/lpsmith) (*.net *.split)
2020-12-17 02:24:53 +0100Forkk(forkk@2600:3c00::f03c:91ff:fe84:de4d) (*.net *.split)
2020-12-17 02:24:53 +0100drdo(~drdo@overlord0.drdo.eu) (*.net *.split)
2020-12-17 02:24:53 +0100riatre(~quassel@2001:310:6000:f::5198:1) (*.net *.split)
2020-12-17 02:24:53 +0100bonz060(~quassel@2001:bc8:47a4:a23::1) (*.net *.split)
2020-12-17 02:24:53 +0100PHO_(~pho@akari.cielonegro.org) (*.net *.split)
2020-12-17 02:24:53 +0100solarus(~solarus@2a03:b0c0:2:d0::48:7001) (*.net *.split)
2020-12-17 02:24:53 +0100xcin(~x@159.203.132.140) (*.net *.split)
2020-12-17 02:24:53 +0100sim642(~simmo@unaffiliated/sim642) (*.net *.split)
2020-12-17 02:24:53 +0100xnyhps(~xnyhps@2a02:2770:3:0:216:3eff:fe67:3288) (*.net *.split)
2020-12-17 02:24:53 +0100tomjaguarpaw(~tom@li367-225.members.linode.com) (*.net *.split)
2020-12-17 02:25:09 +0100nurupo(~nurupo.ga@unaffiliated/nurupo)
2020-12-17 02:25:58 +0100sakirious(~sakirious@c-71-197-191-137.hsd1.wa.comcast.net) (Quit: The Lounge - https://thelounge.chat)
2020-12-17 02:27:07 +0100dredozub-(~dredozubo@37.139.21.214) (Ping timeout: 246 seconds)
2020-12-17 02:27:07 +0100Jesin(~Jesin@pool-72-66-101-18.washdc.fios.verizon.net) (Ping timeout: 246 seconds)
2020-12-17 02:27:07 +0100adamCS(~adamCS@ec2-34-207-160-255.compute-1.amazonaws.com) (Ping timeout: 246 seconds)
2020-12-17 02:27:16 +0100is_null(~jpic@pdpc/supporter/professional/is-null) (Ping timeout: 252 seconds)
2020-12-17 02:28:36 +0100melosense(~melosense@4e69b241.skybroadband.com) (Ping timeout: 240 seconds)
2020-12-17 02:29:27 +0100Kronic(~Kronic___@84.203.96.46) (Quit: Leaving)
2020-12-17 02:29:50 +0100alx741(~alx741@186.178.110.75)
2020-12-17 02:30:07 +0100adamCS(~adamCS@ec2-34-207-160-255.compute-1.amazonaws.com)
2020-12-17 02:30:12 +0100da39a3ee5e6b4b0d(~da39a3ee5@2403:6200:8876:cecf:313a:ef0a:c021:651e)
2020-12-17 02:30:12 +0100mounty(~mounty@2001:8000:2f59:0:7042:17ea:748b:dc0c)
2020-12-17 02:30:12 +0100Noldorin(~noldorin@unaffiliated/noldorin)
2020-12-17 02:30:12 +0100xff0x(~fox@2001:1a81:5229:f800:6bf4:ad68:acd0:bb77)
2020-12-17 02:30:12 +0100jespada(~jespada@90.254.245.49)
2020-12-17 02:30:12 +0100weechat_1(~mingc@2400:8902::f03c:91ff:feb7:8e82)
2020-12-17 02:30:12 +0100hnOsmium0001(uid453710@gateway/web/irccloud.com/x-esxplnjepcfjthew)
2020-12-17 02:30:12 +0100bitmapper(uid464869@gateway/web/irccloud.com/x-zzifphhwbirnbmhh)
2020-12-17 02:30:12 +0100amerigo(uid331857@gateway/web/irccloud.com/x-rgqindfclfxyvhfd)
2020-12-17 02:30:12 +0100fissureman(~quassel@c-73-163-84-25.hsd1.dc.comcast.net)
2020-12-17 02:30:12 +0100tabaqui(~tabaqui@2604:a880:800:c1::21b:3001)
2020-12-17 02:30:12 +0100DigitalKiwi(~kiwi@unaffiliated/digitalkiwi)
2020-12-17 02:30:12 +0100teddyc(theodorc@cassarossa.samfundet.no)
2020-12-17 02:30:12 +0100entropygain(levitate@unaffiliated/entropygain)
2020-12-17 02:30:12 +0100grol_(~quassel@2620:11e:1000:2:250:56ff:fea4:7)
2020-12-17 02:30:12 +0100NinjaTrappeur(~ninja@unaffiliated/ninjatrappeur)
2020-12-17 02:30:12 +0100emmanuel_erc(~user@2604:2000:1382:ce03::9af)
2020-12-17 02:30:12 +0100Raito_Bezarius(~Raito@unaffiliated/raito-bezarius/x-8764578)
2020-12-17 02:30:12 +0100benschza(~quassel@2604:1380:2000:cf00::1)
2020-12-17 02:30:12 +0100TheScoop(~TheScoop@unaffiliated/tryte)
2020-12-17 02:30:12 +0100lolmac(sid171216@gateway/web/irccloud.com/x-etsrrrsvkbkttjng)
2020-12-17 02:30:12 +0100betawaffle(sid2730@gateway/web/irccloud.com/x-nwsshpoaasjiiopc)
2020-12-17 02:30:12 +0100tinwood(~tinwood@general.default.akavanagh.uk0.bigv.io)
2020-12-17 02:30:12 +0100coeus(~coeus@p200300d0271c3b00114a6166d66724be.dip0.t-ipconnect.de)
2020-12-17 02:30:12 +0100mcfilib(sid302703@gateway/web/irccloud.com/x-pupkwpbkjgigplfb)
2020-12-17 02:30:12 +0100glowpelt(~myst@focks.pw)
2020-12-17 02:30:12 +0100aizen_s(sid462968@gateway/web/irccloud.com/x-ighywpehicgiourx)
2020-12-17 02:30:12 +0100PoliticsII______(sid193551@gateway/web/irccloud.com/x-ifhtanwghthhvmbn)
2020-12-17 02:30:12 +0100benl23(sid284234@gateway/web/irccloud.com/x-hgqgnkygwwcwddwc)
2020-12-17 02:30:12 +0100yogani(sid42623@gateway/web/irccloud.com/x-xwocvhxoqauihzue)
2020-12-17 02:30:12 +0100ManiacTwister(~Twister@2a01:4f8:171:4de::40:2)
2020-12-17 02:30:12 +0100tnks(sid412124@gateway/web/irccloud.com/x-zbyszpuhbbhjdzks)
2020-12-17 02:30:12 +0100heyj(sid171370@gateway/web/irccloud.com/x-ofkusdzepocmjaiw)
2020-12-17 02:30:12 +0100typetetris(sid275937@gateway/web/irccloud.com/x-msdsoshziggpwxpy)
2020-12-17 02:30:12 +0100simony(sid226116@gateway/web/irccloud.com/x-keowsotekzgqfqdf)
2020-12-17 02:30:12 +0100dgpratt(sid193493@gateway/web/irccloud.com/x-eisigjveajsvarno)
2020-12-17 02:30:12 +0100moobar(sid171730@gateway/web/irccloud.com/x-svksvglonzzyzxxy)
2020-12-17 02:30:12 +0100ReinH__(sid179972@gateway/web/irccloud.com/x-ujhxicmjajcluchu)
2020-12-17 02:30:12 +0100jakalx(~jakalx@base.jakalx.net)
2020-12-17 02:30:12 +0100debugloop(~danieln@unaffiliated/debugloop)
2020-12-17 02:30:12 +0100krjst(~krjst@2604:a880:800:c1::16b:8001)
2020-12-17 02:30:12 +0100Ferdirand(~max@2001:4c78:2012:5000::2)
2020-12-17 02:30:12 +0100lightandlight(sid135476@gateway/web/irccloud.com/x-iidtschrmhcqrxgl)
2020-12-17 02:30:12 +0100J_Arcane(sid119274@gateway/web/irccloud.com/x-efprusjudjcoflyt)
2020-12-17 02:30:12 +0100rodlogic__(sid214676@gateway/web/irccloud.com/x-egfcshsulxcglqnw)
2020-12-17 02:30:12 +0100dsturnbull(sid347899@gateway/web/irccloud.com/x-xmzhvaiswgjcomqa)
2020-12-17 02:30:12 +0100topos(sid467876@gateway/web/irccloud.com/x-mqpmkdyaexkjdklr)
2020-12-17 02:30:12 +0100jackdk(sid373013@gateway/web/irccloud.com/x-arnfpemfesqxinsb)
2020-12-17 02:30:12 +0100i7c(8Tki2L7DF5@unaffiliated/i7c)
2020-12-17 02:30:12 +0100yorick(~yorick@oftn/oswg-member/yorick)
2020-12-17 02:30:12 +0100miklcct(quasselcor@2001:19f0:7001:5ad:5400:2ff:feb6:50d7)
2020-12-17 02:30:12 +0100zyeri(zyeri@tilde.team/users/zyeri)
2020-12-17 02:30:12 +0100infinisil(~infinisil@NixOS/user/infinisil)
2020-12-17 02:30:12 +0100denucat(teqwve@2001:bc8:28d6::2)
2020-12-17 02:30:12 +0100dumptruckman(dumptruckm@2600:3c02::f03c:91ff:fe6e:2cfd)
2020-12-17 02:30:12 +0100ego(~ego@parallaxcorporation.xyz)
2020-12-17 02:30:12 +0100bspar(~bspar@2604:a880:0:1010::776:e001)
2020-12-17 02:30:12 +0100idupree(~quassel@2604:a880:400:d0::9bb:2001)
2020-12-17 02:30:12 +0100lpsmith(~lpsmith@unaffiliated/lpsmith)
2020-12-17 02:30:12 +0100Forkk(forkk@2600:3c00::f03c:91ff:fe84:de4d)
2020-12-17 02:30:12 +0100drdo(~drdo@overlord0.drdo.eu)
2020-12-17 02:30:12 +0100sim642(~simmo@unaffiliated/sim642)
2020-12-17 02:30:12 +0100riatre(~quassel@2001:310:6000:f::5198:1)
2020-12-17 02:30:12 +0100bonz060(~quassel@2001:bc8:47a4:a23::1)
2020-12-17 02:30:12 +0100PHO_(~pho@akari.cielonegro.org)
2020-12-17 02:30:12 +0100solarus(~solarus@2a03:b0c0:2:d0::48:7001)
2020-12-17 02:30:12 +0100xcin(~x@159.203.132.140)
2020-12-17 02:30:12 +0100xnyhps(~xnyhps@2a02:2770:3:0:216:3eff:fe67:3288)
2020-12-17 02:30:12 +0100tomjaguarpaw(~tom@li367-225.members.linode.com)
2020-12-17 02:30:15 +0100dredozubov(~dredozubo@37.139.21.214)
2020-12-17 02:30:59 +0100miklcct(quasselcor@2001:19f0:7001:5ad:5400:2ff:feb6:50d7) (Max SendQ exceeded)
2020-12-17 02:31:10 +0100miklcct(quasselcor@2001:19f0:7001:5ad:5400:2ff:feb6:50d7)
2020-12-17 02:31:26 +0100columbarius(~columbari@mue-88-130-54-048.dsl.tropolys.de) (Ping timeout: 268 seconds)
2020-12-17 02:33:22 +0100betawaffle(sid2730@gateway/web/irccloud.com/x-nwsshpoaasjiiopc) (Ping timeout: 249 seconds)
2020-12-17 02:33:23 +0100aizen_s(sid462968@gateway/web/irccloud.com/x-ighywpehicgiourx) (Ping timeout: 249 seconds)
2020-12-17 02:33:24 +0100merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-12-17 02:33:27 +0100columbarius(~columbari@i5E86B369.versanet.de)
2020-12-17 02:33:57 +0100hnOsmium0001(uid453710@gateway/web/irccloud.com/x-esxplnjepcfjthew) (Ping timeout: 260 seconds)
2020-12-17 02:33:58 +0100amerigo(uid331857@gateway/web/irccloud.com/x-rgqindfclfxyvhfd) (Ping timeout: 260 seconds)
2020-12-17 02:33:58 +0100lolmac(sid171216@gateway/web/irccloud.com/x-etsrrrsvkbkttjng) (Ping timeout: 260 seconds)
2020-12-17 02:34:04 +0100betawaffle(sid2730@gateway/web/irccloud.com/x-iqipatfmsyxtpnsb)
2020-12-17 02:34:09 +0100aizen_s(sid462968@gateway/web/irccloud.com/x-lsbqjsnyhdhmooyk)
2020-12-17 02:35:52 +0100lolmac(sid171216@gateway/web/irccloud.com/x-espdqhkcxsbkntws)
2020-12-17 02:36:01 +0100amerigo(uid331857@gateway/web/irccloud.com/x-dofzufotyixjvskt)
2020-12-17 02:36:37 +0100mimi_vx(~mimi@2a01:490:16:1026:d923:3519:de60:eb74) (Ping timeout: 260 seconds)
2020-12-17 02:36:56 +0100hnOsmium0001(uid453710@gateway/web/irccloud.com/x-zxxiepmgnexcriai)
2020-12-17 02:37:12 +0100nhs(~nhs@c-67-180-177-103.hsd1.ca.comcast.net) (Read error: Connection reset by peer)
2020-12-17 02:37:25 +0100Rudd0(~Rudd0@185.189.115.108) (Ping timeout: 240 seconds)
2020-12-17 02:38:16 +0100Tene(~tene@poipu/supporter/slacker/tene) (Ping timeout: 260 seconds)
2020-12-17 02:38:55 +0100Tuplanolla(~Tuplanoll@91-159-68-239.elisa-laajakaista.fi) (Quit: Leaving.)
2020-12-17 02:39:02 +0100ByronJohnson(~bairyn@unaffiliated/bob0) (Ping timeout: 264 seconds)
2020-12-17 02:39:18 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00)
2020-12-17 02:43:52 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00) (Ping timeout: 260 seconds)
2020-12-17 02:44:26 +0100ByronJohnson(~bairyn@unaffiliated/bob0)
2020-12-17 02:44:44 +0100Tene(~tene@poipu/supporter/slacker/tene)
2020-12-17 02:49:40 +0100Lord_of_Life_(~Lord@unaffiliated/lord-of-life/x-0885362)
2020-12-17 02:51:05 +0100Lord_of_Life(~Lord@unaffiliated/lord-of-life/x-0885362) (Ping timeout: 240 seconds)
2020-12-17 02:51:05 +0100Lord_of_Life_Lord_of_Life
2020-12-17 02:56:38 +0100mimi_vx(~mimi@2a01:490:16:1026:d923:3519:de60:eb74)
2020-12-17 02:59:44 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00)
2020-12-17 03:01:23 +0100mimi_vx(~mimi@2a01:490:16:1026:d923:3519:de60:eb74) (Ping timeout: 260 seconds)
2020-12-17 03:01:26 +0100star_cloud(~star_clou@ec2-34-220-44-120.us-west-2.compute.amazonaws.com)
2020-12-17 03:03:12 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00) (Remote host closed the connection)
2020-12-17 03:03:13 +0100brodie_(~brodie@207.53.253.137)
2020-12-17 03:03:45 +0100stux|RC-only(stux2@grid9.quadspeedi.net) (Read error: Connection reset by peer)
2020-12-17 03:04:05 +0100is_null(~jpic@pdpc/supporter/professional/is-null)
2020-12-17 03:04:08 +0100Vulfe_(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00)
2020-12-17 03:04:22 +0100joeyh(~joeyh@kitenet.net) (Quit: ZNC 1.8.1+deb1 - https://znc.in)
2020-12-17 03:04:29 +0100gabiruh(~gabiruh@vps19177.publiccloud.com.br) (Quit: ZNC 1.7.5 - https://znc.in)
2020-12-17 03:04:32 +0100demiurge(e@freenode/staff/spy.edk) (Quit: edk)
2020-12-17 03:04:49 +0100gabiruh(~gabiruh@vps19177.publiccloud.com.br)
2020-12-17 03:05:22 +0100joeyh_(joeyh@kitenet.net)
2020-12-17 03:05:30 +0100stux|RC-only(stux2@grid9.quadspeedi.net)
2020-12-17 03:07:22 +0100merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 246 seconds)
2020-12-17 03:07:49 +0100ddellacosta(dd@gateway/vpn/mullvad/ddellacosta) (Ping timeout: 260 seconds)
2020-12-17 03:08:17 +0100tinwood(~tinwood@general.default.akavanagh.uk0.bigv.io) (Remote host closed the connection)
2020-12-17 03:09:32 +0100xff0x(~fox@2001:1a81:5229:f800:6bf4:ad68:acd0:bb77) (Ping timeout: 260 seconds)
2020-12-17 03:11:18 +0100xff0x(~fox@2001:1a81:5260:ab00:b677:a698:4a99:d811)
2020-12-17 03:11:22 +0100tinwood(~tinwood@general.default.akavanagh.uk0.bigv.io)
2020-12-17 03:14:31 +0100wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Quit: leaving)
2020-12-17 03:15:11 +0100mimi_vx(~mimi@2a01:490:16:1026:d923:3519:de60:eb74)
2020-12-17 03:21:36 +0100wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
2020-12-17 03:24:49 +0100xelxebar(~xelxebar@gateway/tor-sasl/xelxebar)
2020-12-17 03:25:34 +0100edk_(e@freenode/staff/spy.edk)
2020-12-17 03:25:53 +0100lep-delete(~lep@94.31.80.94) (Ping timeout: 260 seconds)
2020-12-17 03:27:55 +0100lep-delete(~lep@94.31.80.94)
2020-12-17 03:30:07 +0100Noldorin(~noldorin@unaffiliated/noldorin) (Quit: Textual IRC Client: www.textualapp.com)
2020-12-17 03:31:08 +0100jespada(~jespada@90.254.245.49) (Ping timeout: 260 seconds)
2020-12-17 03:32:34 +0100raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) (Ping timeout: 272 seconds)
2020-12-17 03:32:57 +0100lep-deletetest
2020-12-17 03:33:27 +0100testGuest18945
2020-12-17 03:33:34 +0100jespada(~jespada@90.254.245.49)
2020-12-17 03:35:50 +0100hNoob(6b80d5f1@107-128-213-241.lightspeed.sntcca.sbcglobal.net)
2020-12-17 03:37:07 +0100ransom_(~c4264035@70-59-9-132.hlrn.qwest.net) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2020-12-17 03:37:45 +0100boxscape(54a35b08@gateway/web/cgi-irc/kiwiirc.com/ip.84.163.91.8) (Ping timeout: 240 seconds)
2020-12-17 03:39:12 +0100 <hNoob> I just installed stack for the first time (and did a 'stack update' and 'stack upgrade' just for good measure). When I attempt to install ghc-mod (stack install ghc-mod) it fails because ghc-mod (it decided to get ghc-mod-5.8.0.0) has dependency issues with a bunch of things including Cabal, base, etc. Any insights would be appreciated.
2020-12-17 03:41:10 +0100amerigo(uid331857@gateway/web/irccloud.com/x-dofzufotyixjvskt) (Quit: Connection closed for inactivity)
2020-12-17 03:41:44 +0100thc202(~thc202@unaffiliated/thc202) (Ping timeout: 268 seconds)
2020-12-17 03:42:03 +0100Unhammer(~Unhammer@gateway/tor-sasl/unhammer) (Ping timeout: 240 seconds)
2020-12-17 03:42:39 +0100christo(~chris@81.96.113.213) (Remote host closed the connection)
2020-12-17 03:42:39 +0100merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-12-17 03:43:20 +0100christo(~chris@81.96.113.213)
2020-12-17 03:43:42 +0100columbarius(~columbari@i5E86B369.versanet.de) (Ping timeout: 260 seconds)
2020-12-17 03:45:58 +0100 <chibi_> hNoob: ghc-mod is deprecated
2020-12-17 03:46:33 +0100 <hNoob> Thank you chibi_
2020-12-17 03:47:04 +0100nbloomf(~nbloomf@2600:1700:ad14:3020:a8dc:3f5a:f8f1:dbd6) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2020-12-17 03:47:54 +0100merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 268 seconds)
2020-12-17 03:49:50 +0100Guest18945(~lep@94.31.80.94) (Ping timeout: 256 seconds)
2020-12-17 03:53:41 +0100nbloomf(~nbloomf@2600:1700:ad14:3020:a8dc:3f5a:f8f1:dbd6)
2020-12-17 03:54:04 +0100renzhi(~renzhi@2607:fa49:6500:ac00::bfed)
2020-12-17 03:58:03 +0100columbarius(~columbari@87.123.198.173)
2020-12-17 03:59:50 +0100cosimone(~cosimone@5.171.25.104) (Quit: cosimone)
2020-12-17 04:02:38 +0100Unhammer(~Unhammer@gateway/tor-sasl/unhammer)
2020-12-17 04:03:19 +0100jmchael_(~jmchael@87.112.46.194) (Ping timeout: 268 seconds)
2020-12-17 04:08:07 +0100cheater(~user@unaffiliated/cheater) (Remote host closed the connection)
2020-12-17 04:09:04 +0100da39a3ee5e6b4b0d(~da39a3ee5@2403:6200:8876:cecf:313a:ef0a:c021:651e) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2020-12-17 04:11:00 +0100cheater(~user@unaffiliated/cheater)
2020-12-17 04:11:29 +0100da39a3ee5e6b4b0d(~da39a3ee5@2403:6200:8876:cecf:bc4d:596d:63fe:f2dd)
2020-12-17 04:12:31 +0100bitmagie(~Thunderbi@200116b8065b450029a1f7959c8665e8.dip.versatel-1u1.de) (Quit: bitmagie)
2020-12-17 04:14:12 +0100ransom_(~c4264035@70-59-9-132.hlrn.qwest.net)
2020-12-17 04:16:47 +0100mimi_vx(~mimi@2a01:490:16:1026:d923:3519:de60:eb74) (Ping timeout: 272 seconds)
2020-12-17 04:17:17 +0100urodna(~urodna@unaffiliated/urodna) (Quit: urodna)
2020-12-17 04:17:24 +0100guest1216(~user@49.5.6.87)
2020-12-17 04:18:42 +0100lep-delete(~lep@94.31.81.93)
2020-12-17 04:18:54 +0100 <guest1216> if there're two parser, how to concat them? I mean let the second parser work on the result of the first one
2020-12-17 04:19:00 +0100ransom_(~c4264035@70-59-9-132.hlrn.qwest.net) (Quit: Textual IRC Client: www.textualapp.com)
2020-12-17 04:19:37 +0100 <guest1216> removeSpace = spaces *> many (anyChar <* spaces)
2020-12-17 04:19:45 +0100 <guest1216> p8 :: Parser [String]
2020-12-17 04:20:19 +0100 <guest1216> p8 = {do; x <- many letter; char '='; y <- many letter; return [x,y]}
2020-12-17 04:20:46 +0100theDon(~td@94.134.91.88) (Ping timeout: 256 seconds)
2020-12-17 04:20:58 +0100 <dsal> You can push the result back into the parser state with megaparsec, but it's a bit weird. Why not just do the right thing the first time?
2020-12-17 04:20:58 +0100Deide(~Deide@217.155.19.23) (Quit: Seeee yaaaa)
2020-12-17 04:21:08 +0100 <guest1216> parse (removeSpace *> p8) "" "ab = cd" /= Right ["ab","cd"]
2020-12-17 04:21:17 +0100da39a3ee5e6b4b0d(~da39a3ee5@2403:6200:8876:cecf:bc4d:596d:63fe:f2dd) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2020-12-17 04:21:55 +0100 <guest1216> (Right (parse p8 "")) <*> (parse removeSpaces "" " a = b") == Right (Right ["a","b"])
2020-12-17 04:22:02 +0100 <guest1216> but this is ugly...
2020-12-17 04:22:16 +0100theDon(~td@muedsl-82-207-238-174.citykom.de)
2020-12-17 04:22:18 +0100cheater(~user@unaffiliated/cheater) (Remote host closed the connection)
2020-12-17 04:22:22 +0100 <guest1216> dsal: more specific?
2020-12-17 04:22:26 +0100wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Quit: leaving)
2020-12-17 04:22:42 +0100merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-12-17 04:23:21 +0100 <dsal> If you want space consumed lexemes, that's lexeme here: https://hackage.haskell.org/package/megaparsec-9.0.1/docs/Text-Megaparsec-Char-Lexer.html
2020-12-17 04:23:30 +0100da39a3ee5e6b4b0d(~da39a3ee5@2403:6200:8876:cecf:bc4d:596d:63fe:f2dd)
2020-12-17 04:23:36 +0100 <jle`> looks like you're talking about mutli-stage parsing
2020-12-17 04:24:04 +0100 <guest1216> jle`: remove spaces first, then split by '=' into a list
2020-12-17 04:24:05 +0100lagothrixGuest64420
2020-12-17 04:24:05 +0100xirhtogal(~lagothrix@unaffiliated/lagothrix)
2020-12-17 04:24:05 +0100Guest64420(~lagothrix@unaffiliated/lagothrix) (Killed (karatkievich.freenode.net (Nickname regained by services)))
2020-12-17 04:24:05 +0100xirhtogallagothrix
2020-12-17 04:24:05 +0100 <jle`> but working with parser combinators, it is sort of designed to not require it if you are able to phrase your main problem in a parser combinatory way
2020-12-17 04:24:19 +0100 <jle`> yes, that's what i mean. that's multi-pass/multi-stage parsing
2020-12-17 04:24:45 +0100 <jle`> but that's not really how you're "supposed" to use parser combinators, in the general wisdom
2020-12-17 04:24:52 +0100 <jle`> these days it's considered unidiomatic
2020-12-17 04:24:52 +0100 <dsal> for that exact expression, a list seems weird. I'd just do something like `liftA2 (,) (lexeme word <* lexeme "=") (lexeme word)`
2020-12-17 04:25:21 +0100Jesin(~Jesin@pool-72-66-101-18.washdc.fios.verizon.net)
2020-12-17 04:25:32 +0100m0rphism(~m0rphism@HSI-KBW-085-216-104-059.hsi.kabelbw.de) (Ping timeout: 256 seconds)
2020-12-17 04:26:15 +0100lep-deleteGuest18945
2020-12-17 04:27:18 +0100cheater(~user@unaffiliated/cheater)
2020-12-17 04:31:24 +0100dax(dax@bitbot/dax) (Quit: brb)
2020-12-17 04:31:51 +0100dax(dax@bitbot/dax)
2020-12-17 04:32:07 +0100 <guest1216> p8 = {do; spaces; x <- many letter; spaces; char '='; spaces; y <- many letter; spaces; return [x,y]}
2020-12-17 04:32:19 +0100 <guest1216> this one can do that
2020-12-17 04:32:43 +0100 <jle`> right, there is usualyl a way you can rephrase your program to not require multi stage parsing
2020-12-17 04:33:06 +0100 <dsal> A list feels pretty wrong there, still. Why would you use a list of two items vs. a tuple?
2020-12-17 04:33:06 +0100Jeanne-Kamikaze(~Jeanne-Ka@66.115.189.229)
2020-12-17 04:33:50 +0100 <RENNNN> what's the easiest to use implementation of dikstra?
2020-12-17 04:33:52 +0100 <dsal> `lexeme` is basically `spaces *> x <* spaces` so you can just drop it in places where spaces are optional.
2020-12-17 04:33:55 +0100 <RENNNN> on cyclic graph
2020-12-17 04:34:16 +0100johnw(~johnw@haskell/developer/johnw)
2020-12-17 04:34:56 +0100 <guest1216> dsal: ok, I will change it to a tuple
2020-12-17 04:36:04 +0100 <dsal> guest1216: tuple also means you can do the liftA2 thing there if you want. e.g., `p8 = liftA2 (,) (lexeme word <* lexeme "=") (lexeme word) where word = many letter`
2020-12-17 04:36:11 +0100drbean(~drbean@TC210-63-209-202.static.apol.com.tw)
2020-12-17 04:38:37 +0100 <guest1216> dsal: what's x in `spaces *> x <* spaces`?
2020-12-17 04:38:45 +0100 <dsal> x is the parser you want between the spaces.
2020-12-17 04:39:26 +0100 <guest1216> parse (spaces *> many letter <* spaces) "" "a = b" == Right 'a'
2020-12-17 04:40:03 +0100 <guest1216> dsal: should I use many anyChar?
2020-12-17 04:40:14 +0100 <dsal> Yes, but you can name `spaces *> x <* spaces` `lexeme x = spaces *> x <* spaces` and then just type `lexeme (many letter)` (or use the one in Text.Megaparsec.Char.Lexer
2020-12-17 04:40:15 +0100 <dsal> )
2020-12-17 04:40:51 +0100 <dsal> `many anychar ` might not do what you want. There are combinators like `manyTill`, but `many anyChar` will basically eat the rest of your input.
2020-12-17 04:40:56 +0100 <guest1216> dsal: I'd like to try Text.ParserCombinators.Parsec first
2020-12-17 04:41:06 +0100 <dsal> I usually use something like `satisfy`
2020-12-17 04:41:59 +0100cheater(~user@unaffiliated/cheater) (Read error: Connection reset by peer)
2020-12-17 04:42:25 +0100pfurla(~pfurla@ool-182ed2e2.dyn.optonline.net) (Ping timeout: 240 seconds)
2020-12-17 04:42:43 +0100 <dsal> Oh, I just looked at the source. lexeme is actually: `lexeme spc p = p <* spc`
2020-12-17 04:42:46 +0100 <MarcelineVQ> idk if it's typical to consume the following spaces when lexing
2020-12-17 04:42:57 +0100 <MarcelineVQ> oh huh :>
2020-12-17 04:43:26 +0100pfurla(~pfurla@216.151.180.208)
2020-12-17 04:43:29 +0100 <dsal> It makes more sense to me to consume from the left. I guess that's worth knowing.
2020-12-17 04:43:50 +0100MOSCOS(~MOSCOS@122.54.107.175) (Remote host closed the connection)
2020-12-17 04:43:55 +0100 <dsal> I remember in the past getting confused and just shotgunning lexeme all over my code.
2020-12-17 04:44:09 +0100cheater(~user@unaffiliated/cheater)
2020-12-17 04:44:16 +0100MOSCOS(~MOSCOS@122.54.107.175)
2020-12-17 04:48:07 +0100cheater(~user@unaffiliated/cheater) (Read error: Connection reset by peer)
2020-12-17 04:48:32 +0100 <dsal> I still find Haskell easier to read than English. If I'd've read that code a long time ago, I'd've been less confused. The *parameter* doc says it's for the whitespace after the lexeme, but function doc doesn't make that obvious.
2020-12-17 04:49:31 +0100 <guest1216> dsal: that lexeme is only in megaparsec? not in pasec?
2020-12-17 04:50:02 +0100 <dsal> I don't know that anyone's used parsec in a long time, but that's the actual code for it there, so you can make your own. :)
2020-12-17 04:50:36 +0100Sheilong(uid293653@gateway/web/irccloud.com/x-sqydmizngzbsyouz) ()
2020-12-17 04:50:48 +0100 <guest1216> haha, but parsec comes with ghc, so I like to try the old one first then others
2020-12-17 04:51:48 +0100cheater(~user@unaffiliated/cheater)
2020-12-17 04:52:23 +0100cheater(~user@unaffiliated/cheater) (Client Quit)
2020-12-17 04:52:44 +0100 <monochrom> MarcelineVQ: There is a convention that each parser holds the invariant "consume spaces after the stuff I need", therefore "when I start I can assume no space before the stuff I need". There is a global do-once "slurp beginning spaces" to kickstart the invariant.
2020-12-17 04:53:20 +0100 <monochrom> Basically parsec's Token module started that convention.
2020-12-17 04:55:13 +0100 <monochrom> I guess ReadS started that convention actually.
2020-12-17 04:56:36 +0100merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 240 seconds)
2020-12-17 04:56:37 +0100 <monochrom> Err no, ReadS didn't. (Or, Prelude.lex didn't.)
2020-12-17 04:57:46 +0100hexfive(~hexfive@50-47-142-195.evrt.wa.frontiernet.net)
2020-12-17 04:57:57 +0100 <monochrom> > lex " abc "
2020-12-17 04:57:59 +0100 <lambdabot> [("abc"," ")]
2020-12-17 04:58:46 +0100 <glguy> consuming spaces after lexing a token is particularly useful for parsec where consuming any input has an effect on backtracking
2020-12-17 04:59:00 +0100Maxdamantusalways thought it made more sense to read at the start rather than at the end.
2020-12-17 04:59:00 +0100 <monochrom> Yeah.
2020-12-17 04:59:21 +0100 <glguy> so you don't want your lexeme parsers eating whitespace only to fail at parsing a lexeme
2020-12-17 04:59:50 +0100 <glguy> nor do you want every alternative to have to reprocess the same whitespac
2020-12-17 05:00:30 +0100Rudd0(~Rudd0@185.189.115.98)
2020-12-17 05:01:00 +0100 <Maxdamantus> since nothing comes before the first thing to consume any leading whitespace, and trailing whitespace gets consumed by the EOF parser.
2020-12-17 05:01:55 +0100 <glguy> all the other factors end up being much more important than that
2020-12-17 05:02:42 +0100 <glguy> ideally you're just using an actual lexing pass, anyway
2020-12-17 05:02:48 +0100cheater(~user@unaffiliated/cheater)
2020-12-17 05:03:28 +0100 <dsal> It's not lexec
2020-12-17 05:03:44 +0100SupaYoshii(~supayoshi@213-10-140-13.fixed.kpn.net) (Quit: Goodbye!)
2020-12-17 05:03:46 +0100elliott__(~elliott@pool-108-51-101-42.washdc.fios.verizon.net)
2020-12-17 05:04:01 +0100pfurla(~pfurla@216.151.180.208) (Ping timeout: 265 seconds)
2020-12-17 05:04:16 +0100elliott__(~elliott@pool-108-51-101-42.washdc.fios.verizon.net) (Client Quit)
2020-12-17 05:04:41 +0100hNoob(6b80d5f1@107-128-213-241.lightspeed.sntcca.sbcglobal.net) (Remote host closed the connection)
2020-12-17 05:05:10 +0100elliott__(~elliott@pool-108-51-101-42.washdc.fios.verizon.net)
2020-12-17 05:06:17 +0100SupaYoshi(~supayoshi@213-10-140-13.fixed.kpn.net)
2020-12-17 05:06:44 +0100Mikagami(~MOSCOS@152.32.70.55)
2020-12-17 05:06:57 +0100pfurla(~pfurla@ool-182ed2e2.dyn.optonline.net)
2020-12-17 05:07:24 +0100jlamothe(~jlamothe@198.251.55.207) (Ping timeout: 265 seconds)
2020-12-17 05:07:42 +0100Mikagami(~MOSCOS@152.32.70.55) (Read error: Connection reset by peer)
2020-12-17 05:08:01 +0100Mikagami(~MOSCOS@152.32.70.55)
2020-12-17 05:09:44 +0100Cthalupa(~cthulhu@47.186.47.75) (Ping timeout: 260 seconds)
2020-12-17 05:09:55 +0100MOSCOS(~MOSCOS@122.54.107.175) (Ping timeout: 268 seconds)
2020-12-17 05:10:16 +0100Cthalupa(~cthulhu@47.186.47.75)
2020-12-17 05:10:41 +0100wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
2020-12-17 05:10:55 +0100RENNNN(~sobhan@gentoo/developer/sobhan) (Quit: Leaving)
2020-12-17 05:10:57 +0100MOSCOS(~MOSCOS@122.54.107.175)
2020-12-17 05:11:37 +0100stefan-_(~cri@42dots.de) (Ping timeout: 264 seconds)
2020-12-17 05:13:11 +0100stefan(~cri@42dots.de)
2020-12-17 05:13:31 +0100Stanley00(~stanley00@unaffiliated/stanley00)
2020-12-17 05:13:42 +0100Mikagami(~MOSCOS@152.32.70.55) (Ping timeout: 256 seconds)
2020-12-17 05:16:15 +0100xsperry(~as@unaffiliated/xsperry) (Read error: Connection reset by peer)
2020-12-17 05:17:34 +0100petersen(~petersen@redhat/juhp)
2020-12-17 05:18:33 +0100devdsp(~devdsp@178.162.212.214) (Ping timeout: 268 seconds)
2020-12-17 05:19:22 +0100argento(~argent0@168.227.97.23)
2020-12-17 05:21:43 +0100da39a3ee5e6b4b0d(~da39a3ee5@2403:6200:8876:cecf:bc4d:596d:63fe:f2dd) (Quit: Textual IRC Client: www.textualapp.com)
2020-12-17 05:23:57 +0100nbloomf(~nbloomf@2600:1700:ad14:3020:a8dc:3f5a:f8f1:dbd6) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2020-12-17 05:24:48 +0100 <steve-chavez> Hello. While trying to upgrade cabal with `cabal install cabal-install`, I get a `unknown package: lukko` error. Does anyone know how to solve that?
2020-12-17 05:25:38 +0100gienah(~mwright@gentoo/developer/gienah) (Quit: leaving)
2020-12-17 05:25:44 +0100 <steve-chavez> cabal install lukko tells me there's no package lukko..
2020-12-17 05:25:49 +0100merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-12-17 05:28:07 +0100gienah(~mwright@gentoo/developer/gienah)
2020-12-17 05:28:18 +0100 <glguy> steve-chavez, You can upgrade your cabal-install with ghcup
2020-12-17 05:28:39 +0100 <glguy> steve-chavez, you might have to run 'cabal update' for it to see that package
2020-12-17 05:29:33 +0100 <steve-chavez> Yes, I've done cabal update before. Will ghcup work on aarch64?
2020-12-17 05:30:53 +0100 <steve-chavez> Just got ghc 8.8.3 working on ubuntu aarch64. If possible I'd like to compile cabal from source..
2020-12-17 05:31:25 +0100merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 264 seconds)
2020-12-17 05:32:35 +0100frankie2(~frankie@s91904426.blix.com)
2020-12-17 05:32:49 +0100 <glguy> I have no idea
2020-12-17 05:33:16 +0100 <MarcelineVQ> dsal, monochrom: It does make sense, I wasn't thinking
2020-12-17 05:33:38 +0100 <dsal> The backtracking thing made sense.
2020-12-17 05:35:32 +0100Vulfe_(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00) (Remote host closed the connection)
2020-12-17 05:36:10 +0100`shy_boy`(~xhearth@110.54.206.153)
2020-12-17 05:36:12 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00)
2020-12-17 05:36:13 +0100`shy_boy`(~xhearth@110.54.206.153) (Excess Flood)
2020-12-17 05:36:50 +0100sakirious(~sakirious@c-71-197-191-137.hsd1.wa.comcast.net)
2020-12-17 05:37:16 +0100drbean(~drbean@TC210-63-209-202.static.apol.com.tw) (Ping timeout: 256 seconds)
2020-12-17 05:37:28 +0100`shy_boy`(~xhearth@110.54.206.153)
2020-12-17 05:37:55 +0100da39a3ee5e6b4b0d(~da39a3ee5@2403:6200:8876:cecf:c08f:f3d8:5294:ef76)
2020-12-17 05:40:37 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00) (Ping timeout: 260 seconds)
2020-12-17 05:42:19 +0100mimi_vx(~mimi@2a01:490:16:1026:d923:3519:de60:eb74)
2020-12-17 05:43:30 +0100 <remexre> is there something like Functor+Foldable for containers with a fixed element?
2020-12-17 05:44:08 +0100 <jle`> fixed element?
2020-12-17 05:44:17 +0100 <MarcelineVQ> like monofunctor or something?
2020-12-17 05:44:18 +0100 <remexre> uh like, specialized containers, e.g. IntVector
2020-12-17 05:44:33 +0100 <remexre> ah yep that looks like it
2020-12-17 05:44:33 +0100 <jle`> maybe mono-traversable
2020-12-17 05:44:35 +0100 <remexre> thanks!
2020-12-17 05:44:36 +0100 <jle`> mono-foldable
2020-12-17 05:46:58 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00)
2020-12-17 05:48:20 +0100triode(~melosense@4e69b241.skybroadband.com)
2020-12-17 05:48:24 +0100triodeGuest95606
2020-12-17 05:48:36 +0100christo(~chris@81.96.113.213) (Remote host closed the connection)
2020-12-17 05:51:27 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00) (Ping timeout: 260 seconds)
2020-12-17 05:51:43 +0100chibi_(~chibi@75-26-238-119.lightspeed.glvwil.sbcglobal.net) (Ping timeout: 260 seconds)
2020-12-17 05:54:04 +0100justanotheruser(~justanoth@unaffiliated/justanotheruser)
2020-12-17 05:56:49 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00)
2020-12-17 05:57:24 +0100Tario(~Tario@201.192.165.173) (Ping timeout: 268 seconds)
2020-12-17 05:58:07 +0100renzhi(~renzhi@2607:fa49:6500:ac00::bfed) (Ping timeout: 272 seconds)
2020-12-17 05:59:04 +0100mbomba(~mbomba@bras-base-toroon2719w-grc-53-142-114-5-26.dsl.bell.ca)
2020-12-17 05:59:28 +0100brodie_(~brodie@207.53.253.137) (Quit: brodie_)
2020-12-17 06:01:43 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00) (Ping timeout: 268 seconds)
2020-12-17 06:01:51 +0100merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-12-17 06:14:40 +0100brodie_(~brodie@207.53.253.137)
2020-12-17 06:15:02 +0100cole-h(~cole-h@c-73-48-197-220.hsd1.ca.comcast.net) (Quit: Goodbye)
2020-12-17 06:15:56 +0100cole-h(~cole-h@c-73-48-197-220.hsd1.ca.comcast.net)
2020-12-17 06:15:57 +0100mimi_vx(~mimi@2a01:490:16:1026:d923:3519:de60:eb74) (Ping timeout: 260 seconds)
2020-12-17 06:17:09 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00)
2020-12-17 06:20:49 +0100brodie_brodie
2020-12-17 06:21:47 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00) (Ping timeout: 260 seconds)
2020-12-17 06:23:48 +0100StoneToad(~StoneToad@199-167-119-150.ppp.storm.ca) (Ping timeout: 260 seconds)
2020-12-17 06:24:56 +0100pyx(~pyx@unaffiliated/pyx)
2020-12-17 06:25:05 +0100pyx(~pyx@unaffiliated/pyx) (Client Quit)
2020-12-17 06:28:59 +0100StoneToad(~StoneToad@104-192-232-58.ppp.storm.ca)
2020-12-17 06:34:11 +0100brodie(~brodie@207.53.253.137) (Quit: brodie)
2020-12-17 06:36:16 +0100merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 256 seconds)
2020-12-17 06:37:30 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00)
2020-12-17 06:39:55 +0100DirefulSalt(DirefulSal@gateway/vpn/privateinternetaccess/direfulsalt)
2020-12-17 06:41:22 +0100Jeanne-Kamikaze(~Jeanne-Ka@66.115.189.229) (Ping timeout: 256 seconds)
2020-12-17 06:41:52 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00) (Ping timeout: 260 seconds)
2020-12-17 06:45:12 +0100rayyyy(~nanoz@gateway/tor-sasl/nanoz)
2020-12-17 06:48:10 +0100 <guest1216> why there's no splitOn and splitWith in Data.List?
2020-12-17 06:48:39 +0100 <guest1216> I know there's Data.List.Split, but why it doesn't come with ghc?
2020-12-17 06:49:12 +0100`shy_boy`(~xhearth@110.54.206.153) (Remote host closed the connection)
2020-12-17 06:49:26 +0100 <guest1216> and yeah, they're in Data.Text, but if we want to operate on String, we have to unpack String to Text?
2020-12-17 06:49:29 +0100plutoniix(~q@184.82.198.131)
2020-12-17 06:50:32 +0100`shy_boy`(~xhearth@110.54.206.153)
2020-12-17 06:56:36 +0100 <maerwald> steve-chavez: not yet (wrt aarch64), but should be possible, since there are already debian aarch bindists and cabal ones as well
2020-12-17 06:58:18 +0100 <maerwald> https://oleg.fi/cabal-install-3.4.0.0-rc4/cabal-install-3.4.0.0-aarch64-ubuntu-18.04.tar.xz
2020-12-17 06:58:19 +0100nek0(~nek0@mail.nek0.eu)
2020-12-17 06:58:25 +0100 <maerwald> https://downloads.haskell.org/~ghc/9.0.1-alpha1/ghc-9.0.0.20200925-aarch64-deb9-linux.tar.xz
2020-12-17 07:02:23 +0100 <steve-chavez> maerwald: Whoa.. thanks! Hope that cabal-install 3.4 works with ghc 8.8.2.. 3.2 didn't ..
2020-12-17 07:02:37 +0100 <steve-chavez> Because of https://github.com/haskell/cabal/issues/6327
2020-12-17 07:03:08 +0100brodie(~brodie@207.53.253.137)
2020-12-17 07:05:43 +0100coot(~coot@37.30.50.101.nat.umts.dynamic.t-mobile.pl)
2020-12-17 07:06:06 +0100takuan(~takuan@178-116-218-225.access.telenet.be)
2020-12-17 07:06:26 +0100merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-12-17 07:07:54 +0100 <steve-chavez> 3.4 contained a cabal binary! Hope I can compile my project now.. (crossing fingers)..
2020-12-17 07:09:06 +0100cgfbee(~bot@oc1.itim-cj.ro) (Remote host closed the connection)
2020-12-17 07:11:58 +0100merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 256 seconds)
2020-12-17 07:13:36 +0100brodie(~brodie@207.53.253.137) (Quit: brodie)
2020-12-17 07:18:38 +0100mounty(~mounty@2001:8000:2f59:0:7042:17ea:748b:dc0c) (Ping timeout: 260 seconds)
2020-12-17 07:18:40 +0100keltono(~keltono@x-160-94-179-178.acm.umn.edu) (Ping timeout: 246 seconds)
2020-12-17 07:20:51 +0100keltono(~keltono@x-160-94-179-178.acm.umn.edu)
2020-12-17 07:27:30 +0100`shy_boy`(~xhearth@110.54.206.153) (Quit: PLease buy best selected product at http://amazonian2.000webhostapp.com/)
2020-12-17 07:28:30 +0100sord937(~sord937@gateway/tor-sasl/sord937)
2020-12-17 07:32:35 +0100 <koz_> maerwald: The oleg.fi download of cabal-install-3.4.0.0 blows up when ghcup tries to cURL it down.
2020-12-17 07:33:29 +0100mimi_vx(~mimi@2a01:490:16:1026:d923:3519:de60:eb74)
2020-12-17 07:33:58 +0100noecho(~noecho@2a01:4f8:1c0c:80ee::4223) (Quit: ZNC - http://znc.in)
2020-12-17 07:34:31 +0100noecho(~noecho@2a01:4f8:1c0c:80ee::4223)
2020-12-17 07:37:25 +0100sim590(~sim590@modemcable090.207-203-24.mc.videotron.ca) (Ping timeout: 264 seconds)
2020-12-17 07:38:35 +0100 <maerwald> koz_: how is that
2020-12-17 07:39:09 +0100 <koz_> Where's tomsmeding's pastebin link gone...
2020-12-17 07:39:34 +0100 <int-e> @where paste
2020-12-17 07:39:34 +0100 <lambdabot> Help us help you: please paste full code, input and/or output at eg https://paste.tomsmeding.com
2020-12-17 07:39:56 +0100 <int-e> . o O ( I
2020-12-17 07:40:00 +0100 <koz_> maerwald: https://paste.tomsmeding.com/Ky4SpOIX
2020-12-17 07:40:04 +0100 <koz_> Like that.
2020-12-17 07:40:26 +0100 <int-e> . o O ( I'd update @paste but we seem to be changing pastebins more frequently than I'm updating lambdabot :-/ )
2020-12-17 07:40:51 +0100 <koz_> This is not specific to my machine (I've reproed it in at least two places), my cURL works fine on every other site, and every other version of cabal (when installing via ghcup).
2020-12-17 07:41:16 +0100 <koz_> int-e: Are you in charge of lambdabot?
2020-12-17 07:41:26 +0100 <koz_> If so, could you update @unmtl with more transformers?
2020-12-17 07:41:29 +0100 <maerwald> internet is broken then I guess
2020-12-17 07:41:55 +0100 <koz_> maerwald: I think it's an issue with oleg.fi honestly.
2020-12-17 07:41:57 +0100nyaomi(~naomi@cpe-74-75-6-125.maine.res.rr.com) (Read error: Connection reset by peer)
2020-12-17 07:42:02 +0100 <koz_> Figured I'd run it by you first.
2020-12-17 07:42:07 +0100nyaomin(~naomi@2603-7080-c43e-59ad-c878-29ff-fedf-ce89.res6.spectrum.com)
2020-12-17 07:42:22 +0100 <int-e> koz_: maybe?
2020-12-17 07:42:27 +0100merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-12-17 07:42:30 +0100 <maerwald> the certificate has no issuer name it seems
2020-12-17 07:42:44 +0100elliott__(~elliott@pool-108-51-101-42.washdc.fios.verizon.net) (Ping timeout: 256 seconds)
2020-12-17 07:43:36 +0100sim590(~sim590@modemcable090.207-203-24.mc.videotron.ca)
2020-12-17 07:43:51 +0100 <koz_> int-e: Maybe you're in charge, or maybe you could update @unmtl with more transformers?
2020-12-17 07:45:49 +0100 <int-e> I'm in charge. I may get around to adding something to @unmtl
2020-12-17 07:46:23 +0100 <koz_> int-e: OK, thanks!
2020-12-17 07:46:34 +0100 <koz_> Main one is ExceptT.
2020-12-17 07:47:33 +0100 <int-e> that one is actually in the repo version, just never got around to rebuilding the thing, it seems
2020-12-17 07:48:24 +0100hf69(~haskeller@ip72-205-40-121.dc.dc.cox.net) (Ping timeout: 268 seconds)
2020-12-17 07:52:12 +0100 <int-e> koz_: so since you brought it up, what are the others?
2020-12-17 07:52:41 +0100 <koz_> int-e: That was basically the only one I need.
2020-12-17 07:53:00 +0100 <koz_> I recall other folks mentioning some more, but that's the main one for me.
2020-12-17 07:57:05 +0100machinedgod(~machinedg@135-23-192-217.cpe.pppoe.ca) (Ping timeout: 240 seconds)
2020-12-17 08:04:45 +0100 <guest1216> how to match a continuum string? letter can't match abc.cdef
2020-12-17 08:05:53 +0100 <koz_> "Continuum string" sounds like a physics term. :P
2020-12-17 08:05:59 +0100p8m_(p8m@gateway/vpn/protonvpn/p8m)
2020-12-17 08:06:26 +0100da39a3ee5e6b4b0d(~da39a3ee5@2403:6200:8876:cecf:c08f:f3d8:5294:ef76) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2020-12-17 08:06:43 +0100 <guest1216> I don't know how to describe it, a string without spaces
2020-12-17 08:07:14 +0100 <guest1216> a continuum non-space char?
2020-12-17 08:07:23 +0100p8m(p8m@gateway/vpn/protonvpn/p8m) (Read error: Connection reset by peer)
2020-12-17 08:08:23 +0100danso(~dan@69-165-210-185.cable.teksavvy.com) (Quit: WeeChat 2.9)
2020-12-17 08:08:48 +0100sh9(~sh9@softbank060116136158.bbtec.net) (Ping timeout: 256 seconds)
2020-12-17 08:10:25 +0100leothrix(~leothrix@elastic/staff/leothrix) (Ping timeout: 240 seconds)
2020-12-17 08:12:17 +0100asheshambasta(~user@ptr-e1lysaxt4bg7tmaahx1.18120a2.ip6.access.telenet.be)
2020-12-17 08:14:20 +0100hexo(~hexo@gateway/tor-sasl/hexo) (Quit: ZNC 1.8.2 - https://znc.in)
2020-12-17 08:15:20 +0100hexo(~hexo@gateway/tor-sasl/hexo)
2020-12-17 08:15:43 +0100jpds(~jpds@gateway/tor-sasl/jpds) (Ping timeout: 240 seconds)
2020-12-17 08:15:43 +0100tomboy64(~tomboy64@gateway/tor-sasl/tomboy64) (Ping timeout: 240 seconds)
2020-12-17 08:15:51 +0100 <MarcelineVQ> you're​mad​completely​mad​and​I​won't​have​it
2020-12-17 08:16:03 +0100Unhammer(~Unhammer@gateway/tor-sasl/unhammer) (Ping timeout: 240 seconds)
2020-12-17 08:16:03 +0100cantstanya(~chatting@gateway/tor-sasl/cantstanya) (Ping timeout: 240 seconds)
2020-12-17 08:16:04 +0100hekkaidekapus(~tchouri@gateway/tor-sasl/hekkaidekapus) (Ping timeout: 240 seconds)
2020-12-17 08:16:04 +0100skiold(~skiold@gateway/tor-sasl/skiold) (Ping timeout: 240 seconds)
2020-12-17 08:16:04 +0100ChaiTRex(~ChaiTRex@gateway/tor-sasl/chaitrex) (Ping timeout: 240 seconds)
2020-12-17 08:16:10 +0100 <steve-chavez> maerwald: It worked! Thank you so much man.. you saved me!
2020-12-17 08:16:23 +0100gxt(~gxt@gateway/tor-sasl/gxt) (Ping timeout: 240 seconds)
2020-12-17 08:16:59 +0100merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 260 seconds)
2020-12-17 08:17:14 +0100Unhammer(~Unhammer@gateway/tor-sasl/unhammer)
2020-12-17 08:17:17 +0100ChaiTRex(~ChaiTRex@gateway/tor-sasl/chaitrex)
2020-12-17 08:17:18 +0100Ariakenom(~Ariakenom@2001:9b1:efb:fc00:8872:797c:1a98:8dff)
2020-12-17 08:17:18 +0100jpds(~jpds@gateway/tor-sasl/jpds)
2020-12-17 08:17:21 +0100hekkaidekapus(~tchouri@gateway/tor-sasl/hekkaidekapus)
2020-12-17 08:17:24 +0100tomboy64(~tomboy64@gateway/tor-sasl/tomboy64)
2020-12-17 08:17:36 +0100skiold(~skiold@gateway/tor-sasl/skiold)
2020-12-17 08:17:39 +0100gxt(~gxt@gateway/tor-sasl/gxt)
2020-12-17 08:18:49 +0100cantstanya(~chatting@gateway/tor-sasl/cantstanya)
2020-12-17 08:20:16 +0100wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Ping timeout: 246 seconds)
2020-12-17 08:20:18 +0100da39a3ee5e6b4b0d(~da39a3ee5@49.228.254.151)
2020-12-17 08:20:56 +0100dhouthoo(~dhouthoo@ptr-eitgbj2w0uu6delkbrh.18120a2.ip6.access.telenet.be)
2020-12-17 08:23:25 +0100geowiesnot(~user@87-89-181-157.abo.bbox.fr)
2020-12-17 08:23:31 +0100solonarv(~solonarv@astrasbourg-157-1-27-135.w90-40.abo.wanadoo.fr)
2020-12-17 08:25:11 +0100jamm(~jamm@unaffiliated/jamm)
2020-12-17 08:26:13 +0100p8m(p8m@gateway/vpn/protonvpn/p8m)
2020-12-17 08:26:31 +0100leothrix(~leothrix@elastic/staff/leothrix)
2020-12-17 08:26:56 +0100p8m_(p8m@gateway/vpn/protonvpn/p8m) (Ping timeout: 240 seconds)
2020-12-17 08:29:01 +0100iteratee(~kyle@162.211.154.4) (Ping timeout: 264 seconds)
2020-12-17 08:31:22 +0100iteratee(~kyle@162.211.154.4)
2020-12-17 08:33:53 +0100lambdabot(~lambdabot@haskell/bot/lambdabot) (Quit: brb)
2020-12-17 08:34:01 +0100lambdabot(~lambdabot@silicon.int-e.eu)
2020-12-17 08:34:01 +0100lambdabot(~lambdabot@silicon.int-e.eu) (Changing host)
2020-12-17 08:34:01 +0100lambdabot(~lambdabot@haskell/bot/lambdabot)
2020-12-17 08:34:43 +0100srk(~sorki@gateway/tor-sasl/sorki) (Ping timeout: 240 seconds)
2020-12-17 08:34:43 +0100denisse(~spaceCat@gateway/tor-sasl/alephzer0) (Ping timeout: 240 seconds)
2020-12-17 08:35:05 +0100jamm(~jamm@unaffiliated/jamm) (Remote host closed the connection)
2020-12-17 08:36:03 +0100philopsos(~caecilius@gateway/tor-sasl/caecilius) (Ping timeout: 240 seconds)
2020-12-17 08:36:23 +0100cantstanya(~chatting@gateway/tor-sasl/cantstanya) (Ping timeout: 240 seconds)
2020-12-17 08:36:24 +0100teardown(~user@gateway/tor-sasl/mrush) (Ping timeout: 240 seconds)
2020-12-17 08:36:43 +0100Unhammer(~Unhammer@gateway/tor-sasl/unhammer) (Ping timeout: 240 seconds)
2020-12-17 08:37:01 +0100srk(~sorki@gateway/tor-sasl/sorki)
2020-12-17 08:37:02 +0100philopsos(~caecilius@gateway/tor-sasl/caecilius)
2020-12-17 08:37:06 +0100teardown(~user@gateway/tor-sasl/mrush)
2020-12-17 08:37:08 +0100denisse(~spaceCat@gateway/tor-sasl/alephzer0)
2020-12-17 08:37:45 +0100Unhammer(~Unhammer@gateway/tor-sasl/unhammer)
2020-12-17 08:39:20 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00)
2020-12-17 08:39:26 +0100cantstanya(~chatting@gateway/tor-sasl/cantstanya)
2020-12-17 08:40:38 +0100jamm(~jamm@unaffiliated/jamm)
2020-12-17 08:41:26 +0100jonathanx(~jonathan@dyn-8-sc.cdg.chalmers.se)
2020-12-17 08:44:35 +0100merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-12-17 08:44:42 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00) (Ping timeout: 260 seconds)
2020-12-17 08:50:23 +0100merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 272 seconds)
2020-12-17 08:50:40 +0100p8m_(p8m@gateway/vpn/protonvpn/p8m)
2020-12-17 08:52:46 +0100p8m(p8m@gateway/vpn/protonvpn/p8m) (Ping timeout: 256 seconds)
2020-12-17 08:52:51 +0100Guest18945lep-delete
2020-12-17 08:56:53 +0100frankie2(~frankie@s91904426.blix.com) (Remote host closed the connection)
2020-12-17 08:59:58 +0100fendor(~fendor@178.165.130.183.wireless.dyn.drei.com)
2020-12-17 09:02:09 +0100Varis(~Tadas@unaffiliated/varis) (Read error: Connection reset by peer)
2020-12-17 09:02:47 +0100geowiesnot(~user@87-89-181-157.abo.bbox.fr) (Ping timeout: 265 seconds)
2020-12-17 09:03:42 +0100danvet(~Daniel@2a02:168:57f4:0:efd0:b9e5:5ae6:c2fa)
2020-12-17 09:04:27 +0100steve-chavez(~steve-cha@190.43.229.137) (Quit: WeeChat 2.4)
2020-12-17 09:09:08 +0100howdoi(uid224@gateway/web/irccloud.com/x-soxuifipgxjanjxg) (Quit: Connection closed for inactivity)
2020-12-17 09:09:34 +0100fendor_(~fendor@77.119.130.134.wireless.dyn.drei.com)
2020-12-17 09:09:40 +0100 <dsal> guest1216: You are probably looking for `satisfy`
2020-12-17 09:11:31 +0100 <guest1216> dsal: I saw that letter = satisfy isAlpha, digit = satisfy isDigit, how to match a string without space
2020-12-17 09:11:56 +0100 <dsal> :t satisfy
2020-12-17 09:11:58 +0100 <lambdabot> error: Variable not in scope: satisfy
2020-12-17 09:12:15 +0100 <dsal> satisfy is just (Char -> Bool)
2020-12-17 09:12:27 +0100fuzzypixelz(~fuzzypixe@eth-west-pareq2-46-193-4-100.wb.wifirst.net)
2020-12-17 09:12:29 +0100 <dsal> Make a function that returns true for chars you like.
2020-12-17 09:12:40 +0100fendor(~fendor@178.165.130.183.wireless.dyn.drei.com) (Ping timeout: 272 seconds)
2020-12-17 09:12:40 +0100wonko7(~wonko7@2a01:e35:2ffb:7040:4535:f480:7dff:b3b5)
2020-12-17 09:12:44 +0100 <dsal> `satisfy (/= ' ')`
2020-12-17 09:12:53 +0100 <dibblego> :type isSpace
2020-12-17 09:13:41 +0100 <dsal> :t isSpace
2020-12-17 09:13:42 +0100 <lambdabot> Char -> Bool
2020-12-17 09:14:45 +0100Usurp1(~Usurp@178.239.168.171)
2020-12-17 09:15:09 +0100merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-12-17 09:18:56 +0100chele(~chele@ip5b416ea2.dynamic.kabel-deutschland.de)
2020-12-17 09:19:28 +0100marek(~mmahut@209.250.249.245) (Changing host)
2020-12-17 09:19:28 +0100marek(~mmahut@fedora/pyxel)
2020-12-17 09:20:03 +0100 <guest1216> dsal: that's right!
2020-12-17 09:26:31 +0100 <guest1216> dsal: sometimes the parser's return values may not be the same type, how to use <|> work on them? like `parse (x :: Parser (String,String) <|> y :: Parser (String, Int)) "" "..."`
2020-12-17 09:26:53 +0100 <guest1216> <|> :: f a -> f a -> f a
2020-12-17 09:27:28 +0100 <guest1216> I should use *> here...
2020-12-17 09:27:51 +0100 <guest1216> never mind
2020-12-17 09:30:57 +0100Varis(~Tadas@unaffiliated/varis)
2020-12-17 09:36:27 +0100Usurp1(~Usurp@178.239.168.171) (Remote host closed the connection)
2020-12-17 09:37:15 +0100Sgeo(~Sgeo@ool-18b98aa4.dyn.optonline.net) (Read error: Connection reset by peer)
2020-12-17 09:37:25 +0100livvy(~livvy@gateway/tor-sasl/livvy)
2020-12-17 09:39:27 +0100wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
2020-12-17 09:40:51 +0100is_null(~jpic@pdpc/supporter/professional/is-null) (Remote host closed the connection)
2020-12-17 09:43:12 +0100iteratee(~kyle@162.211.154.4) (Ping timeout: 256 seconds)
2020-12-17 09:43:38 +0100limpkin1(~limpkin@s91904426.blix.com)
2020-12-17 09:44:21 +0100wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Ping timeout: 265 seconds)
2020-12-17 09:46:07 +0100iteratee(~kyle@162.211.154.4)
2020-12-17 09:48:24 +0100 <guest1216> try to turn "server = abc.net\nport=6667\nname =nick\n" to fromList[("server", "abc.net"), ("port","6667"), ("name","nick")]
2020-12-17 09:48:32 +0100xff0x(~fox@2001:1a81:5260:ab00:b677:a698:4a99:d811) (Ping timeout: 260 seconds)
2020-12-17 09:49:27 +0100xff0x(~fox@2001:1a81:5260:ab00:d51e:2f78:24df:5c60)
2020-12-17 09:49:54 +0100 <guest1216> p9 :: Parser (String,String); p9 = {do; spaces; x <- many letter; spaces; char '='; spaces; y <- many (satisfy (/= ' ')); spaces; return (x,y)}
2020-12-17 09:51:06 +0100 <guest1216> parse p9 "" "on that repeatly string" won't work
2020-12-17 09:51:44 +0100kuribas(~user@ptr-25vy0i8agrj36ppuptm.18120a2.ip6.access.telenet.be)
2020-12-17 09:53:59 +0100 <idnar> shouldn't that be satisfy (/= '\n')?
2020-12-17 09:54:37 +0100 <iqubic> Even better is "satify (not isSpace)"
2020-12-17 09:54:47 +0100 <iqubic> Using "isSpace" from Data.Char
2020-12-17 09:55:43 +0100__monty__(~toonn@unaffiliated/toonn)
2020-12-17 09:56:32 +0100 <guest1216> but that only get Right ("server","abc.net")
2020-12-17 09:56:51 +0100 <guest1216> there're three repeat blocks in that string
2020-12-17 09:57:03 +0100 <merijn> guest1216: Well, p9 doesn't magically get repeated
2020-12-17 09:57:05 +0100 <guest1216> I don't know how to math that
2020-12-17 09:57:19 +0100 <merijn> guest1216: If you write "parse p9" it will parse 'p9' *once*
2020-12-17 09:57:23 +0100 <guest1216> merijn: how to let p9 repeat?
2020-12-17 09:57:28 +0100 <guest1216> forever p9:
2020-12-17 09:57:45 +0100 <merijn> Well, looking at your example input, you probably want "sepBy p9 eol"
2020-12-17 09:57:49 +0100 <merijn> @hoogle sepBy
2020-12-17 09:57:50 +0100 <lambdabot> Text.ParserCombinators.ReadP sepBy :: ReadP a -> ReadP sep -> ReadP [a]
2020-12-17 09:57:50 +0100 <lambdabot> Text.Parsec sepBy :: Stream s m t => ParsecT s u m a -> ParsecT s u m sep -> ParsecT s u m [a]
2020-12-17 09:57:50 +0100 <lambdabot> Text.Parsec.Combinator sepBy :: Stream s m t => ParsecT s u m a -> ParsecT s u m sep -> ParsecT s u m [a]
2020-12-17 09:57:53 +0100 <merijn> hmm
2020-12-17 09:58:10 +0100 <merijn> Probably want the version from parser-combinators if you're using megaparsec
2020-12-17 09:58:27 +0100 <solonarv> yes, and it's re-exported by megaparsec
2020-12-17 09:58:33 +0100 <guest1216> I don't know speBy's usage, spe is short for?
2020-12-17 09:58:38 +0100 <merijn> separator
2020-12-17 09:58:52 +0100 <solonarv> *sep*, not *spe*
2020-12-17 09:58:55 +0100 <merijn> "sepBy x y" is "parse 0 or more 'x' separated by 'y'"
2020-12-17 09:59:11 +0100 <solonarv> "sepBy" is short for "separated by", it's meant to be used infix
2020-12-17 09:59:13 +0100 <merijn> So "sepBy p9 eol" would be "parse 0 or more p9, separated by newlines"
2020-12-17 09:59:36 +0100 <solonarv> for example, "p9 `sepBy` eol" reads "p9 separated by newline(s)"
2020-12-17 09:59:56 +0100 <guest1216> ok, I will try it
2020-12-17 10:00:26 +0100Ekho(~Ekho@unaffiliated/ekho) (Quit: CORE ERROR, SYSTEM HALTED.)
2020-12-17 10:01:17 +0100oish(~charlie@228.25.169.217.in-addr.arpa)
2020-12-17 10:01:36 +0100Cthalupa(~cthulhu@47.186.47.75) (Ping timeout: 268 seconds)
2020-12-17 10:01:38 +0100 <guest1216> there's no eol in Text.Parsec...
2020-12-17 10:02:15 +0100 <dminuoso> merijn: From what I gathered over the past few days, they're using parsec?
2020-12-17 10:02:21 +0100Cthalupa(~cthulhu@47.186.47.75)
2020-12-17 10:02:32 +0100nineonine(~nineonine@50.216.62.2) (Ping timeout: 256 seconds)
2020-12-17 10:03:32 +0100sh9(~sh9@softbank060116136158.bbtec.net)
2020-12-17 10:04:37 +0100cfricke(~cfricke@unaffiliated/cfricke)
2020-12-17 10:05:52 +0100oish(~charlie@228.25.169.217.in-addr.arpa) (Ping timeout: 256 seconds)
2020-12-17 10:07:08 +0100 <int-e> guest1216: there's https://hackage.haskell.org/package/parsec-3.1.14.0/docs/Text-Parsec-Char.html#v:endOfLine
2020-12-17 10:07:36 +0100oish(~charlie@228.25.169.217.in-addr.arpa)
2020-12-17 10:08:51 +0100superstar64(6ccefa7c@108-206-250-124.lightspeed.miamfl.sbcglobal.net)
2020-12-17 10:09:28 +0100 <superstar64> is there a sort of semi flexible instances, where you can only match `T a b c` or raw type variables `a`?
2020-12-17 10:09:36 +0100 <superstar64> i find i'm doing this pattern a lot in my code
2020-12-17 10:09:44 +0100 <guest1216> parse (sepBy p9 endOfLine) "" "server = abc.net\n port= 6667\n" == Right ("server", "abc.net\n")
2020-12-17 10:11:43 +0100hexo(~hexo@gateway/tor-sasl/hexo) (Ping timeout: 240 seconds)
2020-12-17 10:12:54 +0100hexo(~hexo@gateway/tor-sasl/hexo)
2020-12-17 10:13:38 +0100thc202(~thc202@unaffiliated/thc202)
2020-12-17 10:13:48 +0100Ekho(~Ekho@unaffiliated/ekho)
2020-12-17 10:14:08 +0100heatsink(~heatsink@2600:1700:bef1:5e10:64b4:1541:658f:e8d8) (Remote host closed the connection)
2020-12-17 10:14:51 +0100 <dminuoso> superstar64: What do you mean by "only match `T a b c`" exactly?
2020-12-17 10:15:08 +0100 <superstar64> that's the normal requirement for instances right?
2020-12-17 10:15:10 +0100cole-h(~cole-h@c-73-48-197-220.hsd1.ca.comcast.net) (Ping timeout: 256 seconds)
2020-12-17 10:15:51 +0100 <superstar64> i just want instances with that and the option to match with only a type variable
2020-12-17 10:15:55 +0100 <dminuoso> superstar64: Standard Haskell demands the shape of the instance head to be `T a_0 a_2 .. a_n` where a_0 through a_n is an arbitrary amount of type variables
2020-12-17 10:16:08 +0100 <superstar64> yes i know that
2020-12-17 10:16:15 +0100 <dminuoso> So what is your question exactly?
2020-12-17 10:16:52 +0100 <superstar64> i'm just noticing i'm doing something slightly looser and i'm wonder if there's a limited version of flexible instances?
2020-12-17 10:17:00 +0100 <dminuoso> What do you mean by "limited" exactly?
2020-12-17 10:17:12 +0100 <dminuoso> Do you have an example of an instance you'd like to write?
2020-12-17 10:17:17 +0100 <superstar64> the normal `T a b c` and the ability to match `a`
2020-12-17 10:17:24 +0100 <dminuoso> You mean like `T Int b c` ?
2020-12-17 10:17:29 +0100 <superstar64> no
2020-12-17 10:17:43 +0100 <dminuoso> Then I do not understand.
2020-12-17 10:18:29 +0100 <superstar64> `instance (a ~ a') => F a (MyObject a')`
2020-12-17 10:18:56 +0100 <superstar64> i only want the ability to match `T a b c` and `a`
2020-12-17 10:20:22 +0100 <superstar64> " (Arguably it should be okay if just one has this form and the others are type variables, but that’s the rules at the moment)." from https://downloads.haskell.org/~ghc/latest/docs/html/users_guide/glasgow_exts.html#extension-Flexib…
2020-12-17 10:20:30 +0100 <superstar64> is there more info on this?
2020-12-17 10:24:07 +0100justanotheruser(~justanoth@unaffiliated/justanotheruser) (Ping timeout: 272 seconds)
2020-12-17 10:24:58 +0100hyiltiz(~quassel@unaffiliated/hyiltiz) (Quit: hyiltiz)
2020-12-17 10:25:13 +0100Bigcheese(~quassel@unaffiliated/bigcheese) (Remote host closed the connection)
2020-12-17 10:26:09 +0100hyiltiz(~quassel@93.119.106.77)
2020-12-17 10:26:09 +0100hyiltiz(~quassel@93.119.106.77) (Changing host)
2020-12-17 10:26:09 +0100hyiltiz(~quassel@unaffiliated/hyiltiz)
2020-12-17 10:26:21 +0100Bigcheese(~quassel@unaffiliated/bigcheese)
2020-12-17 10:26:50 +0100da39a3ee5e6b4b0d(~da39a3ee5@49.228.254.151) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2020-12-17 10:27:45 +0100 <lortabac> superstar64: do you mean you want to forbid the head of the instance declaration from mentioning concrete types in type-constructor arguments?
2020-12-17 10:28:02 +0100 <superstar64> yes
2020-12-17 10:28:23 +0100 <superstar64> i just want normal rules in addition to matching type variables
2020-12-17 10:29:18 +0100 <guest1216> where it's wrong? https://paste.ubuntu.com/p/QSCc59fsFR/
2020-12-17 10:29:29 +0100 <lortabac> superstar64: isn't it just Haskell 98?
2020-12-17 10:29:55 +0100 <superstar64> lortabac, no you can't do `instance F a where`
2020-12-17 10:31:15 +0100 <lortabac> is there a use case for 'instance F a'?
2020-12-17 10:31:18 +0100 <merijn> superstar64: You can, but that overlaps everything, so that's not what you want :p
2020-12-17 10:31:21 +0100 <merijn> lortabac: No
2020-12-17 10:31:22 +0100 <dminuoso> superstar64: https://www.microsoft.com/en-us/research/wp-content/uploads/1997/01/multi.pdf should be a worthwhile read.
2020-12-17 10:31:50 +0100 <superstar64> there's a uses with multiple param typeclasses
2020-12-17 10:32:22 +0100 <merijn> superstar64: multi param typeclasses aren't standard anyway, so Haskell2010 says nothing about it :p
2020-12-17 10:32:23 +0100 <int-e> guest1216: satisfy (/= ' ') matches newlines
2020-12-17 10:32:23 +0100michalz(~user@185.246.204.59)
2020-12-17 10:32:42 +0100 <superstar64> well i want multi param typeclasses with semi flexible instances
2020-12-17 10:32:52 +0100 <merijn> That's not a thing
2020-12-17 10:33:03 +0100 <int-e> guest1216: not sure what to use instead, maybe try satisfy (not . isSpace) (isSpace is from Data.Char)
2020-12-17 10:33:05 +0100 <merijn> Just enable FlexibleInstances
2020-12-17 10:33:15 +0100 <lortabac> superstar64: even with multi param typeclasses, matching on 'a' is generally a bad idea
2020-12-17 10:33:49 +0100 <int-e> guest1216: the other thing that's wrong is that you don't terminate the parse using `eof`, so it can stop in the middle and discard the remaining input.
2020-12-17 10:34:35 +0100 <dminuoso> superstar64: So you roughly want something like `instance {-# OVERLAPPING #-} C (T a b c); instance C a` ?
2020-12-17 10:34:36 +0100 <lortabac> superstar64: there might be situations in which it is necessary, but those are certainly not common
2020-12-17 10:34:59 +0100 <superstar64> what's `{-# OVERLAPPING #-}`?
2020-12-17 10:35:10 +0100 <int-e> guest1216: try parse (endEndBy parseAll endOfLine *> eof)
2020-12-17 10:35:21 +0100 <int-e> guest1216: err, sepEndBy
2020-12-17 10:35:43 +0100 <dminuoso> superstar64: Overlapping instances, keep in mind that `instance C a`, were it allowed, would match *all* types, including `T a b c`
2020-12-17 10:37:13 +0100 <dminuoso> Unlike case-of in the value world, where the pattern matching has a tractable order, such that `case t of T ... -> ...; _ -> ...` makes sense, it doesn't work like that typeclasses. If `instance C a` was allowed, the above would be the sort of equivalent
2020-12-17 10:37:19 +0100fuzzypixelz(~fuzzypixe@eth-west-pareq2-46-193-4-100.wb.wifirst.net) (Quit: fuzzypixelz)
2020-12-17 10:37:19 +0100amerigo(uid331857@gateway/web/irccloud.com/x-qlwggbtbsclqlize)
2020-12-17 10:37:44 +0100 <dminuoso> Oh. it seems allowed inf act with FlexibleInstances
2020-12-17 10:37:48 +0100 <dminuoso> % instance Functor f
2020-12-17 10:37:48 +0100 <yahb> dminuoso: ; <interactive>:5:10: warning: [-Wmissing-methods]; * No explicit implementation for; `fmap'; * In the instance declaration for `Functor f'
2020-12-17 10:37:55 +0100 <dminuoso> Well. I guess there you go, then.
2020-12-17 10:38:26 +0100dminuosoregrets overlapping instances every time
2020-12-17 10:38:46 +0100 <superstar64> maybe i can avoid flexible instances with functional dependencies, i'll try to refactor my code
2020-12-17 10:38:58 +0100 <dminuoso> superstar64: fundeps does not replace flexible instances.
2020-12-17 10:39:10 +0100 <merijn> https://twitter.com/Symbo1ics/status/1339328851365814272 >.>
2020-12-17 10:39:11 +0100 <superstar64> does it replace my specific usecase?
2020-12-17 10:39:16 +0100hnOsmium0001(uid453710@gateway/web/irccloud.com/x-zxxiepmgnexcriai) (Quit: Connection closed for inactivity)
2020-12-17 10:39:25 +0100 <dminuoso> in fact, for fundeps to be useful you usually have to enable MPTC, and flexible instances/contexts anyway
2020-12-17 10:39:36 +0100nineonine(~nineonine@50.216.62.2)
2020-12-17 10:40:04 +0100 <int-e> merijn: why does that sound like XML
2020-12-17 10:41:09 +0100 <lortabac> superstar64: you didn't say what you use case is :)
2020-12-17 10:41:12 +0100 <lortabac> *your
2020-12-17 10:41:20 +0100 <int-e> (What I mean is, in this context, JSON looks like an XML-shaped hole for people to fall into.)
2020-12-17 10:41:36 +0100 <dminuoso> int-e: Unlike programming code, JSON is human readable!
2020-12-17 10:41:43 +0100 <superstar64> i'm writing a compiler and i find this neat way of having composible typesystems
2020-12-17 10:41:44 +0100 <merijn> @quote the.essence.of
2020-12-17 10:41:44 +0100 <lambdabot> dibblego says: if only all/most programmers understood the essence of compositional programming... _peter: Stupid question, is there any nice way to do a ::= with a list?
2020-12-17 10:41:47 +0100 <merijn> aww
2020-12-17 10:41:49 +0100 <merijn> wrong quote
2020-12-17 10:42:05 +0100 <superstar64> it's a lot of `instance (a ~ a') => F a (G a')`
2020-12-17 10:42:10 +0100 <merijn> @quote Wadler essence.of
2020-12-17 10:42:11 +0100 <lambdabot> Wadler says: So, the essence of XML is this: the problem it solves is not hard, and it does not solve the problem well.
2020-12-17 10:42:25 +0100RusAlex(~Chel@unaffiliated/rusalex) (Ping timeout: 240 seconds)
2020-12-17 10:42:35 +0100mbomba(~mbomba@bras-base-toroon2719w-grc-53-142-114-5-26.dsl.bell.ca) (Quit: WeeChat 3.0)
2020-12-17 10:43:16 +0100 <kuribas> the tools around it suck, but then it's made for languages that suck
2020-12-17 10:43:23 +0100philopsos(~caecilius@gateway/tor-sasl/caecilius) (Ping timeout: 240 seconds)
2020-12-17 10:43:28 +0100 <kuribas> so it cancels out
2020-12-17 10:43:35 +0100RusAlex(~Chel@unaffiliated/rusalex)
2020-12-17 10:44:51 +0100MOSCOS(~MOSCOS@122.54.107.175) (Remote host closed the connection)
2020-12-17 10:45:15 +0100nineonine(~nineonine@50.216.62.2) (Ping timeout: 265 seconds)
2020-12-17 10:45:17 +0100MOSCOS(~MOSCOS@122.54.107.175)
2020-12-17 10:45:31 +0100 <lortabac> superstar64: it's hard to tell without knowing the details, but at first sight it looks like a good use case for singleton-bool
2020-12-17 10:46:40 +0100 <superstar64> i have things like `data Application e = Application e e` ... `instance TypeCheck e (Application e')` ...
2020-12-17 10:49:38 +0100 <lortabac> superstar64: so the purpose of the instance is only to ensure that the types are equal?
2020-12-17 10:50:00 +0100 <lortabac> is there are instance for when the types are NOT equal?
2020-12-17 10:50:14 +0100 <superstar64> i don't think so
2020-12-17 10:50:26 +0100DavidEichmann(~david@62.110.198.146.dyn.plus.net)
2020-12-17 10:50:36 +0100 <lortabac> then can't you just write a function?
2020-12-17 10:50:50 +0100dexterlb(~dexterlb@2a01:9e40:2:2::2) (Quit: Boing)
2020-12-17 10:51:11 +0100 <superstar64> i have a giant either chain, and the an instance for `TypeCheck` for either
2020-12-17 10:51:19 +0100 <superstar64> and a project from my ast to the either chain
2020-12-17 10:51:21 +0100Tuplanolla(~Tuplanoll@91-159-68-239.elisa-laajakaista.fi)
2020-12-17 10:51:21 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00)
2020-12-17 10:51:25 +0100edk_demiurge
2020-12-17 10:51:38 +0100dexterlb(~dexterlb@2a01:9e40:2:2::2)
2020-12-17 10:52:08 +0100m0rphism(~m0rphism@HSI-KBW-085-216-104-059.hsi.kabelbw.de)
2020-12-17 10:52:09 +0100fendor_(~fendor@77.119.130.134.wireless.dyn.drei.com) (Remote host closed the connection)
2020-12-17 10:52:21 +0100 <lortabac> superstar64: are you sure you need the TypeCheck class at all?
2020-12-17 10:52:35 +0100 <superstar64> well, i don't need them, but it makes this code way more composble
2020-12-17 10:53:21 +0100 <lortabac> the purpose of type classes is overloading, if you don't do any overloading I don't see the point
2020-12-17 10:53:23 +0100rayyyy(~nanoz@gateway/tor-sasl/nanoz) (Ping timeout: 240 seconds)
2020-12-17 10:53:42 +0100 <lortabac> but I don't know your code, so I might have misunderstood
2020-12-17 10:53:44 +0100 <superstar64> if i have 2 different asts, i can share a lot of code between them this way
2020-12-17 10:54:04 +0100 <superstar64> i just need to project them both into an either chain
2020-12-17 10:54:36 +0100 <lortabac> then it looks like you need 'instance TypeCheck AST1' and 'instance TypeCheck AST2'
2020-12-17 10:55:03 +0100 <superstar64> no, i have each constructor as it's own type
2020-12-17 10:55:50 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00) (Ping timeout: 264 seconds)
2020-12-17 10:58:32 +0100fendor(~fendor@77.119.130.134.wireless.dyn.drei.com)
2020-12-17 10:58:40 +0100 <solonarv> superstar64: what are the methods of this TypeCheck class?
2020-12-17 10:59:56 +0100 <superstar64> i just have 1 method per typeclass
2020-12-17 11:00:35 +0100fuzzypixelz(~fuzzypixe@eth-west-pareq2-46-193-4-100.wb.wifirst.net)
2020-12-17 11:00:45 +0100 <solonarv> that is an extremely weird way of splitting things up
2020-12-17 11:00:50 +0100argento(~argent0@168.227.97.23) (Remote host closed the connection)
2020-12-17 11:01:42 +0100 <solonarv> but what, *exactly*, is the (apparently only) method of TypeCheck?
2020-12-17 11:03:48 +0100 <superstar64> `class TypeCheck m e σ where { typeCheck :: e -> m σ }`
2020-12-17 11:04:28 +0100gehmehgeh(~ircuser1@gateway/tor-sasl/gehmehgeh)
2020-12-17 11:05:27 +0100 <solonarv> uhhh... then how are you writing 'data Application e = Application e e; instance TypeCheck e (Application e') where ...' ? that doesn't kind-check
2020-12-17 11:06:20 +0100 <superstar64> give me a second, i'll post a paste after i'm done refactoring
2020-12-17 11:08:46 +0100 <merijn> I'm now morbidly curious
2020-12-17 11:11:09 +0100 <superstar64> https://gist.github.com/Superstar64/5eb07d95e538f8a320d611471471d3dd
2020-12-17 11:11:30 +0100jamm(~jamm@unaffiliated/jamm) (Remote host closed the connection)
2020-12-17 11:11:45 +0100oish(~charlie@228.25.169.217.in-addr.arpa) (Ping timeout: 240 seconds)
2020-12-17 11:13:26 +0100jonathanx(~jonathan@dyn-8-sc.cdg.chalmers.se) (Remote host closed the connection)
2020-12-17 11:13:42 +0100jonathanx(~jonathan@dyn-8-sc.cdg.chalmers.se)
2020-12-17 11:13:47 +0100oish(~charlie@228.25.169.217.in-addr.arpa)
2020-12-17 11:14:31 +0100heatsink(~heatsink@2600:1700:bef1:5e10:64b4:1541:658f:e8d8)
2020-12-17 11:17:15 +0100jamm(~jamm@unaffiliated/jamm)
2020-12-17 11:17:46 +0100 <superstar64> this is called the tagless final style right?
2020-12-17 11:18:06 +0100 <superstar64> i read oleg's paper on tihs
2020-12-17 11:18:33 +0100 <superstar64> or wait, i might be misremebering
2020-12-17 11:19:17 +0100heatsink(~heatsink@2600:1700:bef1:5e10:64b4:1541:658f:e8d8) (Ping timeout: 260 seconds)
2020-12-17 11:19:38 +0100raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net)
2020-12-17 11:21:55 +0100 <merijn> Well...that looks like a nightmare to actually use :)
2020-12-17 11:22:22 +0100 <solonarv> I agree. I can't fathom why you would design your compiler like this.
2020-12-17 11:22:38 +0100 <superstar64> so i can share code between 2 different asts?
2020-12-17 11:22:58 +0100 <merijn> superstar64: In reality you can't share code between different ASTs
2020-12-17 11:23:00 +0100pjb(~t@2a01cb04063ec5007460d15e87468757.ipv6.abo.wanadoo.fr) (Ping timeout: 268 seconds)
2020-12-17 11:23:04 +0100 <solonarv> do you actually *have* two different ASTs? I don't even see one AST in there
2020-12-17 11:23:06 +0100 <superstar64> if i have a hindley milner version and an explicited typed version, i can share these typing rules
2020-12-17 11:23:20 +0100 <superstar64> that's only the typing rules solonarv
2020-12-17 11:23:39 +0100 <merijn> Prediction: The overhead and confusion of this whole approach will cost you 5x more time than simply writing the code twice
2020-12-17 11:23:59 +0100Gurkenglas(~Gurkengla@unaffiliated/gurkenglas)
2020-12-17 11:24:08 +0100 <solonarv> merijn: seconded
2020-12-17 11:24:15 +0100 <superstar64> https://gist.github.com/Superstar64/dfd430fcf10f3cb6363b5377116a96d1
2020-12-17 11:24:25 +0100oish(~charlie@228.25.169.217.in-addr.arpa) (Quit: leaving)
2020-12-17 11:24:27 +0100 <superstar64> here's a snippet from my core language
2020-12-17 11:24:53 +0100 <superstar64> it's been working pretty well for me so far
2020-12-17 11:27:09 +0100 <fuzzypixelz> can I write multiline list comprehensions?
2020-12-17 11:27:31 +0100 <superstar64> fuzzypixelz, can't you use do notation for that?
2020-12-17 11:27:35 +0100 <guest1216> int-e: https://paste.ubuntu.com/p/SVc9hPqn3t/
2020-12-17 11:28:19 +0100 <solonarv> fuzzypixelz: of course, you can generally spread any expression out over multiple lines; list comprehensions are no exception to that
2020-12-17 11:29:04 +0100 <fuzzypixelz> yes, but I don't know how to use do notation...
2020-12-17 11:29:04 +0100 <guest1216> int-e: https://paste.ubuntu.com/p/Ssn6PbxJVK/
2020-12-17 11:30:01 +0100 <solonarv> fuzzypixelz: here's an example of a multiline list comprehension: https://github.com/Solonarv/adventofcode-2020/blob/main/haskell/solutions/Day03.hs#L46-L53
2020-12-17 11:30:03 +0100gxt(~gxt@gateway/tor-sasl/gxt) (Ping timeout: 240 seconds)
2020-12-17 11:30:25 +0100u0_a203__(~u0_a203@37.98.47.224)
2020-12-17 11:31:03 +0100u0_a203__(~u0_a203@37.98.47.224) (Client Quit)
2020-12-17 11:33:38 +0100ubert(~Thunderbi@p200300ecdf35147ee6b318fffe838f33.dip0.t-ipconnect.de)
2020-12-17 11:35:16 +0100boxscape(4ff0ba59@gateway/web/cgi-irc/kiwiirc.com/ip.79.240.186.89)
2020-12-17 11:35:16 +0100boxscape(4ff0ba59@gateway/web/cgi-irc/kiwiirc.com/ip.79.240.186.89) (Client Quit)
2020-12-17 11:35:38 +0100guest1216(~user@49.5.6.87) (Ping timeout: 256 seconds)
2020-12-17 11:37:27 +0100Franciman(~francesco@host-82-49-79-73.retail.telecomitalia.it)
2020-12-17 11:40:50 +0100xff0x(~fox@2001:1a81:5260:ab00:d51e:2f78:24df:5c60) (Ping timeout: 264 seconds)
2020-12-17 11:41:39 +0100xff0x(~fox@2001:1a81:5260:ab00:d700:e460:f864:a3a3)
2020-12-17 11:43:10 +0100st8less(~st8less@inet-167-224-197-181.isp.ozarksgo.net) (Quit: WeeChat 2.9)
2020-12-17 11:47:30 +0100inkbottle(~inkbottle@aaubervilliers-654-1-95-58.w86-212.abo.wanadoo.fr)
2020-12-17 11:48:06 +0100zebrag(~inkbottle@aaubervilliers-654-1-76-48.w86-212.abo.wanadoo.fr) (Ping timeout: 256 seconds)
2020-12-17 11:49:01 +0100aplainzetakind(~johndoe@captainludd.powered.by.lunarbnc.net) (Quit: Free ZNC ~ Powered by LunarBNC: https://LunarBNC.net)
2020-12-17 11:51:48 +0100raichoo(~raichoo@dslb-092-073-214-015.092.073.pools.vodafone-ip.de)
2020-12-17 11:52:36 +0100aplainzetakind(~johndoe@captainludd.powered.by.lunarbnc.net)
2020-12-17 11:55:05 +0100berberman(~berberman@unaffiliated/berberman)
2020-12-17 11:56:26 +0100berberman_(~berberman@unaffiliated/berberman) (Ping timeout: 264 seconds)
2020-12-17 12:01:44 +0100cvlad-(sid203065@gateway/web/irccloud.com/x-tonetmfmrrlnwmtg) (Quit: Connection closed for inactivity)
2020-12-17 12:01:59 +0100shatriff(~vitaliish@176-52-216-242.irishtelecom.com)
2020-12-17 12:03:26 +0100srk(~sorki@gateway/tor-sasl/sorki) (Remote host closed the connection)
2020-12-17 12:03:39 +0100srk(~sorki@gateway/tor-sasl/sorki)
2020-12-17 12:07:11 +0100da39a3ee5e6b4b0d(~da39a3ee5@2403:6200:8876:cecf:4940:8dd3:7c10:4404)
2020-12-17 12:09:31 +0100shatriff(~vitaliish@176-52-216-242.irishtelecom.com) (Remote host closed the connection)
2020-12-17 12:09:46 +0100shatriff(~vitaliish@176-52-216-242.irishtelecom.com)
2020-12-17 12:10:38 +0100superstar64(6ccefa7c@108-206-250-124.lightspeed.miamfl.sbcglobal.net) (Remote host closed the connection)
2020-12-17 12:11:52 +0100Death_(~Death@125.166.65.72)
2020-12-17 12:15:58 +0100heatsink(~heatsink@2600:1700:bef1:5e10:64b4:1541:658f:e8d8)
2020-12-17 12:16:28 +0100borne(~fritjof@200116b864804800c0a3d285e8e687f4.dip.versatel-1u1.de)
2020-12-17 12:18:12 +0100dhil(~dhil@78.156.97.38)
2020-12-17 12:19:49 +0100LKoen(~LKoen@29.248.88.92.rev.sfr.net)
2020-12-17 12:21:02 +0100heatsink(~heatsink@2600:1700:bef1:5e10:64b4:1541:658f:e8d8) (Ping timeout: 264 seconds)
2020-12-17 12:21:44 +0100oish(~charlie@228.25.169.217.in-addr.arpa)
2020-12-17 12:22:45 +0100oish(~charlie@228.25.169.217.in-addr.arpa) (Client Quit)
2020-12-17 12:23:06 +0100oish(~charlie@228.25.169.217.in-addr.arpa)
2020-12-17 12:24:06 +0100ClaudiusMaximus(~claude@196.67.6.51.dyn.plus.net)
2020-12-17 12:24:06 +0100ClaudiusMaximus(~claude@196.67.6.51.dyn.plus.net) (Changing host)
2020-12-17 12:24:06 +0100ClaudiusMaximus(~claude@unaffiliated/claudiusmaximus)
2020-12-17 12:24:19 +0100oish(~charlie@228.25.169.217.in-addr.arpa) (Client Quit)
2020-12-17 12:24:42 +0100oish(~charlie@228.25.169.217.in-addr.arpa)
2020-12-17 12:28:58 +0100Miroboru(~myrvoll@78.156.11.206) (Ping timeout: 260 seconds)
2020-12-17 12:28:59 +0100matryoshka(~matryoshk@184.75.223.227) (Ping timeout: 268 seconds)
2020-12-17 12:29:14 +0100Miroboru(~myrvoll@78.91.103.180)
2020-12-17 12:29:57 +0100Death_(~Death@125.166.65.72) (Quit: Leaving...)
2020-12-17 12:32:46 +0100oish(~charlie@228.25.169.217.in-addr.arpa) (Quit: Lost terminal)
2020-12-17 12:33:11 +0100oish(~charlie@228.25.169.217.in-addr.arpa)
2020-12-17 12:34:01 +0100 <pja> solonarv: I usually turn those into do .. pure blocks.
2020-12-17 12:34:39 +0100 <pja> Not sure why, but I prefer it that way.
2020-12-17 12:37:55 +0100 <int-e> pja: they lay out more nicely and the result is at the end... so when reading code linearly you know what the variables in there are. all this for the small price of having to use `guard` for filtering by boolean constraints
2020-12-17 12:39:58 +0100rprije(~rprije@14-203-203-69.tpgi.com.au) (Ping timeout: 246 seconds)
2020-12-17 12:40:44 +0100oish(~charlie@228.25.169.217.in-addr.arpa) (Quit: Lost terminal)
2020-12-17 12:41:08 +0100oish(~charlie@228.25.169.217.in-addr.arpa)
2020-12-17 12:42:33 +0100mouseghost(~draco@wikipedia/desperek)
2020-12-17 12:45:51 +0100christo(~chris@81.96.113.213)
2020-12-17 12:49:14 +0100wonko7(~wonko7@2a01:e35:2ffb:7040:4535:f480:7dff:b3b5) (Ping timeout: 264 seconds)
2020-12-17 12:50:45 +0100oish(~charlie@228.25.169.217.in-addr.arpa) (Quit: Lost terminal)
2020-12-17 12:51:11 +0100oish(~charlie@228.25.169.217.in-addr.arpa)
2020-12-17 12:55:51 +0100Tario(~Tario@201.192.165.173)
2020-12-17 12:57:52 +0100Stanley00(~stanley00@unaffiliated/stanley00) (Remote host closed the connection)
2020-12-17 12:58:01 +0100cgfbee(~bot@oc1.itim-cj.ro)
2020-12-17 13:01:12 +0100carldd0(~carldd@90-224-49-113-no56.tbcn.telia.com) (Quit: The Lounge - https://thelounge.chat)
2020-12-17 13:01:20 +0100kenran(~kenran@i59F67BCB.versanet.de)
2020-12-17 13:01:37 +0100carldd(~carldd@90-224-49-113-no56.tbcn.telia.com)
2020-12-17 13:07:12 +0100superstar64(6ccefa7c@108-206-250-124.lightspeed.miamfl.sbcglobal.net)
2020-12-17 13:07:14 +0100borne(~fritjof@200116b864804800c0a3d285e8e687f4.dip.versatel-1u1.de) (Ping timeout: 264 seconds)
2020-12-17 13:08:11 +0100 <[exa]> is there any good reading material about the logic of migrations in Database.Selda ? (tutorial is missing so far)
2020-12-17 13:09:27 +0100berberman(~berberman@unaffiliated/berberman) (Quit: ZNC 1.7.5 - https://znc.in)
2020-12-17 13:09:53 +0100berberman(~berberman@unaffiliated/berberman)
2020-12-17 13:10:16 +0100jamm(~jamm@unaffiliated/jamm) (Remote host closed the connection)
2020-12-17 13:12:18 +0100Entertainment(~entertain@104.246.132.210)
2020-12-17 13:13:57 +0100jamm(~jamm@unaffiliated/jamm)
2020-12-17 13:14:15 +0100jamm(~jamm@unaffiliated/jamm) (Remote host closed the connection)
2020-12-17 13:22:38 +0100Varis(~Tadas@unaffiliated/varis) (Ping timeout: 268 seconds)
2020-12-17 13:29:25 +0100olligobber(olligobber@gateway/vpn/privateinternetaccess/olligobber) (Ping timeout: 240 seconds)
2020-12-17 13:30:42 +0100FreeBirdLjj(~freebirdl@101.87.168.174)
2020-12-17 13:31:22 +0100jmchael_(~jmchael@87.112.46.194)
2020-12-17 13:33:05 +0100Cthalupa(~cthulhu@47.186.47.75) (Ping timeout: 240 seconds)
2020-12-17 13:33:55 +0100 <cheater> has anyone been able to compile the llvm lib for llvm 9.0.1 on windows?
2020-12-17 13:33:57 +0100Cthalupa(~cthulhu@47.186.47.75)
2020-12-17 13:35:12 +0100 <fuzzypixelz> hello
2020-12-17 13:35:16 +0100 <fuzzypixelz> I write
2020-12-17 13:35:18 +0100 <fuzzypixelz> lambda byr: byr >= 1920 and byr <= 2002
2020-12-17 13:35:23 +0100FreeBirdLjj(~freebirdl@101.87.168.174) (Ping timeout: 265 seconds)
2020-12-17 13:35:48 +0100 <[exa]> fuzzypixelz: that's some snakeish variant of haskell?
2020-12-17 13:35:50 +0100 <int-e> That doesn't look like Haskell, what is it? Python?
2020-12-17 13:35:53 +0100 <fuzzypixelz> but pylint says: simplify chained expression between operands
2020-12-17 13:36:01 +0100 <int-e> [exa] said it better
2020-12-17 13:36:02 +0100 <fuzzypixelz> oh my lord! wrong channel!
2020-12-17 13:36:12 +0100 <[exa]> p a r s e l t o n g u e
2020-12-17 13:36:36 +0100 <superstar64> https://pyos.github.io/dg/
2020-12-17 13:36:37 +0100 <[exa]> oh worry not though. :]
2020-12-17 13:36:53 +0100 <fuzzypixelz> Please forgive my blasphemy
2020-12-17 13:37:22 +0100 <superstar64> fuzzypixelz, you might be interested in dogelang
2020-12-17 13:37:26 +0100 <idnar> fuzzypixelz: lambda byr: 1920 <= byr <= 2002 # a freebie
2020-12-17 13:37:55 +0100 <fuzzypixelz> I will definitely check it out superstar64, as in right now
2020-12-17 13:38:15 +0100 <[exa]> cheater: still the same problem with linking btw? (you might want to ask in #llvm, there will likely be more windowsy people)
2020-12-17 13:38:17 +0100 <superstar64> "With Haskell's syntax but none of its type system, dg is the best way to make fans of static typing shut up already"
2020-12-17 13:38:27 +0100 <cheater> [exa]: yes
2020-12-17 13:38:28 +0100 <int-e> fuzzypixelz: good luck with the AoC :P
2020-12-17 13:38:30 +0100 <fuzzypixelz> thanks idnar
2020-12-17 13:38:45 +0100 <cheater> the llvm channel was completely useless no one even uses windows there
2020-12-17 13:38:57 +0100 <int-e> or maybe :--< (split tongue)?
2020-12-17 13:39:28 +0100 <[exa]> cheater: why you want it to work on windows anyway? windows simply doesn't support a lot of stuff, done.
2020-12-17 13:39:35 +0100 <fuzzypixelz> int-e: I tried to do it with Haskell, but my tricks ran our on day 2, I just said what the heck I'll rewrite it later when I learn how to split a freaking string
2020-12-17 13:40:23 +0100 <int-e> :t words
2020-12-17 13:40:25 +0100 <lambdabot> String -> [String]
2020-12-17 13:40:34 +0100 <fuzzypixelz> huh
2020-12-17 13:40:38 +0100bliminse(~bliminse@host109-158-129-129.range109-158.btcentralplus.com)
2020-12-17 13:40:45 +0100 <[exa]> cheater: anyway if you can't apply various "linux subsystem for W" tricks, I'd suggest to write a nicely formatted error report to LLVM mailing list or something, so that the issue stays for more potential people to see
2020-12-17 13:40:51 +0100 <int-e> I've been abusing `words` a lot this year, including mapping commas to spaces and then using `words`.
2020-12-17 13:41:11 +0100 <[exa]> (or to the authors of the respective haskell wraps)
2020-12-17 13:41:28 +0100 <fuzzypixelz> int-e: but what if you need to split against specific chars?
2020-12-17 13:41:32 +0100 <[exa]> int-e: I'm still missing some variant of strtok()
2020-12-17 13:41:36 +0100 <idnar> :t splitOn
2020-12-17 13:41:37 +0100 <lambdabot> Eq a => [a] -> [a] -> [[a]]
2020-12-17 13:41:45 +0100 <cheater> int-e: are you the person who implemented that bug in cabal i was struggling with
2020-12-17 13:41:54 +0100 <int-e> splitOn is in the split package
2020-12-17 13:42:01 +0100 <int-e> cheater: I was talking AoC, not production code
2020-12-17 13:42:15 +0100 <int-e> cheater: so, no
2020-12-17 13:43:00 +0100 <fuzzypixelz> int-e: does it come with haskell platform?
2020-12-17 13:43:22 +0100 <idnar> > splitOn "," "foo,bar"
2020-12-17 13:43:24 +0100 <lambdabot> ["foo","bar"]
2020-12-17 13:43:34 +0100 <int-e> I don't really know what's included in the Haskell platform
2020-12-17 13:43:53 +0100 <int-e> it has cabal-install so to my mind it practically includes all of hackage
2020-12-17 13:44:41 +0100 <int-e> > words $ map (\c -> if c == ',' then ' ' else c) "foo,bar"
2020-12-17 13:44:43 +0100 <lambdabot> ["foo","bar"]
2020-12-17 13:44:52 +0100 <int-e> nasty, effective
2020-12-17 13:45:00 +0100 <superstar64> how do i make ghc warn me if a `data` could be a `newtype`?
2020-12-17 13:45:06 +0100 <int-e> , good enough for AoC
2020-12-17 13:45:10 +0100 <ski> > words (map (\c -> if c == ',' then ' ' else c) "foo,bar bar")
2020-12-17 13:45:12 +0100 <lambdabot> ["foo","bar","bar"]
2020-12-17 13:45:21 +0100 <int-e> ski: I know!
2020-12-17 13:45:42 +0100 <int-e> ski: include ,, for good measure
2020-12-17 13:46:33 +0100 <ski> escaping ?
2020-12-17 13:46:47 +0100 <int-e> > words " a b "
2020-12-17 13:46:50 +0100 <lambdabot> ["a","b"]
2020-12-17 13:47:08 +0100 <int-e> coalescing
2020-12-17 13:47:32 +0100 <int-e> > splitOn " " " a b "
2020-12-17 13:47:34 +0100 <lambdabot> ["","a","","b",""]
2020-12-17 13:47:47 +0100 <ski> @type Data.List.NonEmpty.words
2020-12-17 13:47:48 +0100 <lambdabot> error:
2020-12-17 13:47:48 +0100 <lambdabot> Not in scope: ‘Data.List.NonEmpty.words’
2020-12-17 13:47:48 +0100 <lambdabot> No module named ‘Data.List.NonEmpty’ is imported.
2020-12-17 13:49:24 +0100 <idnar> superstar64: use hlint I think
2020-12-17 13:49:24 +0100carlomagno(~cararell@148.87.23.8) (Remote host closed the connection)
2020-12-17 13:50:07 +0100 <ephemient> if you're working on Text, that has splitOn built-in
2020-12-17 13:50:36 +0100 <superstar64> alright, i'll look into it
2020-12-17 13:52:03 +0100 <ski> @type mapMaybe NE.nonEmpty . splitOn " "
2020-12-17 13:52:04 +0100 <lambdabot> [Char] -> [NE.NonEmpty Char]
2020-12-17 13:52:38 +0100 <ski> > (mapMaybe NE.nonEmpty . splitOn ",") "foo,bar baz,,quux"
2020-12-17 13:52:40 +0100 <lambdabot> ['f' :| "oo",'b' :| "ar baz",'q' :| "uux"]
2020-12-17 13:53:03 +0100 <int-e> ew
2020-12-17 13:53:21 +0100Kronic(~Kronic___@84.203.96.46)
2020-12-17 13:53:37 +0100 <int-e> . o O ( filter (not . null) )
2020-12-17 13:53:40 +0100todda7(~torstein@ppp-2-84-17-53.home.otenet.gr) (Quit: Konversation terminated!)
2020-12-17 13:54:24 +0100shf(~sheaf@2a01:cb19:80cc:7e00:ec10:402a:74e0:28d6) (Quit: Leaving)
2020-12-17 13:54:25 +0100 <ski> but then i have to use `NE.fromList' (which is partial)
2020-12-17 13:55:11 +0100 <int-e> I don't like NonEmpty, so why would I use that.
2020-12-17 13:55:52 +0100 <ski> well, the goal here was to look for a way to implement `Data.List.NonEmpty.words' ..
2020-12-17 13:56:30 +0100 <ski> (since the output elements of `words' are always non-empty)
2020-12-17 13:56:34 +0100 <int-e> yeah I should've stayed out of it, but couldn't help myself
2020-12-17 14:00:31 +0100ph88(~ph88@2a02:8109:9e00:7e5c:d5e6:6f2:2e3f:fbbc)
2020-12-17 14:00:54 +0100da39a3ee5e6b4b0d(~da39a3ee5@2403:6200:8876:cecf:4940:8dd3:7c10:4404) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2020-12-17 14:02:08 +0100 <ph88> when i want to make a tree structure is there some pattern to flatten the tree ? I was looking at monoid with mconcat which uses fold ... but im not sure if this is related
2020-12-17 14:03:44 +0100 <solonarv> ph88: it is indeed related. there's a reason that 'toList' is a method of the 'Foldable' class.
2020-12-17 14:05:14 +0100amerigo(uid331857@gateway/web/irccloud.com/x-qlwggbtbsclqlize) (Quit: Connection closed for inactivity)
2020-12-17 14:07:15 +0100 <dminuoso> In fact, arguably, toList could be a minimal method of Foldable
2020-12-17 14:07:35 +0100 <solonarv> it certainly could, it just wouldn't be a very good design (IMO)
2020-12-17 14:07:59 +0100 <lortabac> I think it's more a question of performance
2020-12-17 14:08:06 +0100 <dminuoso> Indeed.
2020-12-17 14:08:15 +0100 <dminuoso> If you have an elegant recursive way to build a list, you might as well just implement foldr directly.
2020-12-17 14:08:16 +0100 <solonarv> yes, performance is part of why it wouldn't be a good design
2020-12-17 14:09:13 +0100 <solonarv> I suppose build/foldr fusion would take care of it, if you write toList in terms of build
2020-12-17 14:10:02 +0100 <dminuoso> Well. if you write toList in terms of build...
2020-12-17 14:10:10 +0100 <ph88> i want to make my own data type .. what should i do to flatten the tree structure ? implement Foldabable ?
2020-12-17 14:10:13 +0100 <dminuoso> That's just a very very odd way of writing foldr..
2020-12-17 14:10:13 +0100sh9(~sh9@softbank060116136158.bbtec.net) (Quit: WeeChat 2.8)
2020-12-17 14:10:17 +0100 <solonarv> then you might as well just write foldr instead, yes :p
2020-12-17 14:10:32 +0100 <solonarv> ph88: yes, most likely. What does the data type look like?
2020-12-17 14:10:55 +0100 <ph88> solonarv, i don't have it yet, but should be a simple type with branches and leaves
2020-12-17 14:11:13 +0100 <solonarv> note that "implement Foldable" answers "where do I put my flattening function?", not "how do I write a flattening function in the first place"
2020-12-17 14:11:18 +0100 <ph88> data myTree = MyLeave | MyBranch (MyTree) something like this ?
2020-12-17 14:11:22 +0100 <dminuoso> Well thats not foldable
2020-12-17 14:11:28 +0100 <dminuoso> Foldable must be * -> * kinded.
2020-12-17 14:11:39 +0100 <ph88> oh
2020-12-17 14:11:46 +0100 <dminuoso> Also, that data type does not encode a list..
2020-12-17 14:11:50 +0100 <dminuoso> That just encodes peano naturals
2020-12-17 14:11:55 +0100 <dminuoso> *does not encode a tree.
2020-12-17 14:12:07 +0100 <ph88> what should i do then ?
2020-12-17 14:12:10 +0100 <dminuoso> At the very least you'd want `data MyTree = MyLeaf | MyBranch MyTree MyTree`
2020-12-17 14:12:16 +0100 <dminuoso> And then perhaps you want to attach values?
2020-12-17 14:12:27 +0100 <ph88> ye, i want some values
2020-12-17 14:12:31 +0100 <dminuoso> So `data MyTree a = MyLeaf a | MyBranch MyTree MyTree` for a leaf-valued binary tree
2020-12-17 14:12:51 +0100 <ph88> it's not a binary tree, should be rose tree ??
2020-12-17 14:12:57 +0100 <dminuoso> You tell us?
2020-12-17 14:13:16 +0100 <ephemient> *MyBranch (MyTree a) (MyTree a)
2020-12-17 14:13:20 +0100 <ephemient> (but the intent is clear)
2020-12-17 14:13:34 +0100 <ph88> ye there are more branches, and actually when you have one node with variable amount of branches, the order of those branches matter
2020-12-17 14:14:00 +0100 <ph88> MyBranch [MyTree] what about this ?
2020-12-17 14:14:38 +0100 <ephemient> ... no values, but sure
2020-12-17 14:14:42 +0100 <dminuoso> ph88: Do you want only the leafs to carry data, or each node?
2020-12-17 14:15:07 +0100geekosaur(ac3a3ed0@172.58.62.208)
2020-12-17 14:16:05 +0100 <ph88> each node carries data .. but for the flatten tree i only need the information in the leaves. But i need data in nodes later for other purposes
2020-12-17 14:16:57 +0100dddddd(~dddddd@unaffiliated/dddddd) (Quit: dddddd)
2020-12-17 14:17:13 +0100dddddd(~dddddd@unaffiliated/dddddd)
2020-12-17 14:17:17 +0100heatsink(~heatsink@2600:1700:bef1:5e10:64b4:1541:658f:e8d8)
2020-12-17 14:17:40 +0100Blackraider(~Blackraid@188.127.187.5)
2020-12-17 14:17:51 +0100wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
2020-12-17 14:17:52 +0100Blackraider(~Blackraid@188.127.187.5) (Remote host closed the connection)
2020-12-17 14:18:08 +0100kupi(uid212005@gateway/web/irccloud.com/x-mktflcfjzasruohy)
2020-12-17 14:21:14 +0100 <ph88> i found this package https://hackage.haskell.org/package/rose-trees what's this hash tree ?
2020-12-17 14:21:56 +0100heatsink(~heatsink@2600:1700:bef1:5e10:64b4:1541:658f:e8d8) (Ping timeout: 258 seconds)
2020-12-17 14:22:48 +0100wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Ping timeout: 256 seconds)
2020-12-17 14:24:01 +0100 <ph88> i'll come back later, i don't know what to do about this tree
2020-12-17 14:24:40 +0100jamm(~jamm@unaffiliated/jamm)
2020-12-17 14:26:35 +0100plutoniix(~q@184.82.198.131) (Quit: Leaving)
2020-12-17 14:28:43 +0100nbloomf(~nbloomf@2600:1700:ad14:3020:a8dc:3f5a:f8f1:dbd6)
2020-12-17 14:30:55 +0100 <superstar64> how do i get the path of the binary cabal generates when i run cabal build?
2020-12-17 14:32:32 +0100 <solonarv> superstar64: cabal exec where name-of-my-binary
2020-12-17 14:32:41 +0100 <solonarv> that'll give you the path
2020-12-17 14:32:51 +0100 <solonarv> if you want to copy it somewhere 'cabal install' can do that for you
2020-12-17 14:33:00 +0100da39a3ee5e6b4b0d(~da39a3ee5@2403:6200:8876:cecf:4940:8dd3:7c10:4404)
2020-12-17 14:33:01 +0100Miroboru(~myrvoll@78.91.103.180) (Read error: Connection reset by peer)
2020-12-17 14:35:16 +0100columbarius(~columbari@87.123.198.173) (Ping timeout: 240 seconds)
2020-12-17 14:35:42 +0100softwarm(4408f588@ip68-8-245-136.sd.sd.cox.net)
2020-12-17 14:35:49 +0100boxscape(4ff0ba59@gateway/web/cgi-irc/kiwiirc.com/ip.79.240.186.89)
2020-12-17 14:36:13 +0100aplainzetakind(~johndoe@captainludd.powered.by.lunarbnc.net) (Quit: Free ZNC ~ Powered by LunarBNC: https://LunarBNC.net)
2020-12-17 14:36:28 +0100 <boxscape> Is there a function like forM_ that allows me to stop the loop once a condition is met?
2020-12-17 14:36:37 +0100 <boxscape> If not I suppose writing it myself is fairly straightforward...
2020-12-17 14:36:46 +0100aplainzetakind(~johndoe@captainludd.powered.by.lunarbnc.net)
2020-12-17 14:37:18 +0100ubert(~Thunderbi@p200300ecdf35147ee6b318fffe838f33.dip0.t-ipconnect.de) (Ping timeout: 260 seconds)
2020-12-17 14:37:19 +0100da39a3ee5e6b4b0d(~da39a3ee5@2403:6200:8876:cecf:4940:8dd3:7c10:4404) (Client Quit)
2020-12-17 14:37:37 +0100gawen(~gawen@movzbl.root.sx) (Quit: cya)
2020-12-17 14:37:56 +0100columbarius(~columbari@87.123.198.173)
2020-12-17 14:38:00 +0100gawen(~gawen@movzbl.root.sx)
2020-12-17 14:39:56 +0100 <ephemient> boxscape: https://hackage.haskell.org/package/monad-loops ?
2020-12-17 14:40:32 +0100 <boxscape> hm yeah looks like there could be something in there, thanks
2020-12-17 14:41:03 +0100aplainzetakind(~johndoe@captainludd.powered.by.lunarbnc.net) (Client Quit)
2020-12-17 14:41:16 +0100Varis(~Tadas@unaffiliated/varis)
2020-12-17 14:42:12 +0100 <solonarv> boxscape: MaybeT could also do it, since "early exit" is exactly what that transformer does
2020-12-17 14:42:15 +0100aplainzetakind(~johndoe@captainludd.powered.by.lunarbnc.net)
2020-12-17 14:42:24 +0100 <boxscape> ah, I see
2020-12-17 14:43:03 +0100 <solonarv> :t \f xs -> runMaybeT (for_ xs (guard <=< lift . f))
2020-12-17 14:43:04 +0100 <lambdabot> error:
2020-12-17 14:43:04 +0100 <lambdabot> Variable not in scope: runMaybeT :: t0 m () -> t1
2020-12-17 14:43:20 +0100 <solonarv> @let import Control.Monad.Maybe.Trans
2020-12-17 14:43:20 +0100 <lambdabot> .L.hs:61:1: error:
2020-12-17 14:43:20 +0100 <lambdabot> Could not find module ‘Control.Monad.Maybe.Trans’
2020-12-17 14:43:21 +0100 <lambdabot> Perhaps you meant Control.Monad.Trans (from mtl-2.2.2)
2020-12-17 14:43:24 +0100 <solonarv> gah
2020-12-17 14:43:30 +0100 <solonarv> % :t \f xs -> runMaybeT (for_ xs (guard <=< lift . f))
2020-12-17 14:43:31 +0100 <yahb> solonarv: ; <interactive>:1:40: error:; Ambiguous occurrence `lift'; It could refer to; either `Language.Haskell.TH.Syntax.lift', imported from `Language.Haskell.TH.Syntax'; or `Control.Monad.Cont.lift', imported from `Control.Monad.Cont' (and originally defined in `Control.Monad.Trans.Class')
2020-12-17 14:43:53 +0100nbloomf(~nbloomf@2600:1700:ad14:3020:a8dc:3f5a:f8f1:dbd6) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2020-12-17 14:44:43 +0100 <solonarv> % :t \f xs -> runMaybeT (for_ xs (guard <=< MonadTrans.lift . f))
2020-12-17 14:44:44 +0100 <yahb> solonarv: ; <interactive>:1:10: error: Variable not in scope: runMaybeT :: t0 m () -> t1
2020-12-17 14:45:01 +0100 <boxscape> % :t \f xs -> Control.Monad.Trans.Maybe.runMaybeT (for_ xs (guard <=< Control.Monad.Cont.lift . f))
2020-12-17 14:45:01 +0100 <yahb> boxscape: (Foldable t, Monad m) => (a -> m Bool) -> t a -> m (Maybe ())
2020-12-17 14:45:03 +0100elfets(~elfets@ip-37-201-23-96.hsi13.unitymediagroup.de)
2020-12-17 14:45:59 +0100joaj(~joaj@2001:690:2100:110:cceb:227c:edbc:592c)
2020-12-17 14:46:15 +0100 <boxscape> % :t \f xs -> Control.Monad.Trans.Maybe.runMaybeT (for xs (Control.Monad.Cont.lift . f))
2020-12-17 14:46:15 +0100 <yahb> boxscape: (Traversable t, Monad m) => (a -> m b) -> t a -> m (Maybe (t b))
2020-12-17 14:46:19 +0100 <boxscape> this looks like what I want actually
2020-12-17 14:46:19 +0100da39a3ee5e6b4b0d(~da39a3ee5@2403:6200:8876:cecf:4940:8dd3:7c10:4404)
2020-12-17 14:46:20 +0100 <boxscape> thanks
2020-12-17 14:46:47 +0100 <solonarv> if you want "early exit with a value" that's ExceptT, of course
2020-12-17 14:46:47 +0100 <boxscape> or not quite
2020-12-17 14:46:52 +0100 <boxscape> I'll figure it out though
2020-12-17 14:47:02 +0100 <boxscape> I only need a value if it doesn't exit early
2020-12-17 14:47:35 +0100 <solonarv> ah, I see
2020-12-17 14:47:54 +0100 <ski> > (runIdentity . runExceptT . (`runStateT` 1) . forever) (do n <- get; put (2 * n); when (n > 1000) (throwError n))
2020-12-17 14:47:56 +0100 <lambdabot> Left 1024
2020-12-17 14:49:14 +0100 <ski> `Cont' sounds like overkill, unless you'd like to resume
2020-12-17 14:49:17 +0100carlomagno(~cararell@148.87.23.9)
2020-12-17 14:49:41 +0100 <int-e> @unmtl StateT s (ExceptT e Identity) a
2020-12-17 14:49:41 +0100 <lambdabot> s -> Either e (a, s)
2020-12-17 14:49:42 +0100 <ski> (i guess you could `Codensity')
2020-12-17 14:49:46 +0100fuzzypixelz(~fuzzypixe@eth-west-pareq2-46-193-4-100.wb.wifirst.net) (Quit: fuzzypixelz)
2020-12-17 14:50:14 +0100 <ski> oh, `unmtl' groks `ExceptT' now ?
2020-12-17 14:50:54 +0100fuzzypixelz(~fuzzypixe@eth-west-pareq2-46-193-4-100.wb.wifirst.net)
2020-12-17 14:53:00 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00)
2020-12-17 14:53:18 +0100 <int-e> apparently ;)
2020-12-17 14:53:27 +0100limpkin1(~limpkin@s91904426.blix.com) (Remote host closed the connection)
2020-12-17 14:54:43 +0100Hafydd(~Hafydd@unaffiliated/joo)
2020-12-17 14:55:08 +0100oish(~charlie@228.25.169.217.in-addr.arpa) (Ping timeout: 268 seconds)
2020-12-17 14:56:26 +0100oish(~charlie@228.25.169.217.in-addr.arpa)
2020-12-17 14:57:27 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00) (Ping timeout: 260 seconds)
2020-12-17 14:57:27 +0100geowiesnot(~user@i15-les02-ix2-87-89-181-157.sfr.lns.abo.bbox.fr)
2020-12-17 14:58:09 +0100proteus-guy(~proteusgu@cm-58-10-154-202.revip7.asianet.co.th)
2020-12-17 15:01:29 +0100ircbrowse_tom(~ircbrowse@64.225.78.177)
2020-12-17 15:01:29 +0100Server+CLnt
2020-12-17 15:01:34 +0100urodna(~urodna@unaffiliated/urodna)
2020-12-17 15:01:48 +0100adeln(~adeln@94.180.253.137) ()
2020-12-17 15:03:47 +0100ggole(~ggole@2001:8003:8119:7200:b1ce:df7:cb14:ba8f)
2020-12-17 15:03:49 +0100Stanley00(~stanley00@unaffiliated/stanley00) (Ping timeout: 264 seconds)
2020-12-17 15:09:17 +0100hyperisco(~hyperisco@d192-186-117-226.static.comm.cgocable.net)
2020-12-17 15:11:31 +0100xelxebar(~xelxebar@gateway/tor-sasl/xelxebar) (Remote host closed the connection)
2020-12-17 15:11:51 +0100xelxebar(~xelxebar@gateway/tor-sasl/xelxebar)
2020-12-17 15:15:14 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00) (Remote host closed the connection)
2020-12-17 15:15:20 +0100Vulfe_(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00)
2020-12-17 15:17:38 +0100zclod(9743c5d5@151.67.197.213)
2020-12-17 15:17:58 +0100wonko7(~wonko7@2a01:e35:2ffb:7040:4535:f480:7dff:b3b5)
2020-12-17 15:18:09 +0100phyll1s_work(~phyll1s_w@195.140.213.38)
2020-12-17 15:20:35 +0100 <zclod> hi I was trying to use recursion-schemes to solve some advent of code problems, my issue is that cata is a foldr while many of the challenges require left associative operations so i need to reverse the list first. is there a way to do a foldl with recursion scheme?
2020-12-17 15:23:31 +0100fuzzypixelz(~fuzzypixe@eth-west-pareq2-46-193-4-100.wb.wifirst.net) (Quit: fuzzypixelz)
2020-12-17 15:24:44 +0100taurux(~taurux@net-188-216-19-113.cust.vodafonedsl.it) (Ping timeout: 268 seconds)
2020-12-17 15:24:58 +0100taurux(~taurux@net-93-144-87-101.cust.dsl.teletu.it)
2020-12-17 15:25:22 +0100guest1217(~user@120.244.28.213)
2020-12-17 15:25:48 +0100bjobjo(~bjobjo@2a01:79c:cebf:d688::9e6) (Ping timeout: 246 seconds)
2020-12-17 15:26:13 +0100christo(~chris@81.96.113.213) (Remote host closed the connection)
2020-12-17 15:26:41 +0100 <boxscape> zclod this seems like it should https://stackoverflow.com/questions/57776420/top-down-recursion-schemes
2020-12-17 15:26:58 +0100geowiesnot(~user@i15-les02-ix2-87-89-181-157.sfr.lns.abo.bbox.fr) (Ping timeout: 272 seconds)
2020-12-17 15:27:02 +0100 <boxscape> help
2020-12-17 15:27:03 +0100 <guest1217> parseString = {do; spaces; x <- many letter; spaces; char '='; spaces; y <- many (satisfy (/= ' ')); spaces; return (x,y)}
2020-12-17 15:27:50 +0100 <boxscape> is there a fancy general lensy way to go over all the Ints in a pairs like (1,2,(3,4)) and (1,2(3,(4,5)))?
2020-12-17 15:27:52 +0100 <guest1217> parse (sepBy parseString spaces) "" "server=irc.freenode.net port=3 nick=john" == Right [("server","irc.freenode.net"),("port","3"),("nick","john")]
2020-12-17 15:28:43 +0100 <guest1217> parse (sepBy parseString newline) "" "server=irc.freenode.net\nport=3\nnick=john\n" == Right [("server","irc.freenode.net\nport=3\nnick=john\n")]
2020-12-17 15:29:00 +0100 <guest1217> why the second is not like the first?
2020-12-17 15:29:08 +0100 <guest1217> where it's wrong?
2020-12-17 15:29:28 +0100 <tomsmeding> guest1217: perhaps parseString accepts '\n' as part of a string?
2020-12-17 15:29:51 +0100 <tomsmeding> and so by the time the first parseString returns, the whole string has already been consumed
2020-12-17 15:30:18 +0100 <guest1217> tomsmeding: parse (anyChar *> newline *> anyChar) "" "a\nc" == Right 'c'
2020-12-17 15:30:41 +0100 <guest1217> oh
2020-12-17 15:31:10 +0100 <guest1217> tomsmeding: how I can change it?
2020-12-17 15:31:26 +0100 <tomsmeding> what's the source of parseString? or does it come from a library?
2020-12-17 15:31:40 +0100Mugisha(~Mugisha@154.73.41.12)
2020-12-17 15:31:52 +0100zclod(9743c5d5@151.67.197.213) (Remote host closed the connection)
2020-12-17 15:31:53 +0100 <inkbottle> Is there something like the STM monad for the dummies? (with nice pictures/diagrams)
2020-12-17 15:31:54 +0100 <guest1217> tomsmeding: parseString = {do; spaces; x <- many letter; spaces; char '='; spaces; y <- many (satisfy (/= ' ')); spaces; return (x,y)}
2020-12-17 15:32:27 +0100 <tomsmeding> that `satisfy (/= ' ')` accepts anything that's not a space, including, for example, newlines
2020-12-17 15:32:32 +0100 <Mugisha> Hi guys i'm new here and on irc
2020-12-17 15:32:50 +0100 <tomsmeding> guest1217: I suggest changing that (/= ' ') to (not . isSpace), where isSpace is from Data.Char
2020-12-17 15:32:51 +0100 <ski> hello Mugisha
2020-12-17 15:33:33 +0100 <guest1217> tomsmeding: satisfy (noneOf "\n ")?
2020-12-17 15:33:40 +0100 <tomsmeding> guest1217: or, of course, (/= '\n') if you only want to do newlines
2020-12-17 15:33:41 +0100 <tomsmeding> or that
2020-12-17 15:33:49 +0100 <tomsmeding> depending on what you need :)
2020-12-17 15:34:00 +0100 <guest1217> tomsmeding: space and newline
2020-12-17 15:34:05 +0100bitmagie(~Thunderbi@200116b80697370068b048f727c82739.dip.versatel-1u1.de)
2020-12-17 15:34:17 +0100 <guest1217> tomsmeding: how I can do it?
2020-12-17 15:34:24 +0100 <tomsmeding> well, like you just said
2020-12-17 15:35:11 +0100 <tomsmeding> also, the `spaces` at the end of `parseString` already swallows all spaces after the key=value pair, so the `spaces` in your `sepBy` will never consume anything
2020-12-17 15:35:24 +0100superstar64(6ccefa7c@108-206-250-124.lightspeed.miamfl.sbcglobal.net) ()
2020-12-17 15:35:38 +0100 <tomsmeding> so I think you can replace `sepBy parseString spaces` and `sepBy parseString newline` with `many parseString`
2020-12-17 15:35:46 +0100 <boxscape> loosk like tinplate works
2020-12-17 15:36:40 +0100 <boxscape> and template does as well
2020-12-17 15:36:57 +0100 <guest1217> tomsmeding: I tried `many (satisfy (noneOf "\n "))` noneOf applied too many arguments...
2020-12-17 15:37:10 +0100 <tomsmeding> ah right
2020-12-17 15:37:14 +0100 <tomsmeding> many (noneOf "\n ")
2020-12-17 15:37:24 +0100 <tomsmeding> noneOf is already a parser, no need to wrap it in 'satisfy'
2020-12-17 15:37:37 +0100jonathanx(~jonathan@dyn-8-sc.cdg.chalmers.se) (Remote host closed the connection)
2020-12-17 15:39:28 +0100 <guest1217> tomsmeding: parse (many parseString) "" "server=irc.freenode.net\nport=3\nnick=john\n" == Right [("server","irc.freenode.net"),("port","3"),("nick","john")]
2020-12-17 15:39:31 +0100jonathanx(~jonathan@dyn-8-sc.cdg.chalmers.se)
2020-12-17 15:39:52 +0100cosimone(~cosimone@2001:b07:ae5:db26:d849:743b:370b:b3cd)
2020-12-17 15:39:58 +0100nbloomf(~nbloomf@2600:1700:ad14:3020:a1f6:288c:9ca1:722b)
2020-12-17 15:40:18 +0100 <boxscape> hm is there a way to combine lenses, i.e. specifically to make a lens that operates on both _1 and _2?
2020-12-17 15:41:16 +0100jb55(~jb55@gateway/tor-sasl/jb55)
2020-12-17 15:42:43 +0100 <guest1217> tomsmeding: but why parse (sepBy parseString newline) "" "server = irc.freenode.net\nport = 3\nnick = john\n" == Right [("server","irc.freenode.net")], even I use `many (noneOf "\n ")`
2020-12-17 15:43:58 +0100 <tomsmeding> guest1217: I think because the `spaces` at the end of parseString already consumes the \n following "irc.freenode.net". By the time the `newline` in `sepBy parseString newline` is executed, the input is already at "port", meaning the `newline` doesn't match
2020-12-17 15:44:44 +0100gentauro(~gentauro@unaffiliated/gentauro) (Read error: Connection reset by peer)
2020-12-17 15:44:59 +0100 <tomsmeding> do you really need to support arbitrary newlines within your key=value lines? If not, perhaps it's a good idea to replace your uses of `spaces` within `parseString` with `many (satisfy (== ' '))`
2020-12-17 15:45:01 +0100gentauro(~gentauro@unaffiliated/gentauro)
2020-12-17 15:45:20 +0100 <tomsmeding> then the \n won't be consumed by parseString, and the sepBy gets to read it
2020-12-17 15:46:06 +0100jneira(501e6453@gateway/web/cgi-irc/kiwiirc.com/ip.80.30.100.83) (Ping timeout: 256 seconds)
2020-12-17 15:46:28 +0100 <hololeap> boxscape: so what, the getter/setter would return/take a tuple?
2020-12-17 15:46:32 +0100 <guest1217> tomsmeding: I remove the last spaces in parseString, then run it again, there's an error, it expecting white space, letter or "="
2020-12-17 15:46:49 +0100 <ski> > (1,2,(3,4)) ^.. (_1 <> _2 <> _3 . (_1 <> _2)) -- boxscape ?
2020-12-17 15:46:51 +0100 <lambdabot> [1,2,3,4]
2020-12-17 15:47:10 +0100 <tomsmeding> guest1217: oh right, that's the final \n at the end of your input
2020-12-17 15:47:31 +0100Sgeo(~Sgeo@ool-18b98aa4.dyn.optonline.net)
2020-12-17 15:47:32 +0100 <tomsmeding> perhaps not use `many parseString` but instead `many parseString <* spaces <* eof`
2020-12-17 15:47:33 +0100takuan(~takuan@178-116-218-225.access.telenet.be) (Ping timeout: 268 seconds)
2020-12-17 15:48:11 +0100Unhammer(~Unhammer@gateway/tor-sasl/unhammer) (Remote host closed the connection)
2020-12-17 15:48:53 +0100Unhammer(~Unhammer@gateway/tor-sasl/unhammer)
2020-12-17 15:51:41 +0100 <boxscape> hololeap ski basically I want to be able to say something like `(1,2,3) & _1 `combine` _2 %~ (+3)' and end up with (5,6,3)
2020-12-17 15:52:27 +0100geekosaur(ac3a3ed0@172.58.62.208) (Remote host closed the connection)
2020-12-17 15:52:35 +0100 <boxscape> uh
2020-12-17 15:52:40 +0100 <iqubic> Where does the 5 come from?
2020-12-17 15:52:42 +0100 <boxscape> s/(+3)/(+4)
2020-12-17 15:52:53 +0100 <boxscape> yeah I can't do basic arithmetic apparently
2020-12-17 15:52:57 +0100 <guest1217> tomsmeding: if I want `sepBy parseString newline` work, how I should change parseString?
2020-12-17 15:52:58 +0100 <iqubic> Oh. I see.
2020-12-17 15:53:28 +0100 <iqubic> boxscape: That looks hard to do.
2020-12-17 15:53:39 +0100 <tomsmeding> guest1217: read carefully what I said before :)
2020-12-17 15:53:47 +0100 <tomsmeding> I suggested what I think is the right change
2020-12-17 15:54:12 +0100 <ski> Mugisha : if you have any (Haskell-related) question, feel free to ask
2020-12-17 15:54:25 +0100shf(~sheaf@2a01:cb19:80cc:7e00:c826:d438:7383:b3d6)
2020-12-17 15:54:34 +0100 <guest1217> tomsmeding: final "\n" in the input?
2020-12-17 15:54:50 +0100 <iqubic> boxscape: Essentially you want a function that takes two lenses and makes a traversal over both things.
2020-12-17 15:55:06 +0100 <boxscape> that sounds right
2020-12-17 15:55:44 +0100 <iqubic> > (1,2,3) & each %~ (+4)
2020-12-17 15:55:46 +0100 <lambdabot> (5,6,7)
2020-12-17 15:55:50 +0100 <tomsmeding> guest1217: https://ircbrowse.tomsmeding.com/selection/haskell?title=Conversation&events=203120,203122,203124
2020-12-17 15:56:14 +0100 <guest1217> tomsmeding: I tried to instead spaces with many (satisfy (== ' ')), sepBy won't work
2020-12-17 15:56:16 +0100 <iqubic> The issue with `each` is that it will traverse *all* elements in the structure.
2020-12-17 15:56:20 +0100 <boxscape> right
2020-12-17 15:57:14 +0100Mugisha(~Mugisha@154.73.41.12) (Ping timeout: 260 seconds)
2020-12-17 15:57:32 +0100matryoshka(~matryoshk@184.75.223.227)
2020-12-17 15:57:52 +0100 <iqubic> boxscape: I found this with a quick search: https://stackoverflow.com/questions/17528119/combining-lenses
2020-12-17 15:58:16 +0100 <boxscape> iqubic hm, thanks
2020-12-17 15:58:21 +0100 <iqubic> Also this: https://github.com/ekmett/lens/issues/109
2020-12-17 15:58:54 +0100 <boxscape> hm some interesting discussion there
2020-12-17 15:59:06 +0100shf(~sheaf@2a01:cb19:80cc:7e00:c826:d438:7383:b3d6) (Read error: Connection reset by peer)
2020-12-17 15:59:40 +0100 <guest1217> tomsmeding: you're right, I remove the last sapces and replace spaces with many (satisfy (== ' ')), now sepBy work
2020-12-17 15:59:50 +0100 <guest1217> tomsmeding: thank you
2020-12-17 16:00:14 +0100 <tomsmeding> guest1217: cool! Note that if you do that, you won't accept ' ' characters at the end of a line
2020-12-17 16:00:27 +0100 <iqubic> boxscape: I'm sorry you can't really do what you want to do.
2020-12-17 16:00:36 +0100 <boxscape> oh well
2020-12-17 16:00:48 +0100 <dminuoso> Id love to have monthly download statistics.
2020-12-17 16:01:00 +0100 <dminuoso> Bet you'd always see *parsec jumping up in december every year. :>
2020-12-17 16:01:18 +0100 <merijn> :p
2020-12-17 16:01:20 +0100 <iqubic> Oh totally.
2020-12-17 16:01:22 +0100 <tomsmeding> where * matches a non-zero length string, I guess?
2020-12-17 16:01:27 +0100 <dminuoso> tomsmeding: Yes.
2020-12-17 16:01:33 +0100 <dminuoso> Err. Not necessarily
2020-12-17 16:01:35 +0100notzmv`(~user@191.205.12.9)
2020-12-17 16:01:48 +0100 <tomsmeding> because parsec itself is bundled with ghc, you're unlikely to download that often :p
2020-12-17 16:01:57 +0100 <dminuoso> That depends on the version, though.
2020-12-17 16:02:10 +0100 <iqubic> What?! Parsec is bundled with GHC? I didn't know that.
2020-12-17 16:02:11 +0100notzmv(~user@unaffiliated/zmv) (Read error: Connection reset by peer)
2020-12-17 16:02:20 +0100kish`(~oracle@unaffiliated/oracle)
2020-12-17 16:02:34 +0100jamm(~jamm@unaffiliated/jamm) (Remote host closed the connection)
2020-12-17 16:02:41 +0100 <iqubic> I just use Megaparsec, because 1. I love the error messages I get, and 2. I love that unit of measurement.
2020-12-17 16:02:50 +0100 <boxscape> iqubic turns out `template` is actually even better for what I had intended than a combination of _1 and _2
2020-12-17 16:03:01 +0100 <iqubic> What is template?
2020-12-17 16:03:08 +0100 <iqubic> :t template
2020-12-17 16:03:10 +0100 <lambdabot> (Data s, Applicative f, Typeable a) => (a -> f a) -> s -> f s
2020-12-17 16:03:16 +0100 <iqubic> Ah. Yes. I see.
2020-12-17 16:03:19 +0100 <tomsmeding> iqubic: I think this is a source of that information: https://gitlab.haskell.org/ghc/ghc/-/blob/master/packages
2020-12-17 16:03:19 +0100 <ephemient> http://hackage.haskell.org/package/parsec old parsec, not megaparsec, is bundled. I prefer using the latter
2020-12-17 16:03:24 +0100 <boxscape> % (1,2,(2,(3,4))) & template %~ (+1)
2020-12-17 16:03:24 +0100 <yahb> boxscape: (2,3,(3,(4,5)))
2020-12-17 16:03:33 +0100jamm(~jamm@unaffiliated/jamm)
2020-12-17 16:03:45 +0100oish(~charlie@228.25.169.217.in-addr.arpa) (Ping timeout: 240 seconds)
2020-12-17 16:04:23 +0100 <tomsmeding> iqubic: according to this wiki page ( https://gitlab.haskell.org/ghc/ghc/-/wikis/commentary/libraries ), a '-' in the tag column indicates a ghc boot library
2020-12-17 16:04:48 +0100Unhammer(~Unhammer@gateway/tor-sasl/unhammer) (Remote host closed the connection)
2020-12-17 16:04:49 +0100 <tomsmeding> also before I knew what cabal even was, properly, I've been using parsec without problems :p
2020-12-17 16:04:54 +0100 <ephemient> GHC also comes with ReadP
2020-12-17 16:04:56 +0100 <dminuoso> iqubic: I find the tuple (megaparsec, attoparsec, binary) to be a suitable set of tools for most purposes. :)
2020-12-17 16:05:04 +0100 <iqubic> boxscape: template will create a traversal that targets all elements of a given type, regardless of where they appear in the structure.
2020-12-17 16:05:09 +0100 <boxscape> yes
2020-12-17 16:05:12 +0100 <dminuoso> Neither is enough to cover all needs.
2020-12-17 16:05:39 +0100 <iqubic> boxscape: What are you doing with this?
2020-12-17 16:05:56 +0100 <boxscape> iqubic making the bounds of my array for AOC today smaller
2020-12-17 16:06:01 +0100 <iqubic> How?
2020-12-17 16:07:19 +0100kish`(~oracle@unaffiliated/oracle) (Quit: Leaving)
2020-12-17 16:07:36 +0100stef204(~stef204@unaffiliated/stef-204/x-384198)
2020-12-17 16:07:39 +0100 <boxscape> iqubic well, not the actual bounds, but the bounds of the cells I check. I first take the bounds of the entire array and then say let bounds' = bounds & bounds & _1 . template +~ s - 1 & _2 . template -~ s - 1, where s is the number of steps left to perform, so as that number goes down, the number of cells I check gets higher
2020-12-17 16:07:40 +0100 <guest1217> how I can turn Right [("a","b")] to fromList [("a","b")]? transparent transform?
2020-12-17 16:08:01 +0100star_cloud(~star_clou@ec2-34-220-44-120.us-west-2.compute.amazonaws.com) (Ping timeout: 264 seconds)
2020-12-17 16:08:12 +0100 <guest1217> or Right (fromList [("a","b")])?
2020-12-17 16:08:17 +0100coot(~coot@37.30.50.101.nat.umts.dynamic.t-mobile.pl) (Quit: coot)
2020-12-17 16:08:21 +0100 <dminuoso> guest1217: fmap fromList
2020-12-17 16:08:22 +0100 <ski> guest1217 : what should happen on `Left' ?
2020-12-17 16:08:22 +0100 <boxscape> iqubic whoops one of those `bounds &` shouldn't be there
2020-12-17 16:08:26 +0100jamm(~jamm@unaffiliated/jamm) (Ping timeout: 264 seconds)
2020-12-17 16:08:40 +0100coot(~coot@37.30.50.101.nat.umts.dynamic.t-mobile.pl)
2020-12-17 16:08:56 +0100 <guest1217> ski: I don't know...
2020-12-17 16:09:03 +0100 <iqubic> ski: I assume that Right [("a","b")] is the result from calling parse.
2020-12-17 16:09:19 +0100 <guest1217> iqubic: yes
2020-12-17 16:09:29 +0100 <guest1217> I need to get the value by the key
2020-12-17 16:09:29 +0100 <iqubic> In that case, I recommend applying fmap *before* running the parser.
2020-12-17 16:09:34 +0100 <ski> if `Right (fromList [("a","b")])' is ok as result, then what dminuoso said (if `Left', then it'll not be changed)
2020-12-17 16:09:49 +0100 <iqubic> :t parse
2020-12-17 16:09:51 +0100 <lambdabot> error: Variable not in scope: parse
2020-12-17 16:11:13 +0100 <guest1217> dminuoso: yes, fmap fromList (Right ...) is ok
2020-12-17 16:11:31 +0100 <boxscape> iqubic btw each wouldn't work because my index is either (x,y,z) or (x,y,(z,w)) depending on dimension, but template works nicely with that. I thought at first I could only apply this optimization to the first two dimensions, hence trying to combine _1 and _2
2020-12-17 16:11:39 +0100 <guest1217> what about Right [...] to fromList [...]?
2020-12-17 16:11:46 +0100cfricke(~cfricke@unaffiliated/cfricke) (Quit: WeeChat 3.0)
2020-12-17 16:11:49 +0100 <guest1217> fromRight?
2020-12-17 16:12:07 +0100 <iqubic> No. Just use fmap there.
2020-12-17 16:12:39 +0100fuzzypixelz(~fuzzypixe@eth-west-pareq2-46-193-4-100.wb.wifirst.net)
2020-12-17 16:12:49 +0100 <guest1217> iqubic: why fromRight and (~>) is not ok?
2020-12-17 16:13:52 +0100 <iqubic> fromRight will give you an error if the argument is Left.
2020-12-17 16:13:59 +0100star_cloud(~star_clou@ec2-34-220-44-120.us-west-2.compute.amazonaws.com)
2020-12-17 16:14:07 +0100ubert(~Thunderbi@p200300ecdf35147ee6b318fffe838f33.dip0.t-ipconnect.de)
2020-12-17 16:14:12 +0100 <merijn> s/give you an error/crash your program
2020-12-17 16:15:01 +0100 <guest1217> and (~>)?
2020-12-17 16:15:18 +0100 <iqubic> I don't know what that is.
2020-12-17 16:15:29 +0100 <guest1217> natural transform?
2020-12-17 16:15:45 +0100 <iqubic> Yeah, you don't want a natural transformation here.
2020-12-17 16:15:58 +0100 <dminuoso> You seem to be conflating terminology here. :)
2020-12-17 16:16:39 +0100 <dminuoso> A natural transformation `S ~> T` is any function `S a -> T a`, assuming both S and T are both functors.
2020-12-17 16:16:47 +0100 <iqubic> I assume they are talking about this: https://hackage.haskell.org/package/natural-transformation-0.4/docs/Control-Natural.html#t:-126--62-
2020-12-17 16:16:48 +0100wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
2020-12-17 16:17:29 +0100 <guest1217> Right is a functor, fromList is not a functor?
2020-12-17 16:17:35 +0100 <dminuoso> guest1217: Right is not a functor.
2020-12-17 16:17:36 +0100kish`(~oracle@unaffiliated/oracle)
2020-12-17 16:17:49 +0100 <merijn> Types are functors. Neither Right no "fromList" are types
2020-12-17 16:17:55 +0100 <guest1217> Either a is a functor
2020-12-17 16:17:59 +0100 <dminuoso> Correct.
2020-12-17 16:18:02 +0100 <dminuoso> Or `Maybe`
2020-12-17 16:18:14 +0100 <dminuoso> So a function `Either a ~> Maybe` would be a natural transformation.
2020-12-17 16:18:22 +0100 <dminuoso> Or: Maybe ~> []
2020-12-17 16:18:36 +0100 <dminuoso> That is, `Either a b -> Maybe b` or `Maybe b -> [b]`
2020-12-17 16:18:45 +0100 <iqubic> Here's the main issue he's trying to solve. He has a Parser [(a, b)] and wants a Parser (Map a b)
2020-12-17 16:18:45 +0100 <guest1217> what is Map?
2020-12-17 16:18:52 +0100heatsink(~heatsink@2600:1700:bef1:5e10:64b4:1541:658f:e8d8)
2020-12-17 16:19:04 +0100 <guest1217> Map a is a functor?
2020-12-17 16:19:05 +0100 <dminuoso> No
2020-12-17 16:19:16 +0100 <dminuoso> Or.. mm. `Map a` is actually I think
2020-12-17 16:19:20 +0100 <dminuoso> I was thinking Set. :)
2020-12-17 16:19:28 +0100 <merijn> dminuoso: Map k is a functor, yes
2020-12-17 16:19:37 +0100 <merijn> dminuoso: Also Foldable and Traversable!
2020-12-17 16:19:37 +0100 <dminuoso> merijn: Yeah, my head is so wired to Set at the moment
2020-12-17 16:19:41 +0100 <iqubic> Map k is a functor, but that's not going to help you here.
2020-12-17 16:19:51 +0100 <dminuoso> merijn: being Foldable is easy, Traversable not so much. :p
2020-12-17 16:20:25 +0100 <iqubic> All he needs is a function of the type "Parser [(k,v)] -> Parse (Map k v)"
2020-12-17 16:20:27 +0100 <guest1217> so Either a and Map k both are functors here, and it still can't turn Right a to fromList a?
2020-12-17 16:20:41 +0100 <iqubic> guest1217: ~> is not a function.
2020-12-17 16:21:03 +0100 <guest1217> iqubic: ok...
2020-12-17 16:21:26 +0100Noughtmare[m](naughtmare@gateway/shell/matrix.org/x-fpxdgixxyxyfpjbh)
2020-12-17 16:21:56 +0100tab65(49819d19@c-73-129-157-25.hsd1.dc.comcast.net)
2020-12-17 16:22:09 +0100fendor_(~fendor@77.119.130.146.wireless.dyn.drei.com)
2020-12-17 16:22:14 +0100Unhammer(~Unhammer@gateway/tor-sasl/unhammer)
2020-12-17 16:22:14 +0100 <dminuoso> guest1217: The point here is, think of it in terms of functions. Let's say you have a function that can turn a `Right a` into `fromList a`, what would that function's type be?
2020-12-17 16:22:39 +0100 <guest1217> Either a b -> Map a b?
2020-12-17 16:22:56 +0100tab65(49819d19@c-73-129-157-25.hsd1.dc.comcast.net) (Remote host closed the connection)
2020-12-17 16:22:56 +0100 <dminuoso> Somewhat close, but not quite.
2020-12-17 16:23:21 +0100 <merijn> eh, this seems to just be a random walk through all possible formulations...[
2020-12-17 16:23:30 +0100 <dminuoso> Yeah..
2020-12-17 16:23:47 +0100heatsink(~heatsink@2600:1700:bef1:5e10:64b4:1541:658f:e8d8) (Ping timeout: 260 seconds)
2020-12-17 16:23:52 +0100 <ephemient> `uncurry Map.singleton :: (a, b) -> Map a b` does exist
2020-12-17 16:23:55 +0100 <guest1217> then I don't know
2020-12-17 16:23:56 +0100kish`(~oracle@unaffiliated/oracle) (Ping timeout: 268 seconds)
2020-12-17 16:24:07 +0100 <ephemient> but `Either a b` and `(a, b)` are pretty different
2020-12-17 16:24:21 +0100 <Vulfe_> they are about as different as two things can be using the same letters
2020-12-17 16:24:58 +0100fendor(~fendor@77.119.130.134.wireless.dyn.drei.com) (Ping timeout: 256 seconds)
2020-12-17 16:26:41 +0100 <iqubic> guest1217: What are you trying to do?
2020-12-17 16:27:06 +0100xsperry(~as@unaffiliated/xsperry)
2020-12-17 16:27:26 +0100 <guest1217> iqubic: like you said, turn Right a to fromList a
2020-12-17 16:27:52 +0100 <tomsmeding> are you sure you're not wanting to turn 'Right a' into 'Right (fromList a)'?
2020-12-17 16:27:56 +0100 <iqubic> Why are you trying to do that? How did you get a `Right a` value?
2020-12-17 16:28:46 +0100 <guest1217> get Right a by parser...
2020-12-17 16:28:54 +0100 <ephemient> what do you expect to happen with a Left _?
2020-12-17 16:29:26 +0100 <guest1217> tomsmeding: I think I should use Right (fromList a) now
2020-12-17 16:29:27 +0100 <dminuoso> Im thinking you have piled up too many tools and bits that confuse you.
2020-12-17 16:30:09 +0100 <guest1217> yes, there're too many things I don't understand now
2020-12-17 16:30:22 +0100 <iqubic> Look, what he wants to do is take the result of his parser and turn it into a Map. I think he should use (fmap fromList) *before* parsing the string into a "Right a"
2020-12-17 16:30:28 +0100 <dminuoso> Good. So perhaps it's helpful to backtrack to the last spot where you felt comfortable and understood bits.
2020-12-17 16:30:31 +0100 <guest1217> ephemient: I don't know
2020-12-17 16:33:02 +0100ph88(~ph88@2a02:8109:9e00:7e5c:d5e6:6f2:2e3f:fbbc) (Ping timeout: 264 seconds)
2020-12-17 16:33:10 +0100hf69(~haskeller@ip72-205-40-121.dc.dc.cox.net)
2020-12-17 16:35:56 +0100jess(jess@freenode/staff/jess) (Quit: updates)
2020-12-17 16:36:40 +0100cosimone(~cosimone@2001:b07:ae5:db26:d849:743b:370b:b3cd) (Remote host closed the connection)
2020-12-17 16:37:04 +0100cosimone(~cosimone@2001:b07:ae5:db26:d849:743b:370b:b3cd)
2020-12-17 16:37:28 +0100 <dminuoso> Is there a way to detect unused package dependencies?
2020-12-17 16:38:05 +0100jamm(~jamm@unaffiliated/jamm)
2020-12-17 16:38:19 +0100 <merijn> dminuoso: Comment them out *duck*
2020-12-17 16:40:17 +0100 <Orbstheorem> Hi, is there any way to have stack compile a small c++ program with my haskell project?
2020-12-17 16:40:27 +0100 <merijn> Orbstheorem: Flee now
2020-12-17 16:40:29 +0100tomsmedingwonders what an optimal algorithm to figure out unused dependencies would be, if all you could do is commenting them out and trying the build
2020-12-17 16:40:41 +0100 <merijn> Orbstheorem: In short: No
2020-12-17 16:40:44 +0100 <Orbstheorem> xDD
2020-12-17 16:40:54 +0100 <Orbstheorem> Alright, what's the longer answer? x)
2020-12-17 16:40:55 +0100 <tomsmeding> well, yes, that's possible
2020-12-17 16:41:01 +0100 <tomsmeding> whether you want it is another question
2020-12-17 16:41:03 +0100 <merijn> Orbstheorem: In long: This is a cursed question I tried to get working for a week and gave up
2020-12-17 16:41:06 +0100 <merijn> tomsmeding: It's not
2020-12-17 16:41:21 +0100 <tomsmeding> depends on your definition of "working"
2020-12-17 16:41:27 +0100 <merijn> tomsmeding: Or rather, it may work if your C compiler is *also* a C++ compiler and doesn't throw a fit
2020-12-17 16:41:47 +0100 <Orbstheorem> I'm stuck between adding a makefile and adding it to stack, but I find adding a makefile to essentially call stack dirty...
2020-12-17 16:41:48 +0100 <tomsmeding> okay I was naively assuming C++ wouldn't be harder than C
2020-12-17 16:41:59 +0100 <Orbstheorem> For the records, my C++ file is standalone.
2020-12-17 16:42:21 +0100 <merijn> tomsmeding: GHC knows about C compilers, it only half knows about C++ compilers, I have a few GHC issues about this
2020-12-17 16:42:36 +0100 <tomsmeding> TIL
2020-12-17 16:43:03 +0100 <merijn> Orbstheorem: I have a much larger C++ codebase, but I just use my own gmake build system for that and call cabal-install from there
2020-12-17 16:43:14 +0100 <Orbstheorem> :(
2020-12-17 16:43:27 +0100geowiesnot(~user@i15-les02-ix2-87-89-181-157.sfr.lns.abo.bbox.fr)
2020-12-17 16:43:30 +0100 <Orbstheorem> Ideally I'd package it in different packages, but it's for a course.
2020-12-17 16:43:43 +0100 <merijn> Orbstheorem: Unless you are willing to make a few (most likely relatively simple) patches to GHC there's no really good way
2020-12-17 16:43:49 +0100 <Orbstheorem> Aaaaand, well... I'm not doing a package for one-file executable.
2020-12-17 16:44:14 +0100 <Orbstheorem> merijn: I'm curious xD
2020-12-17 16:44:16 +0100 <tomsmeding> define "package"
2020-12-17 16:44:22 +0100 <tomsmeding> if we're mixing C++ and haskell
2020-12-17 16:44:26 +0100 <Orbstheorem> `dpkg -i foo`
2020-12-17 16:44:32 +0100 <tomsmeding> I see
2020-12-17 16:44:43 +0100 <Orbstheorem> C++ generates an executable my haskell code will call from PATH.
2020-12-17 16:45:11 +0100 <Orbstheorem> (It could be rewritten, but I'm not allowed to :/)
2020-12-17 16:45:13 +0100 <merijn> Not sure how well stack plays with Makefile, but cabal-install's v2-build has intentionally been designed to be super fast on noop builds so you can unconditionally call it in make
2020-12-17 16:45:59 +0100da39a3ee5e6b4b0d(~da39a3ee5@2403:6200:8876:cecf:4940:8dd3:7c10:4404) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2020-12-17 16:46:10 +0100Jesin(~Jesin@pool-72-66-101-18.washdc.fios.verizon.net) (Ping timeout: 256 seconds)
2020-12-17 16:46:12 +0100 <Orbstheorem> stack run takes 6 seconds on my system (NixOS 20.09) on a no-op.
2020-12-17 16:46:22 +0100 <Orbstheorem> stack ghci is much faster though.
2020-12-17 16:47:49 +0100shf(~sheaf@2a01:cb19:80cc:7e00:3d51:cce0:e1c5:49b6)
2020-12-17 16:48:44 +0100cosimone(~cosimone@2001:b07:ae5:db26:d849:743b:370b:b3cd) (Quit: cosimone)
2020-12-17 16:49:20 +0100cosimone(~cosimone@5.170.241.91)
2020-12-17 16:49:55 +0100 <merijn> Orbstheorem: Anyway, I'd just make a make file that builds the C++ exe and calls stack
2020-12-17 16:50:00 +0100ph88(~ph88@2a02:8109:9e00:7e5c:d5e6:6f2:2e3f:fbbc)
2020-12-17 16:51:12 +0100pavonia(~user@unaffiliated/siracusa) (Quit: Bye!)
2020-12-17 16:52:29 +0100 <boxscape> huh indexing my STUArray with (x, (y, (z, (w, ())))) instead of (x, y, (z, (w, ()))) *doubles* the runtime of my program, interesting
2020-12-17 16:52:47 +0100 <Orbstheorem> Is the really scary way of doing it using Setup.hs and calling g++ from haskell code? x)
2020-12-17 16:53:07 +0100 <merijn> Orbstheorem: Why use Setup.hs at all
2020-12-17 16:53:18 +0100 <merijn> Orbstheorem: Can just have your main program compile with g++ on demand
2020-12-17 16:53:27 +0100 <merijn> (in fact, I literally do that in some code :p)
2020-12-17 16:53:35 +0100 <Orbstheorem> Nah, that sounds horrible x)
2020-12-17 16:53:57 +0100 <Orbstheorem> I'm not saying I won't
2020-12-17 16:54:10 +0100 <Orbstheorem> I just wanna see what's available and make my pick later x)
2020-12-17 16:54:17 +0100 <Orbstheorem> (Yes, I'm lazy)
2020-12-17 16:56:17 +0100 <ephemient> https://hackage.haskell.org/package/inline-c-cpp :P
2020-12-17 16:57:26 +0100coot(~coot@37.30.50.101.nat.umts.dynamic.t-mobile.pl) (Quit: coot)
2020-12-17 16:57:27 +0100LKoen(~LKoen@29.248.88.92.rev.sfr.net) (Remote host closed the connection)
2020-12-17 16:57:46 +0100coot(~coot@37.30.50.101.nat.umts.dynamic.t-mobile.pl)
2020-12-17 16:59:57 +0100Stanley00(~stanley00@unaffiliated/stanley00)
2020-12-17 17:01:38 +0100 <ph88> how can i go from this function https://hackage.haskell.org/package/Frames-streamly-0.1.0.2/docs/Frames-Streamly-CSV.html#v:readTa… to a Vector of my own datatype representing that row ?
2020-12-17 17:01:50 +0100royal_screwup21(52254809@gateway/web/cgi-irc/kiwiirc.com/ip.82.37.72.9)
2020-12-17 17:02:03 +0100guest1217(~user@120.244.28.213) (Quit: ERC (IRC client for Emacs 26.3))
2020-12-17 17:04:00 +0100jlamothe(~jlamothe@198.251.55.207)
2020-12-17 17:04:56 +0100codeAlways(uid272474@gateway/web/irccloud.com/x-uaxhttwxpgbyaiuf)
2020-12-17 17:05:01 +0100Stanley00(~stanley00@unaffiliated/stanley00) (Ping timeout: 272 seconds)
2020-12-17 17:06:22 +0100Ariakenom_(~Ariakenom@2001:9b1:efb:fc00:c9f8:3d5b:f807:f873)
2020-12-17 17:09:25 +0100dax(dax@bitbot/dax) (Quit: updates)
2020-12-17 17:11:13 +0100cosimone_(~cosimone@2001:b07:ae5:db26:d849:743b:370b:b3cd)
2020-12-17 17:11:16 +0100dbmikus(~dbmikus@c-174-49-172-14.hsd1.pa.comcast.net)
2020-12-17 17:11:26 +0100 <dminuoso> Mmm, if I write `f == g && x == y` can I reasonably expect the first equality to be tested first?
2020-12-17 17:11:26 +0100xff0x(~fox@2001:1a81:5260:ab00:d700:e460:f864:a3a3) (Ping timeout: 264 seconds)
2020-12-17 17:11:29 +0100fuzzypixelz(~fuzzypixe@eth-west-pareq2-46-193-4-100.wb.wifirst.net) (Quit: fuzzypixelz)
2020-12-17 17:11:53 +0100xff0x(~fox@2001:1a81:5260:ab00:b5e4:2313:abc1:f0cb)
2020-12-17 17:12:18 +0100 <dminuoso> % True && undefined
2020-12-17 17:12:18 +0100 <yahb> dminuoso: *** Exception: Prelude.undefined; CallStack (from HasCallStack):; error, called at libraries/base/GHC/Err.hs:79:14 in base:GHC.Err; undefined, called at <interactive>:22:9 in interactive:Ghci7
2020-12-17 17:12:27 +0100 <ephemient> yes
2020-12-17 17:12:41 +0100 <ephemient> http://hackage.haskell.org/package/base-4.14.1.0/docs/Prelude.html#v:-38--38- "lazy in the second argument"
2020-12-17 17:12:45 +0100 <dminuoso> yeah but..
2020-12-17 17:12:50 +0100 <dminuoso> what does "lazy in the second argument" even mean here?
2020-12-17 17:13:04 +0100 <dminuoso> Oh
2020-12-17 17:13:10 +0100 <dminuoso> % False && undefined
2020-12-17 17:13:10 +0100 <yahb> dminuoso: False
2020-12-17 17:13:13 +0100 <dminuoso> I see.
2020-12-17 17:13:24 +0100 <dminuoso> I forgot (&&) is a function.
2020-12-17 17:13:28 +0100 <merijn> dminuoso: lol
2020-12-17 17:13:39 +0100 <merijn> dminuoso: Sounds like time for a break :p
2020-12-17 17:13:49 +0100cosimone(~cosimone@5.170.241.91) (Read error: Connection reset by peer)
2020-12-17 17:13:49 +0100cosimone_cosimone
2020-12-17 17:14:20 +0100 <dminuoso> Yeah tell me about it.
2020-12-17 17:14:30 +0100chang(~textual@host-173-230-65-85.njjcmar.clients.pavlovmedia.com) (Quit: Textual IRC Client: www.textualapp.com)
2020-12-17 17:14:36 +0100 <Orbstheorem> ephemient: That's sounds like I can be even lazier :D
2020-12-17 17:14:41 +0100chang(~textual@host-173-230-65-85.njjcmar.clients.pavlovmedia.com)
2020-12-17 17:14:49 +0100christo(~chris@81.96.113.213)
2020-12-17 17:16:05 +0100dbmikus(~dbmikus@c-174-49-172-14.hsd1.pa.comcast.net) (Ping timeout: 240 seconds)
2020-12-17 17:16:18 +0100royal_screwup21(52254809@gateway/web/cgi-irc/kiwiirc.com/ip.82.37.72.9) (Quit: Connection closed)
2020-12-17 17:16:40 +0100royal_screwup21(52254809@gateway/web/cgi-irc/kiwiirc.com/ip.82.37.72.9)
2020-12-17 17:19:02 +0100wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Ping timeout: 256 seconds)
2020-12-17 17:19:37 +0100 <dsal> inkbottle: STM is quite easy. Is there a particular problem you're having? The O'Reily book covers it somewhat, but there's not much to it.
2020-12-17 17:24:47 +0100dbmikus(~dbmikus@c-174-49-172-14.hsd1.pa.comcast.net)
2020-12-17 17:25:21 +0100softwarm(4408f588@ip68-8-245-136.sd.sd.cox.net) (Remote host closed the connection)
2020-12-17 17:25:46 +0100nhs(~nhs@c-67-180-177-103.hsd1.ca.comcast.net)
2020-12-17 17:25:57 +0100alexelcu(~alexelcu@142.93.180.198) (Quit: ZNC 1.8.2 - https://znc.in)
2020-12-17 17:26:17 +0100alexelcu(~alexelcu@142.93.180.198)
2020-12-17 17:26:46 +0100machinedgod(~machinedg@135-23-192-217.cpe.pppoe.ca)
2020-12-17 17:27:57 +0100dmiles(~dmiles@c-98-232-203-165.hsd1.wa.comcast.net) (Ping timeout: 260 seconds)
2020-12-17 17:29:18 +0100Ariakenom(~Ariakenom@2001:9b1:efb:fc00:8872:797c:1a98:8dff) (Ping timeout: 268 seconds)
2020-12-17 17:29:34 +0100dmiles(~dmiles@c-98-232-203-165.hsd1.wa.comcast.net)
2020-12-17 17:29:35 +0100oish(~charlie@228.25.169.217.in-addr.arpa)
2020-12-17 17:30:44 +0100Saukk(~Saukk@2001:998:ec:954:1c59:9bb5:b94c:3)
2020-12-17 17:31:34 +0100hekkaidekapus_(~tchouri@gateway/tor-sasl/hekkaidekapus)
2020-12-17 17:31:47 +0100softwarm(4408f588@ip68-8-245-136.sd.sd.cox.net)
2020-12-17 17:32:26 +0100dax(dax@bitbot/dax)
2020-12-17 17:33:23 +0100hekkaidekapus(~tchouri@gateway/tor-sasl/hekkaidekapus) (Ping timeout: 240 seconds)
2020-12-17 17:39:26 +0100justanotheruser(~justanoth@unaffiliated/justanotheruser)
2020-12-17 17:40:23 +0100iteratee(~kyle@162.211.154.4) (Read error: Connection reset by peer)
2020-12-17 17:40:32 +0100iteratee(~kyle@162.211.154.4)
2020-12-17 17:42:55 +0100jamm(~jamm@unaffiliated/jamm) (Remote host closed the connection)
2020-12-17 17:43:43 +0100jamm(~jamm@unaffiliated/jamm)
2020-12-17 17:45:49 +0100shf(~sheaf@2a01:cb19:80cc:7e00:3d51:cce0:e1c5:49b6) (Read error: Connection reset by peer)
2020-12-17 17:45:59 +0100christo(~chris@81.96.113.213) (Remote host closed the connection)
2020-12-17 17:48:38 +0100jamm(~jamm@unaffiliated/jamm) (Ping timeout: 264 seconds)
2020-12-17 17:50:32 +0100merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 256 seconds)
2020-12-17 17:50:57 +0100geekosaur(42d52137@66.213.33.55)
2020-12-17 17:52:33 +0100raichoo(~raichoo@dslb-092-073-214-015.092.073.pools.vodafone-ip.de) (Quit: Lost terminal)
2020-12-17 17:52:46 +0100heatsink(~heatsink@2600:1700:bef1:5e10:64b4:1541:658f:e8d8)
2020-12-17 17:53:32 +0100christo_(~chris@81.96.113.213)
2020-12-17 17:53:50 +0100chang(~textual@host-173-230-65-85.njjcmar.clients.pavlovmedia.com) ("Textual IRC Client: www.textualapp.com")
2020-12-17 17:54:04 +0100chang(~textual@host-173-230-65-85.njjcmar.clients.pavlovmedia.com)
2020-12-17 17:55:37 +0100cr3(~cr3@192-222-143-195.qc.cable.ebox.net)
2020-12-17 17:57:24 +0100geowiesnot(~user@i15-les02-ix2-87-89-181-157.sfr.lns.abo.bbox.fr) (Ping timeout: 260 seconds)
2020-12-17 17:58:01 +0100cosimone(~cosimone@2001:b07:ae5:db26:d849:743b:370b:b3cd) (Remote host closed the connection)
2020-12-17 17:58:04 +0100tenniscp25(~tenniscp2@134.196.209.118)
2020-12-17 17:59:40 +0100christo_(~chris@81.96.113.213) (Remote host closed the connection)
2020-12-17 18:00:09 +0100teardown_(~user@gateway/tor-sasl/mrush)
2020-12-17 18:00:53 +0100Ariakenom(~Ariakenom@2001:9b1:efb:fc00:1de4:7265:50e8:3545)
2020-12-17 18:02:32 +0100jonathanx(~jonathan@dyn-8-sc.cdg.chalmers.se) (Remote host closed the connection)
2020-12-17 18:03:03 +0100teardown(~user@gateway/tor-sasl/mrush) (Ping timeout: 240 seconds)
2020-12-17 18:03:32 +0100xff0x(~fox@2001:1a81:5260:ab00:b5e4:2313:abc1:f0cb) (Ping timeout: 260 seconds)
2020-12-17 18:04:06 +0100xff0x(~fox@2001:1a81:5260:ab00:82ea:b3e3:e22c:7f9)
2020-12-17 18:05:11 +0100christo(~chris@81.96.113.213)
2020-12-17 18:05:16 +0100brisbin(~patrick@pool-173-49-158-4.phlapa.fios.verizon.net) (Quit: WeeChat 2.9)
2020-12-17 18:06:29 +0100fuzzypixelz(~fuzzypixe@eth-west-pareq2-46-193-4-100.wb.wifirst.net)
2020-12-17 18:06:40 +0100wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
2020-12-17 18:07:37 +0100arahael(~arahael@194-193-194-178.tpgi.com.au) (Ping timeout: 256 seconds)
2020-12-17 18:09:28 +0100christo(~chris@81.96.113.213) (Ping timeout: 256 seconds)
2020-12-17 18:13:08 +0100juuandyy(~juuandyy@90.166.144.65)
2020-12-17 18:13:08 +0100 <ph88> i'm trying to build a project with stack with dependency Frames-streamly stack can't find it, normally it would recommend a line for extra-deps but it doesn't do that this time, how can i add this dependency ?
2020-12-17 18:13:38 +0100royal_screwup21(52254809@gateway/web/cgi-irc/kiwiirc.com/ip.82.37.72.9) (Quit: Connection closed)
2020-12-17 18:13:50 +0100 <koz_> Just add 'Frames-streamly-whatever.version'.
2020-12-17 18:13:56 +0100 <koz_> The SHA hash is optional.
2020-12-17 18:14:01 +0100royal_screwup21(52254809@gateway/web/cgi-irc/kiwiirc.com/ip.82.37.72.9)
2020-12-17 18:14:08 +0100 <koz_> (add it to the extra-deps section, I mean)
2020-12-17 18:14:59 +0100bliminse(~bliminse@host109-158-129-129.range109-158.btcentralplus.com) (Ping timeout: 256 seconds)
2020-12-17 18:15:50 +0100bliminse(~bliminse@host109-158-129-129.range109-158.btcentralplus.com)
2020-12-17 18:21:43 +0100LKoen(~LKoen@29.248.88.92.rev.sfr.net)
2020-12-17 18:26:04 +0100merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-12-17 18:28:30 +0100tomku(~tomku@unaffiliated/tomku) (Ping timeout: 256 seconds)
2020-12-17 18:30:19 +0100royal_screwup21(52254809@gateway/web/cgi-irc/kiwiirc.com/ip.82.37.72.9) (Quit: Connection closed)
2020-12-17 18:30:41 +0100royal_screwup21(52254809@gateway/web/cgi-irc/kiwiirc.com/ip.82.37.72.9)
2020-12-17 18:31:35 +0100merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 268 seconds)
2020-12-17 18:34:06 +0100justsomeguy(~justsomeg@unaffiliated/--/x-3805311) ()
2020-12-17 18:35:17 +0100tomku(~tomku@unaffiliated/tomku)
2020-12-17 18:35:42 +0100royal_screwup21(52254809@gateway/web/cgi-irc/kiwiirc.com/ip.82.37.72.9) (Ping timeout: 272 seconds)
2020-12-17 18:36:07 +0100royal_screwup21(52254809@gateway/web/cgi-irc/kiwiirc.com/ip.82.37.72.9)
2020-12-17 18:37:12 +0100Saukk(~Saukk@2001:998:ec:954:1c59:9bb5:b94c:3) (Remote host closed the connection)
2020-12-17 18:37:46 +0100bjobjo(~bjobjo@2a01:79c:cebf:d688::9e6)
2020-12-17 18:42:35 +0100 <tomsmeding> boxscape: that's interesting, it looks like those have Ix instances that traverse the index space in the same order
2020-12-17 18:42:47 +0100gxt(~gxt@gateway/tor-sasl/gxt)
2020-12-17 18:44:36 +0100Jesin(~Jesin@pool-72-66-101-18.washdc.fios.verizon.net)
2020-12-17 18:48:17 +0100 <Kronic> koz_ so I stumbled upon a similar problem with another lib and I arrived at that solution through trial and error. Is there any particular reason that it does that for some libraries and not others ?
2020-12-17 18:48:40 +0100 <koz_> Kronic: Stack keeps its own index of Hackage I believe.
2020-12-17 18:48:55 +0100 <koz_> If it's in the index, it'll suggest; if it's not, it can't, because it has nothing to go by.
2020-12-17 18:49:00 +0100 <koz_> However, that's just my best guess.
2020-12-17 18:49:10 +0100chele(~chele@ip5b416ea2.dynamic.kabel-deutschland.de) (Remote host closed the connection)
2020-12-17 18:49:34 +0100jneira(501e6453@gateway/web/cgi-irc/kiwiirc.com/ip.80.30.100.83)
2020-12-17 18:49:39 +0100 <Kronic> I see, thank you
2020-12-17 18:50:35 +0100Franciman(~francesco@host-82-49-79-73.retail.telecomitalia.it) (Quit: Leaving)
2020-12-17 18:51:25 +0100DirefulSalt(DirefulSal@gateway/vpn/privateinternetaccess/direfulsalt) (Remote host closed the connection)
2020-12-17 18:51:43 +0100 <ph88> thanks koz_
2020-12-17 18:51:44 +0100nineonine(~nineonine@S01061cabc0b095f3.vf.shawcable.net)
2020-12-17 18:59:26 +0100 <Kronic> So, I've included a question about function application on this paste: https://dpaste.org/Ammy
2020-12-17 18:59:28 +0100joaj(~joaj@2001:690:2100:110:cceb:227c:edbc:592c) (Ping timeout: 258 seconds)
2020-12-17 19:00:06 +0100 <Kronic> Basically, the list I want out of my function returns out of order but I don't understand why, and it appears that changing it up doesn't impact the result in a desirable way either. Anyone able to explain to me what is happening on the line I highlighted ?
2020-12-17 19:00:19 +0100joaj(~joaj@2001:690:2100:1b:a36f:f7ab:d46c:98f0)
2020-12-17 19:00:46 +0100Stanley00(~stanley00@unaffiliated/stanley00)
2020-12-17 19:01:17 +0100merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-12-17 19:01:19 +0100 <hyperisco> Kronic, I don't think this is a question narrowly about function application. If you evaluate your function by hand for a list of, say, 3 elements, do you get what you expect?
2020-12-17 19:01:28 +0100dhouthoo(~dhouthoo@ptr-eitgbj2w0uu6delkbrh.18120a2.ip6.access.telenet.be) (Quit: WeeChat 2.9)
2020-12-17 19:02:03 +0100 <Kronic> I included that information because that is what my understanding of the problem is, but my understanding is wrong, so
2020-12-17 19:02:18 +0100 <hyperisco> I mean take it step by step by hand
2020-12-17 19:02:30 +0100 <hyperisco> if you want to really understand what is happening that is what you should do
2020-12-17 19:02:38 +0100sh9(~sh9@softbank060116136158.bbtec.net)
2020-12-17 19:02:58 +0100 <gentauro> anybody using XMonad on nixos?
2020-12-17 19:03:04 +0100 <Kronic> I see the problem
2020-12-17 19:03:10 +0100 <Kronic> It's the last line
2020-12-17 19:03:25 +0100 <Kronic> I fixed it, thank you :)
2020-12-17 19:03:27 +0100 <gentauro> I have an issue when I try to build `building package X11-1.9.2`
2020-12-17 19:04:23 +0100 <gentauro> I noticed that only `libX11-1.6.12` is available :(
2020-12-17 19:04:36 +0100 <Kronic> not meaning to discard your advice to trace it hyperisco, I already know function application fairly well I think I was just tunnel visioned on the line I commented on a little too much
2020-12-17 19:04:37 +0100mirrorbird(~psutcliff@2a00:801:447:b1bf:a43d:1573:86a9:1f86)
2020-12-17 19:04:47 +0100 <ph88> in which monad can i run this function ? https://hackage.haskell.org/package/Frames-streamly-0.1.0.2/docs/Frames-Streamly-CSV.html#v:readTa…
2020-12-17 19:04:56 +0100Stanley00(~stanley00@unaffiliated/stanley00) (Ping timeout: 240 seconds)
2020-12-17 19:05:02 +0100christo(~chris@81.96.113.213)
2020-12-17 19:05:30 +0100 <sm[m]> adding to koz_'s stack answer: I expect doing stack update would help there
2020-12-17 19:05:46 +0100 <koz_> sm[m]: Yeah, that's a good point.
2020-12-17 19:05:55 +0100 <ph88> are you talking to me ?
2020-12-17 19:06:11 +0100 <koz_> ph88: The 'm' part requires MonadIO and MonadCatch.
2020-12-17 19:06:21 +0100 <koz_> Basically, that translates to 'IO, or a stack with IO in its heart'.
2020-12-17 19:06:28 +0100danso(~dan@69-165-210-185.cable.teksavvy.com)
2020-12-17 19:06:56 +0100wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Quit: leaving)
2020-12-17 19:07:03 +0100mirrorbird(~psutcliff@2a00:801:447:b1bf:a43d:1573:86a9:1f86) (Client Quit)
2020-12-17 19:07:30 +0100joaj(~joaj@2001:690:2100:1b:a36f:f7ab:d46c:98f0) (Quit: WeeChat 2.9)
2020-12-17 19:07:58 +0100juuandyy(~juuandyy@90.166.144.65) (Ping timeout: 268 seconds)
2020-12-17 19:08:19 +0100 <hyperisco> > let { changeOne p f xs = let (a, a') = span (not . p) xs; (b, b') = splitAt 1 a' in a ++ map f b ++ b' } in changeOne (>3) (*2) [1..10]
2020-12-17 19:08:21 +0100 <ph88> koz_, i am trying to run this in IO but i get a type error https://bpa.st/A2JQ
2020-12-17 19:08:21 +0100 <lambdabot> [1,2,3,8,5,6,7,8,9,10]
2020-12-17 19:08:54 +0100 <koz_> ph88: Pastebin the code?
2020-12-17 19:08:59 +0100 <ph88> ok
2020-12-17 19:09:24 +0100 <ph88> koz_, the code is not much more than what is in line 12 to 15
2020-12-17 19:09:37 +0100 <koz_> ph88: Pastebin it anyway.
2020-12-17 19:09:39 +0100 <koz_> Context helps.
2020-12-17 19:09:42 +0100 <ph88> ok just a moment
2020-12-17 19:09:48 +0100 <koz_> (for explanation if nothing else0
2020-12-17 19:09:49 +0100christo(~chris@81.96.113.213) (Ping timeout: 268 seconds)
2020-12-17 19:09:52 +0100 <koz_> )*
2020-12-17 19:10:28 +0100geowiesnot(~user@i15-les02-ix2-87-89-181-157.sfr.lns.abo.bbox.fr)
2020-12-17 19:10:39 +0100 <ph88> koz_, https://bpa.st/GOVA
2020-12-17 19:10:54 +0100phyll1s_work(~phyll1s_w@195.140.213.38) (Ping timeout: 260 seconds)
2020-12-17 19:11:04 +0100 <koz_> readTable doesn't return something in IO.
2020-12-17 19:11:16 +0100 <koz_> It gives back t m (Record rs), where t is a stream type.
2020-12-17 19:11:17 +0100 <boxscape> tomsmeding I'm now using a custom length-indexed vector as the index with the same Ix order as the tuples, and it also has the 2x runtime, but yeah, not really sure what's going on with that
2020-12-17 19:11:26 +0100 <koz_> So you have to use the streamly stuff to actually pull records out of it.
2020-12-17 19:11:39 +0100 <ph88> so it's a pure value from IO monad perspective ?
2020-12-17 19:11:42 +0100 <xerox_> > let change p f = traverse (\x -> x : [ f x | p x ]) in change (>3) (*2) [1..5]
2020-12-17 19:11:42 +0100 <koz_> That's what your type error is saying.
2020-12-17 19:11:44 +0100 <lambdabot> [[1,2,3,4,5],[1,2,3,4,10],[1,2,3,8,5],[1,2,3,8,10]]
2020-12-17 19:11:52 +0100 <xerox_> hyperisco: was hoping head was that one but no
2020-12-17 19:11:56 +0100 <koz_> ph88: It's not in IO, if that's what you're asking.
2020-12-17 19:12:16 +0100 <tomsmeding> boxscape: strange things
2020-12-17 19:12:30 +0100 <koz_> Basically, the whole point of streamly is that the streams themselves are not in IO - the values you pull out of them _are_, but then you only have to be in IO for those values, not the whole thing.
2020-12-17 19:12:38 +0100 <koz_> (which could be infinite, and thus could pose some hilarious problems)
2020-12-17 19:12:56 +0100oish(~charlie@228.25.169.217.in-addr.arpa) (Ping timeout: 256 seconds)
2020-12-17 19:13:30 +0100 <xerox_> ah [f x|p x]++[x] gives the first one as head, right
2020-12-17 19:14:12 +0100 <ph88> koz_, do you know which type i could give it ?? https://bpa.st/IT3A
2020-12-17 19:14:27 +0100oish(~charlie@228.25.169.217.in-addr.arpa)
2020-12-17 19:14:46 +0100 <koz_> As far as I can tell, this is a vinyl problem. I dunno vinyl, so I can't help much.
2020-12-17 19:15:05 +0100 <ph88> oki
2020-12-17 19:15:14 +0100 <ph88> thank you koz_
2020-12-17 19:15:17 +0100 <koz_> No worries.
2020-12-17 19:16:18 +0100 <Kronic> very interesting hyperisco thank you for that!
2020-12-17 19:16:31 +0100 <hyperisco> is it a histomorphism that could do it too
2020-12-17 19:17:50 +0100thc202(~thc202@unaffiliated/thc202) (Ping timeout: 268 seconds)
2020-12-17 19:18:29 +0100geowiesnot(~user@i15-les02-ix2-87-89-181-157.sfr.lns.abo.bbox.fr) (Ping timeout: 260 seconds)
2020-12-17 19:19:33 +0100 <hyperisco> > let changeOne p f = fst . foldr (\x (xs',xs) -> (if p x then f x : xs else x : xs', x:xs)) ([],[]) in changeOne (>3) (*2) [1..10]
2020-12-17 19:19:35 +0100 <lambdabot> [1,2,3,8,5,6,7,8,9,10]
2020-12-17 19:21:28 +0100pjb(~t@2a01cb04063ec500c04af862aff5caa7.ipv6.abo.wanadoo.fr)
2020-12-17 19:23:20 +0100justsomeguy(~justsomeg@2603-9000-960a-fc00-c4d2-5b73-c7b7-3a2b.inf6.spectrum.com)
2020-12-17 19:23:20 +0100justsomeguy(~justsomeg@2603-9000-960a-fc00-c4d2-5b73-c7b7-3a2b.inf6.spectrum.com) (Changing host)
2020-12-17 19:23:20 +0100justsomeguy(~justsomeg@unaffiliated/--/x-3805311)
2020-12-17 19:26:27 +0100Vulfe_(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00) (Remote host closed the connection)
2020-12-17 19:27:11 +0100bliminse(~bliminse@host109-158-129-129.range109-158.btcentralplus.com) (Quit: leaving)
2020-12-17 19:28:00 +0100Stanley00(~stanley00@unaffiliated/stanley00)
2020-12-17 19:28:58 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00)
2020-12-17 19:30:41 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00) (Read error: Connection reset by peer)
2020-12-17 19:30:56 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00)
2020-12-17 19:32:19 +0100howdoi(uid224@gateway/web/irccloud.com/x-jyxgencxqnzavabz)
2020-12-17 19:32:23 +0100rayyyy(~nanoz@gateway/tor-sasl/nanoz)
2020-12-17 19:32:32 +0100Stanley00(~stanley00@unaffiliated/stanley00) (Ping timeout: 256 seconds)
2020-12-17 19:32:40 +0100mbomba(~mbomba@bras-base-toroon2719w-grc-53-142-114-5-26.dsl.bell.ca)
2020-12-17 19:32:49 +0100_linker_(~linker@2a02:a31a:a041:9a80:3db8:9890:7378:91f0)
2020-12-17 19:34:22 +0100guest1216(~user@49.5.6.87)
2020-12-17 19:35:51 +0100stefan(~cri@42dots.de) (Quit: ZNC 1.6.3+deb1ubuntu0.2 - http://znc.in)
2020-12-17 19:35:59 +0100stefan(~cri@42dots.de)
2020-12-17 19:36:07 +0100u0_a298(~user@47.206.148.226)
2020-12-17 19:38:14 +0100stefan(~cri@42dots.de) (Client Quit)
2020-12-17 19:38:21 +0100stefan-_(~cri@42dots.de)
2020-12-17 19:38:42 +0100wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
2020-12-17 19:38:54 +0100guest1216(~user@49.5.6.87) (Ping timeout: 260 seconds)
2020-12-17 19:39:16 +0100porvak(~porvak@84.39.117.57)
2020-12-17 19:42:08 +0100Jesin(~Jesin@pool-72-66-101-18.washdc.fios.verizon.net) (Quit: Leaving)
2020-12-17 19:43:31 +0100Jesin(~Jesin@pool-72-66-101-18.washdc.fios.verizon.net)
2020-12-17 19:43:56 +0100boxscape(4ff0ba59@gateway/web/cgi-irc/kiwiirc.com/ip.79.240.186.89) (Quit: Connection closed)
2020-12-17 19:44:22 +0100boxscape(4ff0ba59@gateway/web/cgi-irc/kiwiirc.com/ip.79.240.186.89)
2020-12-17 19:45:53 +0100MOSCOS(~MOSCOS@122.54.107.175) (Remote host closed the connection)
2020-12-17 19:46:17 +0100MOSCOS(~MOSCOS@122.54.107.175)
2020-12-17 19:50:46 +0100fuzzypixelz_(~fuzzypixe@eth-west-pareq2-46-193-4-100.wb.wifirst.net)
2020-12-17 19:51:31 +0100fuzzypixelz(~fuzzypixe@eth-west-pareq2-46-193-4-100.wb.wifirst.net) (Ping timeout: 246 seconds)
2020-12-17 19:51:36 +0100fuzzypixelz_fuzzypixelz
2020-12-17 19:52:05 +0100fuzzypixelz(~fuzzypixe@eth-west-pareq2-46-193-4-100.wb.wifirst.net) (Client Quit)
2020-12-17 19:52:24 +0100fuzzypixelz(~fuzzypixe@eth-west-pareq2-46-193-4-100.wb.wifirst.net)
2020-12-17 19:54:22 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00) (Remote host closed the connection)
2020-12-17 19:54:40 +0100geekosaur(42d52137@66.213.33.55) (Ping timeout: 245 seconds)
2020-12-17 19:55:26 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00)
2020-12-17 19:56:57 +0100fuzzypixelz(~fuzzypixe@eth-west-pareq2-46-193-4-100.wb.wifirst.net) (Client Quit)
2020-12-17 19:58:18 +0100fresheyeball(~isaac@c-71-237-105-37.hsd1.co.comcast.net)
2020-12-17 20:00:02 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00) (Ping timeout: 264 seconds)
2020-12-17 20:02:11 +0100Merfont(~Kaiepi@47.54.252.148) (Remote host closed the connection)
2020-12-17 20:02:30 +0100hnOsmium0001(uid453710@gateway/web/irccloud.com/x-evqgdihcidrcilck)
2020-12-17 20:02:34 +0100Merfont(~Kaiepi@47.54.252.148)
2020-12-17 20:02:51 +0100berberman(~berberman@unaffiliated/berberman) (Ping timeout: 268 seconds)
2020-12-17 20:03:24 +0100berberman(~berberman@unaffiliated/berberman)
2020-12-17 20:06:22 +0100teardown(~user@gateway/tor-sasl/mrush)
2020-12-17 20:07:05 +0100Rudd0(~Rudd0@185.189.115.98) (Remote host closed the connection)
2020-12-17 20:07:52 +0100ggole(~ggole@2001:8003:8119:7200:b1ce:df7:cb14:ba8f) (Quit: Leaving)
2020-12-17 20:09:01 +0100raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) (Ping timeout: 268 seconds)
2020-12-17 20:09:03 +0100teardown_(~user@gateway/tor-sasl/mrush) (Ping timeout: 240 seconds)
2020-12-17 20:10:19 +0100yitz(~yitz@unaffiliated/yitz)
2020-12-17 20:11:21 +0100 <yitz> Any recommendations for a dead-tree book that's good for learning Haskell?
2020-12-17 20:11:51 +0100asheshambasta(~user@ptr-e1lysaxt4bg7tmaahx1.18120a2.ip6.access.telenet.be) (Ping timeout: 272 seconds)
2020-12-17 20:13:36 +0100geekosaur(42d52137@66.213.33.55)
2020-12-17 20:14:25 +0100codeAlways(uid272474@gateway/web/irccloud.com/x-uaxhttwxpgbyaiuf) (Quit: Connection closed for inactivity)
2020-12-17 20:19:34 +0100cole-h(~cole-h@c-73-48-197-220.hsd1.ca.comcast.net)
2020-12-17 20:31:59 +0100dbmikus(~dbmikus@c-174-49-172-14.hsd1.pa.comcast.net) (Ping timeout: 260 seconds)
2020-12-17 20:32:01 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00)
2020-12-17 20:33:46 +0100tenniscp25(~tenniscp2@134.196.209.118) (Remote host closed the connection)
2020-12-17 20:34:10 +0100 <ph88> Is anyone familiar with vinyl ?? I would like to supply Record https://hackage.haskell.org/package/Frames-0.7.0/docs/Frames-Rec.html#t:Record with an "empty" type just for test. Maybe i can use a type similar to that of RNil ?? https://hackage.haskell.org/package/vinyl-0.13.0/docs/Data-Vinyl-Core.html#v:RNil
2020-12-17 20:34:19 +0100tenniscp25(~tenniscp2@134.196.209.118)
2020-12-17 20:34:34 +0100boxscape(4ff0ba59@gateway/web/cgi-irc/kiwiirc.com/ip.79.240.186.89) (Quit: Connection closed)
2020-12-17 20:34:53 +0100boxscape(4ff0ba59@gateway/web/cgi-irc/kiwiirc.com/ip.79.240.186.89)
2020-12-17 20:35:00 +0100 <ph88> Type ElField is part of Record which needs the actual parameter https://hackage.haskell.org/package/vinyl-0.13.0/docs/Data-Vinyl-Functor.html#t:ElField
2020-12-17 20:35:33 +0100 <suzu_> ah god this is melting my brain
2020-12-17 20:35:42 +0100 <exarkun> How do I narrow down the cause of a fatal exception? eg, my program exits when "DevBot-exe: user error (Upstream source closed.)". How do I map that onto a function that needs additional exception handling?
2020-12-17 20:36:22 +0100 <geekosaur> +RTS -xc ?
2020-12-17 20:36:35 +0100 <geekosaur> may require rebuilding with profiling
2020-12-17 20:36:37 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:5558:d5c3:d19f:3f00) (Ping timeout: 260 seconds)
2020-12-17 20:36:42 +0100Achylles(~Achylles@189.79.237.44)
2020-12-17 20:36:53 +0100 <suzu_> is there a way to get MonadIO for a Foo -> m a where `m` is an instance of MonadIO
2020-12-17 20:38:09 +0100 <ph88> suzu_, what do you mean ?
2020-12-17 20:38:30 +0100 <suzu_> i've got a monad: Widget HTML
2020-12-17 20:38:40 +0100 <suzu_> making values of Widget HTML a
2020-12-17 20:38:47 +0100 <koz_> suzu_: Sure, via ReaderT Foo m
2020-12-17 20:38:54 +0100 <suzu_> i want to do some RIO stuff in it
2020-12-17 20:39:04 +0100tenniscp25(~tenniscp2@134.196.209.118) (Ping timeout: 256 seconds)
2020-12-17 20:39:05 +0100 <ph88> suzu_, maybe you can use function liftIO
2020-12-17 20:39:28 +0100 <suzu_> RIO a is a wrapper on ReaderT env IO a
2020-12-17 20:39:35 +0100 <suzu_> i want to lift RIO a's inside Widget
2020-12-17 20:40:10 +0100nineonine(~nineonine@S01061cabc0b095f3.vf.shawcable.net) (Remote host closed the connection)
2020-12-17 20:40:12 +0100 <suzu_> i want to go from RIO a -> Widget HTML a pretty much
2020-12-17 20:40:28 +0100wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Ping timeout: 268 seconds)
2020-12-17 20:40:34 +0100 <suzu_> i can almost do this
2020-12-17 20:40:36 +0100 <suzu_> liftRIO :: (MonadIO m, MonadReader env m) => RIO env a -> m a
2020-12-17 20:40:38 +0100 <koz_> suzu_: Do you want an instance of MonadIO for Widget HTML I guess?
2020-12-17 20:40:44 +0100nineonine(~nineonine@50.216.62.2)
2020-12-17 20:40:47 +0100 <suzu_> Widget HTML has a MonadIO
2020-12-17 20:40:51 +0100 <suzu_> but no MonadReader
2020-12-17 20:40:58 +0100 <suzu_> so im just sorta stuck
2020-12-17 20:41:09 +0100 <koz_> I guess Widget isn't a thing you wrote?
2020-12-17 20:41:12 +0100 <suzu_> right
2020-12-17 20:41:48 +0100dbmikus(~dbmikus@c-174-49-172-14.hsd1.pa.comcast.net)
2020-12-17 20:42:47 +0100 <ph88> wish i could help :|
2020-12-17 20:43:20 +0100 <koz_> My best bet is 'newtype-wrap Widget and give it the right instance, then unwrap again once you're done lifting'.
2020-12-17 20:44:48 +0100 <suzu_> hmmm
2020-12-17 20:45:10 +0100 <suzu_> newtype-wrap it and give it an 'env' addon perhaps
2020-12-17 20:45:16 +0100 <suzu_> and then add monadreader to it
2020-12-17 20:45:19 +0100jpds(~jpds@gateway/tor-sasl/jpds) (Remote host closed the connection)
2020-12-17 20:45:22 +0100 <koz_> The whole idea is you write like.
2020-12-17 20:45:35 +0100boxscape(4ff0ba59@gateway/web/cgi-irc/kiwiirc.com/ip.79.240.186.89) (Quit: Connection closed)
2020-12-17 20:45:45 +0100 <koz_> newtype SnoymanStopMessingWithMe a = SSMWM (Widget HTML a)
2020-12-17 20:45:47 +0100 <koz_> Then go
2020-12-17 20:45:54 +0100jpds(~jpds@gateway/tor-sasl/jpds)
2020-12-17 20:45:59 +0100 <suzu_> newtype WidgetedEnv env v a = { unwrap :: env -> Widget v a }
2020-12-17 20:46:09 +0100 <koz_> instance MonadReader HTML SnoymanStopMessingWithMe where
2020-12-17 20:46:14 +0100 <suzu_> lmao snoyman stop messing wit hme
2020-12-17 20:46:23 +0100 <koz_> Since I _assume_ the environment in question is HTML?
2020-12-17 20:46:35 +0100 <suzu_> good guess but not quite
2020-12-17 20:46:38 +0100DavidEichmann(~david@62.110.198.146.dyn.plus.net) (Remote host closed the connection)
2020-12-17 20:46:40 +0100 <suzu_> Widget is rather strange
2020-12-17 20:46:53 +0100 <suzu_> but i think what you're describing might work
2020-12-17 20:47:31 +0100 <ph88> that's an interesting name for a type koz_ xD
2020-12-17 20:47:36 +0100 <koz_> ph88: :D
2020-12-17 20:47:55 +0100 <ph88> does someone know this type level programming data kinds stuff ?? https://bpa.st/HQYA
2020-12-17 20:47:57 +0100 <suzu_> oh i found an idea!
2020-12-17 20:48:01 +0100Achylles(~Achylles@189.79.237.44) (Quit: Leaving)
2020-12-17 20:48:07 +0100 <suzu_> instead of writing code in :: Widget HTML a
2020-12-17 20:48:15 +0100 <suzu_> i'll write it in :: env -> Widget HTML a
2020-12-17 20:48:33 +0100royal_screwup21(52254809@gateway/web/cgi-irc/kiwiirc.com/ip.82.37.72.9) (Quit: Connection closed)
2020-12-17 20:48:35 +0100 <suzu_> then i can rioToWidget :: RIO env a -> env -> widget HTML a
2020-12-17 20:48:38 +0100 <koz_> suzu_: So Kleisli (Widget HTML) env a ?
2020-12-17 20:48:40 +0100 <ph88> i had DataKinds enabled btw
2020-12-17 20:48:45 +0100 <suzu_> rioToWidget rr e = runRIO e rr
2020-12-17 20:48:55 +0100 <suzu_> sure idk what Kleisli is
2020-12-17 20:48:56 +0100royal_screwup21(52254809@gateway/web/cgi-irc/kiwiirc.com/ip.82.37.72.9)
2020-12-17 20:49:06 +0100 <suzu_> thats probably what i ended up at by accident
2020-12-17 20:49:07 +0100 <suzu_> lol
2020-12-17 20:49:11 +0100 <koz_> suzu_: Kleisli m a b ~ a -> m b
2020-12-17 20:49:18 +0100 <ph88> some kind of primitive in category theory right
2020-12-17 20:49:25 +0100 <suzu_> looks like monad bind
2020-12-17 20:49:28 +0100 <suzu_> so
2020-12-17 20:49:28 +0100 <koz_> Also known as the fish arrow.
2020-12-17 20:49:30 +0100 <suzu_> yep
2020-12-17 20:49:32 +0100 <suzu_> >=>
2020-12-17 20:49:33 +0100 <koz_> It's not bind - it's fish.
2020-12-17 20:49:34 +0100 <suzu_> this thing?
2020-12-17 20:49:38 +0100 <koz_> Yep, fish.
2020-12-17 20:49:45 +0100 <suzu_> what's the type of fish
2020-12-17 20:49:49 +0100 <ph88> getting hungry now
2020-12-17 20:49:51 +0100 <koz_> :t (>=>)
2020-12-17 20:49:53 +0100 <lambdabot> Monad m => (a -> m b) -> (b -> m c) -> a -> m c
2020-12-17 20:49:58 +0100 <koz_> Oh wait, not fish.
2020-12-17 20:49:59 +0100 <suzu_> that is
2020-12-17 20:50:00 +0100 <suzu_> melting my brain
2020-12-17 20:50:08 +0100 <suzu_> oh i see
2020-12-17 20:50:10 +0100 <ephemient> also (<=<), of course
2020-12-17 20:50:13 +0100 <koz_> Basically, fish composes two Kleislis.
2020-12-17 20:50:21 +0100 <dsal> yitz: I read haskellbook.com on my kindle. It'd be a lot to print.
2020-12-17 20:50:21 +0100 <suzu_> take the a at the end and push it through two almost-bind-like things
2020-12-17 20:50:30 +0100 <suzu_> making one bind-like-thing
2020-12-17 20:50:35 +0100 <koz_> suzu_: They're more like 'functions which add on an effect'.
2020-12-17 20:50:41 +0100 <koz_> Compare a -> b to a -> m b
2020-12-17 20:50:54 +0100 <koz_> The former is pure, the latter (possibly) has effects.
2020-12-17 20:51:08 +0100 <ph88> geekosaur, could you help me with question about DataKinds ?
2020-12-17 20:51:11 +0100 <koz_> So fish is to Kleisli like (.) is to pure functions.
2020-12-17 20:51:12 +0100 <yitz> dsal: Thanks. I'm thinking of taking advantage of company policy to order a book. If they got a print version, I'll look into that one. Thanks!
2020-12-17 20:51:42 +0100 <suzu_> hmm
2020-12-17 20:51:45 +0100geekosaur(42d52137@66.213.33.55) (Ping timeout: 245 seconds)
2020-12-17 20:51:45 +0100 <merijn> suzu_: >=> is just "\f g x -> f x >>= g"
2020-12-17 20:51:49 +0100 <ph88> yitz, i think there was another pretty good book released after the haskellbook, and that book looked better to me
2020-12-17 20:51:52 +0100 <suzu_> whats the nice way to write what i ended up with then?
2020-12-17 20:51:52 +0100 <merijn> :t (>>=)
2020-12-17 20:51:53 +0100 <lambdabot> Monad m => m a -> (a -> m b) -> m b
2020-12-17 20:52:07 +0100sh9(~sh9@softbank060116136158.bbtec.net) (Ping timeout: 260 seconds)
2020-12-17 20:52:24 +0100 <suzu_> i'm now working in ((->) Env) Widget HTML a
2020-12-17 20:52:33 +0100 <suzu_> so the ((->) Env) monad instance
2020-12-17 20:52:33 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:cca6:5d8:2bb0:556c)
2020-12-17 20:52:41 +0100 <yitz> ph88: got a title?
2020-12-17 20:52:42 +0100 <suzu_> and having to `pure` a lot of stuff
2020-12-17 20:52:52 +0100 <ph88> yitz, i will look just a moment
2020-12-17 20:53:10 +0100 <dsal> yitz: There are print version of books that are not the first book you should read. :) I'd say there are three levels. haskellbook.com is good material, though not perfect. People have also been recommending: https://www.cs.nott.ac.uk/~pszgmh/pih.html
2020-12-17 20:53:16 +0100vicfred(~vicfred@unaffiliated/vicfred) (Ping timeout: 240 seconds)
2020-12-17 20:53:33 +0100 <dsal> This is a really good second book: https://simonmar.github.io/pages/pcph.html
2020-12-17 20:53:38 +0100royal_screwup21(52254809@gateway/web/cgi-irc/kiwiirc.com/ip.82.37.72.9) (Ping timeout: 256 seconds)
2020-12-17 20:54:19 +0100 <dsal> From there, https://thinkingwithtypes.com/ will take you quite deep.
2020-12-17 20:54:41 +0100 <dsal> This one is really great for getting a basic understanding of lens: https://leanpub.com/optics-by-example
2020-12-17 20:54:59 +0100 <dsal> Caveat, though. You'll be really angry with all your other tools once you start having better things to compare them to.
2020-12-17 20:55:25 +0100 <dsal> (not that there's nothing to complain about in Haskell, but many of the parts that aren't perfect are just nonexistent in stuff I have to do at work)
2020-12-17 20:55:41 +0100 <yitz> lol. Thank you
2020-12-17 20:55:46 +0100 <suzu_> ok this doesnt work
2020-12-17 20:55:53 +0100 <suzu_> im going to newtype widget as you suggested koz_
2020-12-17 20:55:53 +0100star_cloud(~star_clou@ec2-34-220-44-120.us-west-2.compute.amazonaws.com) (Ping timeout: 268 seconds)
2020-12-17 20:55:55 +0100 <suzu_> i think that's it
2020-12-17 20:56:04 +0100bitmagie(~Thunderbi@200116b80697370068b048f727c82739.dip.versatel-1u1.de) (Quit: bitmagie)
2020-12-17 20:56:16 +0100 <koz_> suzu_: Any problem can be solved by adding enough newtypes. :P
2020-12-17 20:56:31 +0100 <suzu_> why cant it derive monad for me wtf
2020-12-17 20:56:45 +0100 <koz_> suzu_: How are you asking it to derive?
2020-12-17 20:56:55 +0100 <suzu_> probably by doing it wrong
2020-12-17 20:56:57 +0100 <suzu_> newtype RIOWidget env v a = RIOWidget {unRIOWidget :: env -> Widget v a} deriving (Functor)
2020-12-17 20:57:21 +0100 <suzu_> adding Monad / Applicative to that list says it can't do eta-reduce it enough to get it to work?
2020-12-17 20:57:22 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:cca6:5d8:2bb0:556c) (Ping timeout: 260 seconds)
2020-12-17 20:57:23 +0100 <koz_> deriving (Functor, Applicative, Monad) via (Kleisli (Widget v) env) should work?
2020-12-17 20:57:24 +0100 <ph88> yitz, i was also thinking of this book https://www.cs.nott.ac.uk/~pszgmh/pih.html
2020-12-17 20:57:30 +0100 <suzu_> oh
2020-12-17 20:57:32 +0100 <koz_> (you need DerivingVia on)
2020-12-17 20:57:38 +0100 <yitz> Two recommendations for the same book! That's promising
2020-12-17 20:57:41 +0100 <yitz> Thanks, ph88
2020-12-17 20:58:14 +0100justsomeguy(~justsomeg@unaffiliated/--/x-3805311) (Ping timeout: 264 seconds)
2020-12-17 20:58:45 +0100 <suzu_> thath worked
2020-12-17 20:58:47 +0100 <suzu_> .. why did that work
2020-12-17 20:58:50 +0100 <suzu_> what did i just do
2020-12-17 20:58:52 +0100 <suzu_> lol
2020-12-17 20:58:58 +0100 <koz_> suzu_: There's two steps here.
2020-12-17 20:59:00 +0100 <suzu_> @i Kleisli
2020-12-17 20:59:00 +0100 <lambdabot> Maybe you meant: id ignore index instances instances-importing irc-connect irc-password irc-persist-connect v @ ? .
2020-12-17 20:59:16 +0100 <koz_> First, GHC sees that your type is coercible to env -> Widget v a
2020-12-17 20:59:33 +0100 <koz_> Then it sees that env -> Widget v a is coercible to Kleisli (Widget v) env a
2020-12-17 20:59:38 +0100 <suzu_> ^ ok what
2020-12-17 20:59:47 +0100 <koz_> Then it sees that Kleisli (Widget v) env a has the instances you asked for.
2020-12-17 20:59:57 +0100 <koz_> So it then basically scribbles in all the methods with a bunch of coerces.
2020-12-17 21:00:12 +0100machinedgod(~machinedg@135-23-192-217.cpe.pppoe.ca) (Ping timeout: 268 seconds)
2020-12-17 21:00:18 +0100 <ph88> that's a lot of scribbling
2020-12-17 21:00:26 +0100 <koz_> ph88: Saves _you_ doing it, though!
2020-12-17 21:00:28 +0100 <suzu_> Kleisli m a b, is a -> m b
2020-12-17 21:00:45 +0100 <ph88> well i'm still stuck on DataKinds, but ok Kleisli lol :p
2020-12-17 21:01:16 +0100 <suzu_> so Kleisli (Widget v) env a is env -> (Widget v) a
2020-12-17 21:01:21 +0100 <suzu_> ok
2020-12-17 21:01:25 +0100evanjs(~evanjs@075-129-098-007.res.spectrum.com) (Ping timeout: 264 seconds)
2020-12-17 21:01:48 +0100 <suzu_> and then all these nistances under Klesli in Control.arrow are on (Kleisli m) for any m
2020-12-17 21:01:50 +0100 <suzu_> okay
2020-12-17 21:01:52 +0100 <suzu_> i get it
2020-12-17 21:01:54 +0100 <suzu_> wow
2020-12-17 21:01:56 +0100Deide(~Deide@217.155.19.23)
2020-12-17 21:02:01 +0100 <suzu_> that is an excellent tool
2020-12-17 21:02:05 +0100 <koz_> DerivingVia is pretty handy for exactly these kinds of scenarios.
2020-12-17 21:02:07 +0100 <suzu_> i am keeping that in my pocket
2020-12-17 21:02:46 +0100 <koz_> Note: Traverse is annoyingly resistant to being derived this way.
2020-12-17 21:02:53 +0100geekosaur(42d52137@66.213.33.55)
2020-12-17 21:02:56 +0100 <koz_> So don't be surprised if you see coercion gore from GHC if you try it.
2020-12-17 21:03:24 +0100ClaudiusMaximus(~claude@unaffiliated/claudiusmaximus) (Quit: ->)
2020-12-17 21:03:25 +0100wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
2020-12-17 21:04:10 +0100philopsos(~caecilius@gateway/tor-sasl/caecilius)
2020-12-17 21:05:52 +0100Stanley00(~stanley00@unaffiliated/stanley00)
2020-12-17 21:07:52 +0100texasmynsted(~texasmyns@99.96.221.112) (Remote host closed the connection)
2020-12-17 21:08:28 +0100texasmynsted(~texasmyns@92.119.17.139)
2020-12-17 21:09:27 +0100wonko7(~wonko7@2a01:e35:2ffb:7040:4535:f480:7dff:b3b5) (Ping timeout: 268 seconds)
2020-12-17 21:10:34 +0100Stanley00(~stanley00@unaffiliated/stanley00) (Ping timeout: 256 seconds)
2020-12-17 21:10:36 +0100 <ph88> anyone else experience that haskell programs in powershell are very slow ?
2020-12-17 21:11:31 +0100sh9(~sh9@softbank060116136158.bbtec.net)
2020-12-17 21:12:30 +0100 <koz_> ph88: What do said programs do?
2020-12-17 21:12:39 +0100 <koz_> (like, in your experience of slowness?)
2020-12-17 21:12:48 +0100 <ph88> well ghc itself is very slow
2020-12-17 21:13:00 +0100boxscape(4ff0ba59@gateway/web/cgi-irc/kiwiirc.com/ip.79.240.186.89)
2020-12-17 21:13:08 +0100 <ph88> when i run a virtualmachine on the same machine with linux it's faster
2020-12-17 21:13:48 +0100 <Kronic> I prefer coding in a VM personally, haskell using haskell on windows was a huge pain
2020-12-17 21:13:58 +0100 <Kronic> I brainfarted hard there...
2020-12-17 21:14:18 +0100 <Kronic> s/haskell using haskell/using haskell
2020-12-17 21:14:21 +0100sh9(~sh9@softbank060116136158.bbtec.net) (Client Quit)
2020-12-17 21:16:23 +0100teardown(~user@gateway/tor-sasl/mrush) (Ping timeout: 240 seconds)
2020-12-17 21:18:41 +0100teardown(~user@gateway/tor-sasl/mrush)
2020-12-17 21:23:12 +0100 <xsperry> ph88, "when i run a virtualmachine on the same machine with linux it's faster" <- how much faster?
2020-12-17 21:24:05 +0100rprije(~rprije@14-203-203-69.tpgi.com.au)
2020-12-17 21:24:22 +0100 <dsal> yitz: I don't exactly count as a recommendation for the Hutton book. I've not read it. The thing I liked about haskellbook.com (and a lot of people *didn't* like) was that it goes very slow with no assumed knowledge. Forgetting things you know about programming will make it easier.
2020-12-17 21:25:09 +0100 <monochrom> Generally linux is more efficient than windows. Even linux in virtualbox on windows is more efficient than native windows, heh.
2020-12-17 21:25:24 +0100 <yitz> I'm good at forgetting things. But I'm not very good at deciding _which_ things to forget...
2020-12-17 21:25:48 +0100wonko7(~wonko7@lns-bzn-55-82-255-183-4.adsl.proxad.net)
2020-12-17 21:26:06 +0100 <monochrom> Kronic: It's alright, when one builds GHC from source, it counts as haskell using haskell, and it's known to take a while :)
2020-12-17 21:26:58 +0100knupfer(~Thunderbi@200116b82c41c500146d97fffe6f228b.dip.versatel-1u1.de)
2020-12-17 21:27:35 +0100 <monochrom> I like haskellbook.com being slow. I no longer recommend it because it has technical inaccuracy that are unnecessary.
2020-12-17 21:27:43 +0100knupfer(~Thunderbi@200116b82c41c500146d97fffe6f228b.dip.versatel-1u1.de) (Remote host closed the connection)
2020-12-17 21:27:56 +0100knupfer(~Thunderbi@200116b82c41c5004d9c68c948169740.dip.versatel-1u1.de)
2020-12-17 21:28:06 +0100 <merijn> monochrom: Which inaccuracies?
2020-12-17 21:28:11 +0100 <monochrom> I forgot.
2020-12-17 21:28:28 +0100 <monochrom> (Conveniently, eh?)
2020-12-17 21:28:50 +0100 <Kronic> what do you recommend instead?
2020-12-17 21:28:51 +0100 <merijn> monochrom: I like that it includes megaparsec and transformers instead of just Haskell, because parser combinators and transformers are kinda mandatory :p
2020-12-17 21:29:20 +0100 <monochrom> Yeah it has a lot of good things.
2020-12-17 21:29:24 +0100 <merijn> Kronic: fwiw it worked well for my girlfriend
2020-12-17 21:29:35 +0100 <Kronic> I own the book already
2020-12-17 21:29:59 +0100 <Kronic> I was just curious because I'm not having many problems making progress, I'm just curious in case I want to recommend a friend or work mate
2020-12-17 21:30:30 +0100 <merijn> I heard Bird's "Thinking Functionally with Haskell" and Hutton's "Programming in Haskell" were good, but I haven't read either
2020-12-17 21:30:43 +0100 <ezzieyguywuf> when a package has a dependency of ">=QuickCheck-2.13.2 && <QuickCheck-2.14", how can I find out the reason for the upper limit?
2020-12-17 21:30:48 +0100 <merijn> Admittedly, I haven't read more than a few half chapters of HFFP either :p
2020-12-17 21:30:59 +0100 <ezzieyguywuf> there's a few that have this same callout for quickcheck
2020-12-17 21:31:03 +0100 <merijn> ezzieyguywuf: Disabling it and seeing if it works ;)
2020-12-17 21:31:14 +0100 <ezzieyguywuf> lol
2020-12-17 21:31:21 +0100 <ezzieyguywuf> is it generally safe to try that?
2020-12-17 21:31:27 +0100 <ph88> xsperry, significantly ... but i would have to measure. bit busy right now to do those measurements
2020-12-17 21:31:36 +0100 <monochrom> I recommend starting with the wikibook, so you don't have to sink money yet, and maybe it is already enough. If it is not enough, then Hutton's, but take it very slowly, it is not long but you should not use speed reading.
2020-12-17 21:31:40 +0100 <merijn> ezzieyguywuf: There is syntax to distinguish "know to not work" and "not known if it works" in newer cabal versions, but not yet
2020-12-17 21:31:43 +0100 <ezzieyguywuf> i.e. do folks usually put the upper limit "just in case"?
2020-12-17 21:31:58 +0100 <merijn> ezzieyguywuf: A lot of people do and the ones who don't *should*
2020-12-17 21:32:02 +0100 <ezzieyguywuf> merijn: awww man can't wait, lol
2020-12-17 21:32:26 +0100 <monochrom> I suspect that the 1000-page length of haskellbook.com works on the simple ground that even if you try speed reading the 1000 pages will slow you down back to the correct pace.
2020-12-17 21:32:29 +0100 <ezzieyguywuf> merijn: hrm, can you elaborote on why one should set an upper limit? should the upper limit always be the next minor rev?
2020-12-17 21:32:29 +0100 <merijn> ezzieyguywuf: "newer" == cabal-install 2.4 :p
2020-12-17 21:32:45 +0100 <merijn> ezzieyguywuf: https://pvp.haskell.org/
2020-12-17 21:33:17 +0100 <ezzieyguywuf> cabal-install 2.4? isn't that super old?
2020-12-17 21:33:27 +0100 <ezzieyguywuf> I'm trying to package 3.2 right now for gentoo
2020-12-17 21:33:44 +0100 <merijn> ezzieyguywuf: In cabal-version 2.4 and later you have "QuickCheck ^>= 2.13" which means "PVP compatible with the API" of 2.13 (which basically means "untested with anything later")
2020-12-17 21:33:49 +0100 <merijn> ezzieyguywuf: Hence "newer" in quotes :p
2020-12-17 21:33:58 +0100 <monochrom> IOW people these days don't stop after every two sentences and close the book and reflect "does it really mean what I think it means? how do I test my understanding?".
2020-12-17 21:34:14 +0100 <merijn> ezzieyguywuf: As opposed to "QuickCheck < 2.14" which then becomes "*known* to not work"
2020-12-17 21:34:29 +0100royal_screwup21(52254809@gateway/web/cgi-irc/kiwiirc.com/ip.82.37.72.9)
2020-12-17 21:35:03 +0100 <merijn> ezzieyguywuf: cabal-install also has a flag to allow newer bounds for all upperbounds from ^>= without automatically including all the < bounds
2020-12-17 21:35:08 +0100 <ezzieyguywuf> merijn: hrm, so in my head that is translating to "If I don't see a ^, probs ok to poke it"
2020-12-17 21:35:09 +0100 <davean> monochrom: Two sentances seems like a sentance and a half too much given how I read research papers
2020-12-17 21:35:11 +0100jess(jess@freenode/staff/jess)
2020-12-17 21:35:44 +0100 <monochrom> Well, for a mere Haskell textbook, it's OK.
2020-12-17 21:35:45 +0100 <merijn> ezzieyguywuf: A lot of cabal files in the wild use an older version of the format for many different reasons, so it's not very wildspread, but yes
2020-12-17 21:35:49 +0100 <ezzieyguywuf> merijn: is that feature specific to cabal-install, or available in the underlying cabal library?
2020-12-17 21:35:50 +0100softwarm(4408f588@ip68-8-245-136.sd.sd.cox.net) (Remote host closed the connection)
2020-12-17 21:35:53 +0100 <merijn> ezzieyguywuf: Actually, more the opposite
2020-12-17 21:36:00 +0100 <merijn> ezzieyguywuf: Which part
2020-12-17 21:36:10 +0100 <ezzieyguywuf> merijn: "allow newer even if it says don't"
2020-12-17 21:36:16 +0100 <merijn> ezzieyguywuf: It's more like "if you see ^ then it probably ok to relax" not the other way
2020-12-17 21:36:20 +0100 <davean> ezzieyguywuf: Cabal.
2020-12-17 21:36:40 +0100 <davean> ezzieyguywuf: cabal-install is just a thing that uses Cabal. Everything really to do with the .cabal file is Cabal.
2020-12-17 21:36:53 +0100 <ezzieyguywuf> right right
2020-12-17 21:36:55 +0100 <merijn> ezzieyguywuf: Since "foo ^>= 3.14" says *known* to work with 3.14 (and PVP compatible releases) which says nothing about whether newer versions work or not
2020-12-17 21:37:08 +0100 <ezzieyguywuf> hrm, I see
2020-12-17 21:37:27 +0100 <ezzieyguywuf> maybe I look at quicheck changelog
2020-12-17 21:37:33 +0100 <merijn> The distinctio between "know to not work" and "not known to work" is why ^>= was introduced
2020-12-17 21:37:38 +0100 <ezzieyguywuf> I mean, from 2.13 to 2.14 what could have changed...
2020-12-17 21:39:24 +0100 <ezzieyguywuf> yea, changelog seems to indicate a bunch of speed improvements behind the scenes, but doesn't explicitly say that the api changed
2020-12-17 21:39:33 +0100royal_screwup21(52254809@gateway/web/cgi-irc/kiwiirc.com/ip.82.37.72.9) (Ping timeout: 256 seconds)
2020-12-17 21:39:33 +0100 <ezzieyguywuf> (I don't even really understand ABI and PVP...)
2020-12-17 21:39:50 +0100 <davean> There are, not well maintained, tools to diff Haskell APIs
2020-12-17 21:39:59 +0100 <davean> but version changes can also relate to semantics
2020-12-17 21:43:04 +0100tenniscp25(~tenniscp2@134.196.209.118)
2020-12-17 21:43:06 +0100kuribas(~user@ptr-25vy0i8agrj36ppuptm.18120a2.ip6.access.telenet.be) (Quit: ERC (IRC client for Emacs 26.3))
2020-12-17 21:44:50 +0100 <ezzieyguywuf> ahh, see random (the package) changelog "breaking change that...."
2020-12-17 21:44:59 +0100ezzieyguywufsees and nods "ah yes, very good to know"
2020-12-17 21:45:42 +0100teardown_(~user@gateway/tor-sasl/mrush)
2020-12-17 21:45:43 +0100 <davean> ight
2020-12-17 21:47:41 +0100tenniscp25(~tenniscp2@134.196.209.118) (Ping timeout: 268 seconds)
2020-12-17 21:48:14 +0100 <ph88> anyone know how i add instance of Parseable to read a csv file ? https://bpa.st/BG4A
2020-12-17 21:49:03 +0100teardown(~user@gateway/tor-sasl/mrush) (Ping timeout: 240 seconds)
2020-12-17 21:49:11 +0100zmagii(~zmagii@unaffiliated/zmagii)
2020-12-17 21:50:48 +0100darjeeling_(~darjeelin@122.245.217.210) (Ping timeout: 265 seconds)
2020-12-17 21:52:51 +0100cosimone(~cosimone@93-47-228-249.ip115.fastwebnet.it)
2020-12-17 21:53:54 +0100Wuzzy(~Wuzzy@p5b0df87d.dip0.t-ipconnect.de)
2020-12-17 21:54:32 +0100todda7(~torstein@ppp-2-84-17-53.home.otenet.gr)
2020-12-17 21:55:51 +0100Vulfe(~vulfe@2600:1702:31b0:34e0:cca6:5d8:2bb0:556c)
2020-12-17 21:55:56 +0100apoc(~apoc@bridge.mattzq.com) (Ping timeout: 240 seconds)
2020-12-17 21:57:37 +0100machinedgod(~machinedg@24.105.81.50)
2020-12-17 21:57:38 +0100apoc(~apoc@bridge.mattzq.com)
2020-12-17 21:58:20 +0100redmp(~redmp@mobile-166-177-250-97.mycingular.net)
2020-12-17 22:00:49 +0100oish(~charlie@228.25.169.217.in-addr.arpa) (Ping timeout: 264 seconds)
2020-12-17 22:03:20 +0100borne(~fritjof@200116b864804800c0a3d285e8e687f4.dip.versatel-1u1.de)
2020-12-17 22:03:43 +0100pavonia(~user@unaffiliated/siracusa)
2020-12-17 22:04:46 +0100darjeeling_(~darjeelin@122.245.217.210)
2020-12-17 22:07:41 +0100jollygood2(~bc8165ab@217.29.117.252)
2020-12-17 22:07:45 +0100electricityZZZZ(~electrici@108-216-157-17.lightspeed.sntcca.sbcglobal.net)
2020-12-17 22:08:44 +0100xcmw(~textual@2603-6011-2200-f103-8011-a882-4e38-cf45.res6.spectrum.com)
2020-12-17 22:10:04 +0100sord937(~sord937@gateway/tor-sasl/sord937) (Quit: sord937)
2020-12-17 22:10:51 +0100royal_screwup21(52254809@gateway/web/cgi-irc/kiwiirc.com/ip.82.37.72.9)
2020-12-17 22:13:43 +0100LKoen(~LKoen@29.248.88.92.rev.sfr.net) (Quit: “It’s only logical. First you learn to talk, then you learn to think. Too bad it’s not the other way round.”)
2020-12-17 22:15:18 +0100 <ph88> oh found it i think
2020-12-17 22:15:44 +0100royal_screwup21(52254809@gateway/web/cgi-irc/kiwiirc.com/ip.82.37.72.9) (Ping timeout: 256 seconds)
2020-12-17 22:17:17 +0100arahael(~arahael@194-193-194-178.tpgi.com.au)
2020-12-17 22:21:28 +0100Philipp(~Philipp@8.43.122.34)
2020-12-17 22:24:30 +0100Philipp(~Philipp@8.43.122.34) (Client Quit)
2020-12-17 22:30:43 +0100 <ph88> hurray, after 4 hours i was able to read a line from the csv :D
2020-12-17 22:32:37 +0100raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net)
2020-12-17 22:34:03 +0100 <dsal> Frames? Are you doing R in Haskell?
2020-12-17 22:36:12 +0100 <ph88> https://hackage.haskell.org/package/Frames-0.7.0
2020-12-17 22:41:20 +0100knupfer(~Thunderbi@200116b82c41c5004d9c68c948169740.dip.versatel-1u1.de) (Ping timeout: 268 seconds)
2020-12-17 22:43:51 +0100merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 272 seconds)
2020-12-17 22:44:13 +0100royal_screwup21(52254809@gateway/web/cgi-irc/kiwiirc.com/ip.82.37.72.9)
2020-12-17 22:46:10 +0100 <koz_> . o O ('R in Haskell' = 'Raskell'? )
2020-12-17 22:48:01 +0100 <Rembane> Rascal!
2020-12-17 22:48:31 +0100 <koz_> Data-oriented Scheme dialect gogo?
2020-12-17 22:48:45 +0100royal_screwup21(52254809@gateway/web/cgi-irc/kiwiirc.com/ip.82.37.72.9) (Ping timeout: 240 seconds)
2020-12-17 22:48:54 +0100 <geekosaur> waskelly wabbit?
2020-12-17 22:49:58 +0100borne(~fritjof@200116b864804800c0a3d285e8e687f4.dip.versatel-1u1.de) (Ping timeout: 268 seconds)
2020-12-17 22:49:58 +0100 <Rembane> ...for the enterprise
2020-12-17 22:54:44 +0100mounty(~mounty@2001:8000:2f59:0:6c2e:3caf:57c1:9c66)
2020-12-17 22:55:41 +0100geekosaur(42d52137@66.213.33.55) (Remote host closed the connection)
2020-12-17 22:56:08 +0100u0_a298(~user@47.206.148.226) (Ping timeout: 268 seconds)
2020-12-17 22:56:15 +0100justsomeguy(~justsomeg@unaffiliated/--/x-3805311)
2020-12-17 22:56:24 +0100redmp(~redmp@mobile-166-177-250-97.mycingular.net) (Quit: byeee)
2020-12-17 22:56:45 +0100star_cloud(~star_clou@ec2-34-220-44-120.us-west-2.compute.amazonaws.com)
2020-12-17 22:58:33 +0100taurux(~taurux@net-93-144-87-101.cust.dsl.teletu.it) (Quit: ZNC 1.7.5 - https://znc.in)
2020-12-17 23:00:23 +0100Rudd0(~Rudd0@185.189.115.108)
2020-12-17 23:02:49 +0100Ariakenom_(~Ariakenom@2001:9b1:efb:fc00:c9f8:3d5b:f807:f873) (Read error: Connection reset by peer)
2020-12-17 23:04:06 +0100boxscape(4ff0ba59@gateway/web/cgi-irc/kiwiirc.com/ip.79.240.186.89) (Quit: Connection closed)
2020-12-17 23:06:47 +0100olligobber(olligobber@gateway/vpn/privateinternetaccess/olligobber)
2020-12-17 23:06:54 +0100kenran(~kenran@i59F67BCB.versanet.de) (Quit: leaving)
2020-12-17 23:07:02 +0100Stanley00(~stanley00@unaffiliated/stanley00)
2020-12-17 23:07:31 +0100kupi(uid212005@gateway/web/irccloud.com/x-mktflcfjzasruohy) (Quit: Connection closed for inactivity)
2020-12-17 23:07:43 +0100Ariakenom(~Ariakenom@2001:9b1:efb:fc00:1de4:7265:50e8:3545) (Ping timeout: 260 seconds)
2020-12-17 23:09:11 +0100mirrorbird(~psutcliff@2a00:801:447:b1bf:a43d:1573:86a9:1f86)
2020-12-17 23:09:41 +0100ubert(~Thunderbi@p200300ecdf35147ee6b318fffe838f33.dip0.t-ipconnect.de) (Remote host closed the connection)
2020-12-17 23:09:42 +0100dhil(~dhil@78.156.97.38) (Ping timeout: 268 seconds)
2020-12-17 23:10:03 +0100ubert(~Thunderbi@p200300ecdf35147ee6b318fffe838f33.dip0.t-ipconnect.de)
2020-12-17 23:11:11 +0100merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-12-17 23:11:33 +0100Stanley00(~stanley00@unaffiliated/stanley00) (Ping timeout: 268 seconds)
2020-12-17 23:12:14 +0100fendor_(~fendor@77.119.130.146.wireless.dyn.drei.com) (Remote host closed the connection)
2020-12-17 23:13:13 +0100 <koz_> Is there some newtype Foo over Maybe a, such that we have a Semigroup instance where 'Foo Nothing' is an absorbing element?
2020-12-17 23:13:26 +0100 <koz_> (assuming a has a Semigroup instance of its own)
2020-12-17 23:14:01 +0100raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) (Ping timeout: 264 seconds)
2020-12-17 23:14:10 +0100teardown(~user@gateway/tor-sasl/mrush)
2020-12-17 23:15:56 +0100merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 240 seconds)
2020-12-17 23:16:00 +0100raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net)
2020-12-17 23:16:46 +0100u0_a298(~user@65.35.205.131)
2020-12-17 23:17:01 +0100 <dolio> Ap Maybe?
2020-12-17 23:17:03 +0100teardown_(~user@gateway/tor-sasl/mrush) (Ping timeout: 240 seconds)
2020-12-17 23:17:30 +0100 <koz_> dolio: Perfect, thank you!
2020-12-17 23:17:45 +0100 <koz_> I assume its Monoid instance just does 'Just mempty'?
2020-12-17 23:17:57 +0100 <dolio> Presumably.
2020-12-17 23:18:27 +0100 <koz_> Appears like it does, awesome.
2020-12-17 23:19:31 +0100 <koz_> Time for sick deriving shenanigans.
2020-12-17 23:20:34 +0100elliott__(~elliott@pool-108-51-101-42.washdc.fios.verizon.net)
2020-12-17 23:20:56 +0100nineonine(~nineonine@50.216.62.2) (Ping timeout: 240 seconds)
2020-12-17 23:21:11 +0100Varis(~Tadas@unaffiliated/varis) (Remote host closed the connection)
2020-12-17 23:21:25 +0100royal_screwup21(52254809@gateway/web/cgi-irc/kiwiirc.com/ip.82.37.72.9)
2020-12-17 23:21:46 +0100matryoshka(~matryoshk@184.75.223.227) (Read error: Connection reset by peer)
2020-12-17 23:21:58 +0100matryoshka(~matryoshk@2606:6080:1002:8:3285:30e:de43:8809)
2020-12-17 23:22:16 +0100hyperisco(~hyperisco@d192-186-117-226.static.comm.cgocable.net) (Ping timeout: 240 seconds)
2020-12-17 23:23:59 +0100Varis(~Tadas@unaffiliated/varis)
2020-12-17 23:24:39 +0100borne(~fritjof@200116b864804800c0a3d285e8e687f4.dip.versatel-1u1.de)
2020-12-17 23:25:52 +0100carlomagno(~cararell@148.87.23.9) (Remote host closed the connection)
2020-12-17 23:26:12 +0100carlomagno(~cararell@148.87.23.9)
2020-12-17 23:29:26 +0100borne(~fritjof@200116b864804800c0a3d285e8e687f4.dip.versatel-1u1.de) (Ping timeout: 268 seconds)
2020-12-17 23:29:33 +0100 <koz_> "The pat_lhs for explicitly bidirectional construction cannot use Record syntax. (Because the rhs expr might be constructing different data constructors.) It can use guards with multiple equations."
2020-12-17 23:29:51 +0100 <koz_> Is the intent of the sentence that 'guards with multiple equations' can substitute for Record syntax?
2020-12-17 23:29:55 +0100 <koz_> Or are they just unrelated?
2020-12-17 23:30:23 +0100rayyyy(~nanoz@gateway/tor-sasl/nanoz) (Ping timeout: 240 seconds)
2020-12-17 23:32:53 +0100u0_a298(~user@65.35.205.131) (Read error: Connection reset by peer)
2020-12-17 23:33:23 +0100notzmv`notzmv
2020-12-17 23:33:35 +0100 <monochrom> Unrelated.
2020-12-17 23:33:42 +0100u0_a298(~user@65.35.205.131)
2020-12-17 23:33:42 +0100notzmv(~user@191.205.12.9) (Changing host)
2020-12-17 23:33:42 +0100notzmv(~user@unaffiliated/zmv)
2020-12-17 23:33:45 +0100 <koz_> Figured as much, sads.
2020-12-17 23:39:18 +0100danvet(~Daniel@2a02:168:57f4:0:efd0:b9e5:5ae6:c2fa) (Ping timeout: 268 seconds)
2020-12-17 23:41:06 +0100borne(~fritjof@200116b864804800c0a3d285e8e687f4.dip.versatel-1u1.de)
2020-12-17 23:42:01 +0100johnw(~johnw@haskell/developer/johnw) (Quit: ZNC - http://znc.in)
2020-12-17 23:42:50 +0100merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-12-17 23:54:24 +0100dbmikus(~dbmikus@c-174-49-172-14.hsd1.pa.comcast.net) (Ping timeout: 256 seconds)
2020-12-17 23:57:31 +0100notzmv(~user@unaffiliated/zmv) (Remote host closed the connection)