Home freenode/#haskell: Logs Calendar

Logs: freenode/#haskell

←Prev  Next→ 502,152 events total
2021-03-31 15:37:32 × bitdex quits (~bitdex@gateway/tor-sasl/bitdex) (Quit: = "")
2021-03-31 15:40:37 × cfricke quits (~cfricke@unaffiliated/cfricke) (Ping timeout: 268 seconds)
2021-03-31 15:40:50 __minoru__shirae joins (~shiraeesh@109.166.57.243)
2021-03-31 15:43:05 × bergey quits (~user@pool-74-108-99-127.nycmny.fios.verizon.net) (Ping timeout: 260 seconds)
2021-03-31 15:45:18 × stree quits (~stree@68.36.8.116) (Ping timeout: 240 seconds)
2021-03-31 15:46:18 mrlazos joins (~mrlazos@46-44-92.adsl.cyta.gr)
2021-03-31 15:47:55 × mrlazos quits (~mrlazos@46-44-92.adsl.cyta.gr) (Remote host closed the connection)
2021-03-31 15:48:00 × merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 268 seconds)
2021-03-31 15:48:30 heatsink joins (~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2021-03-31 15:48:31 mrlazos joins (~mrlazos@46-44-92.adsl.cyta.gr)
2021-03-31 15:48:50 × mrlazos quits (~mrlazos@46-44-92.adsl.cyta.gr) (Client Quit)
2021-03-31 15:49:06 mrlazos joins (~mrlazos@46-44-92.adsl.cyta.gr)
2021-03-31 15:49:09 × mrlazos quits (~mrlazos@46-44-92.adsl.cyta.gr) (Client Quit)
2021-03-31 15:49:21 mrlazos joins (~mrlazos@46-44-92.adsl.cyta.gr)
2021-03-31 15:50:34 dbmikus joins (~dbmikus@cpe-76-167-86-219.natsow.res.rr.com)
2021-03-31 15:51:02 × deviantfero quits (~deviantfe@190.150.27.58) (Quit: WeeChat 3.1)
2021-03-31 15:51:11 frozenErebus joins (~frozenEre@37.231.244.249)
2021-03-31 15:51:20 × enoq quits (~textual@194-208-146-143.lampert.tv) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2021-03-31 15:52:49 × dandart quits (~Thunderbi@home.dandart.co.uk) (Remote host closed the connection)
2021-03-31 15:55:15 × dbmikus quits (~dbmikus@cpe-76-167-86-219.natsow.res.rr.com) (Ping timeout: 246 seconds)
2021-03-31 15:56:53 solvr35 joins (57e3c46d@87.227.196.109)
2021-03-31 15:57:42 × solvr quits (57e3c46d@87.227.196.109) (Ping timeout: 240 seconds)
2021-03-31 15:58:09 × molehillish quits (~molehilli@2600:8800:8d06:1800:49e2:dd02:cb68:846) (Remote host closed the connection)
2021-03-31 15:58:10 masterplain joins (ce7fb161@ics177-97.icsincorporated.com)
2021-03-31 15:58:51 stree joins (~stree@68.36.8.116)
2021-03-31 15:59:59 molehillish joins (~molehilli@2600:8800:8d06:1800:49e2:dd02:cb68:846)
2021-03-31 16:00:03 × joe[m]1 quits (joemonoida@gateway/shell/matrix.org/x-ddskqwzpoidneuno) (Quit: Idle for 30+ days)
2021-03-31 16:00:18 geekosaur joins (82650c7a@130.101.12.122)
2021-03-31 16:00:28 electricityZZZZ joins (~electrici@135-180-3-82.static.sonic.net)
2021-03-31 16:00:49 dbmikus joins (~dbmikus@cpe-76-167-86-219.natsow.res.rr.com)
2021-03-31 16:01:00 solvr joins (57e3c46d@87.227.196.109)
2021-03-31 16:01:56 × ep1ctetus quits (~epictetus@ip72-194-215-136.sb.sd.cox.net) (Ping timeout: 260 seconds)
2021-03-31 16:03:06 × malumore_ quits (~malumore@151.62.117.70) (Ping timeout: 240 seconds)
2021-03-31 16:03:10 jakalx parts (~jakalx@base.jakalx.net) ()
2021-03-31 16:04:02 × solvr35 quits (57e3c46d@87.227.196.109) (Ping timeout: 240 seconds)
2021-03-31 16:04:34 × molehillish quits (~molehilli@2600:8800:8d06:1800:49e2:dd02:cb68:846) (Ping timeout: 245 seconds)
2021-03-31 16:04:45 × mouseghost quits (~draco@wikipedia/desperek) (Quit: mew wew)
2021-03-31 16:04:50 ep1ctetus joins (~epictetus@ip72-194-215-136.sb.sd.cox.net)
2021-03-31 16:05:54 × dbmikus quits (~dbmikus@cpe-76-167-86-219.natsow.res.rr.com) (Ping timeout: 268 seconds)
2021-03-31 16:05:55 supercoven joins (~Supercove@dsl-hkibng31-54fabd-233.dhcp.inet.fi)
2021-03-31 16:07:51 ezrakilty joins (~ezrakilty@97-126-86-140.tukw.qwest.net)
2021-03-31 16:15:43 merijn joins (~merijn@83-160-49-249.ip.xs4all.nl)
2021-03-31 16:17:26 Tuplanolla joins (~Tuplanoll@91-159-68-239.elisa-laajakaista.fi)
2021-03-31 16:18:25 × xff0x quits (~xff0x@2001:1a81:52d9:7900:4e7f:f403:b0b5:ef3) (Ping timeout: 250 seconds)
2021-03-31 16:19:10 xff0x joins (~xff0x@2001:1a81:52d9:7900:15bf:3601:850c:fab3)
2021-03-31 16:20:10 × ezrakilty quits (~ezrakilty@97-126-86-140.tukw.qwest.net) (Remote host closed the connection)
2021-03-31 16:20:46 × merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 240 seconds)
2021-03-31 16:24:43 malumore_ joins (~malumore@151.62.117.70)
2021-03-31 16:28:16 fuzzy_id joins (~user@1.red-88-0-41.dynamicip.rima-tde.net)
2021-03-31 16:29:23 molehillish joins (~molehilli@2600:8800:8d06:1800:49e2:dd02:cb68:846)
2021-03-31 16:30:20 <fuzzy_id> What's the lens way to apply a getter to a Maybe?
2021-03-31 16:31:15 <fuzzy_id> i.e. an alternative for 'fmap (^. g) $ x ^. f'
2021-03-31 16:31:30 <fuzzy_id> where 'x ^. f' is of type Maybe a
2021-03-31 16:32:00 <fuzzy_id> I'm starring at prisms and my head is melting. :/
2021-03-31 16:32:42 <kuribas> fuzzy_id: traverse?
2021-03-31 16:32:51 Guest41032 joins (~laudiacay@67.176.215.84)
2021-03-31 16:33:49 × evanjs- quits (~evanjs@075-129-098-007.res.spectrum.com) (Quit: ZNC 1.8.2 - https://znc.in)
2021-03-31 16:33:50 <kuribas> > preview (_1 . traverse) (Just 3, "foo")
2021-03-31 16:33:52 <lambdabot> Just 3
2021-03-31 16:34:00 <kuribas> or _Just
2021-03-31 16:34:05 <kuribas> > preview (_1 . _Just) (Just 3, "foo")
2021-03-31 16:34:07 <lambdabot> Just 3
2021-03-31 16:34:11 chele joins (~chele@ip5b40237d.dynamic.kabel-deutschland.de)
2021-03-31 16:34:37 <kuribas> > tolistOf (_1 . traverse) (Just 3, "foo")
2021-03-31 16:34:39 <lambdabot> error:
2021-03-31 16:34:39 <lambdabot> • Variable not in scope:
2021-03-31 16:34:39 <lambdabot> tolistOf
2021-03-31 16:35:18 <kuribas> > toListOf (_1 . traverse) (Just 3, "foo")
2021-03-31 16:35:20 <lambdabot> [3]
2021-03-31 16:35:31 <kuribas> > toListOf (_1 . _Just) (Nothing, "foo")
2021-03-31 16:35:32 <lambdabot> []
2021-03-31 16:36:10 evanjs joins (~evanjs@075-129-098-007.res.spectrum.com)
2021-03-31 16:36:52 <raehik> fuzzy_id: using view and (<$>) might make it look nicer?
2021-03-31 16:36:58 × Guest41032 quits (~laudiacay@67.176.215.84) (Ping timeout: 240 seconds)
2021-03-31 16:37:07 <raehik> > view _1 <$> (Just (1, 2))
2021-03-31 16:37:09 <lambdabot> Just 1
2021-03-31 16:37:26 <raehik> (apologies I don't do enough lenses to rewrite your example)
2021-03-31 16:38:07 × molehillish quits (~molehilli@2600:8800:8d06:1800:49e2:dd02:cb68:846) (Ping timeout: 258 seconds)
2021-03-31 16:38:49 dbmikus joins (~dbmikus@cpe-76-167-86-219.natsow.res.rr.com)
2021-03-31 16:38:57 Deide joins (~Deide@217.155.19.23)
2021-03-31 16:39:49 <fuzzy_id> raehik: Yeah, I guess I go with that.
2021-03-31 16:40:05 <fuzzy_id> kuribas: tbh I don't have any idea how to apply your suggestions. :P
2021-03-31 16:40:16 <kuribas> raehik: that only works if the Maybe is outer.
2021-03-31 16:40:43 <raehik> yes
2021-03-31 16:41:37 × solvr quits (57e3c46d@87.227.196.109) (Quit: Connection closed)
2021-03-31 16:41:37 <kuribas> raehik: give an example where you are failing?
2021-03-31 16:42:48 <raehik> kuribas: I think you meant to tag fuzzy_id!
2021-03-31 16:42:58 <kuribas> eh, right
2021-03-31 16:43:19 pavonia joins (~user@unaffiliated/siracusa)
2021-03-31 16:44:13 gaff joins (~user@49.207.224.136)
2021-03-31 16:44:20 <kuribas> fuzzy_id: traverse targets all elements of a Traversable. _Just targets a maybe value if it is a Just.
2021-03-31 16:44:27 <kuribas> fuzzy_id: which means the same thing in the end.
2021-03-31 16:44:42 <gaff> i have some code pasted at https://pastebin.com/mBevWnT4
2021-03-31 16:44:57 <kuribas> fuzzy_id: also, since you may return no values, you need to use preview or toListOf.
2021-03-31 16:45:20 <kuribas> fuzzy_id: because view always returns a value, but that doesn't work when the Maybe is Nothing.
2021-03-31 16:45:50 argento joins (~argent0@191.81.225.82)
2021-03-31 16:45:55 average joins (uid473595@gateway/web/irccloud.com/x-ygfxxolhucppzalr)
2021-03-31 16:46:00 <fuzzy_id> Hmm. Let's see, I need something to fetch the 2 in 'x = (Just (1, 2), 3)'
2021-03-31 16:46:38 <kuribas> > preview (_Just . _2) (Just (1, 2), 3)
2021-03-31 16:46:40 <lambdabot> error:

All times are in UTC.