Home liberachat/#haskell: Logs Calendar

Logs on 2021-07-25 (liberachat/#haskell)

00:02:04 phma joins (~phma@2001:5b0:211f:7588:d0bc:3afd:37cf:6fa6)
00:03:22 × favonia quits (~favonia@user/favonia) (Ping timeout: 240 seconds)
00:03:24 × phma quits (~phma@2001:5b0:211f:7588:d0bc:3afd:37cf:6fa6) (Read error: Connection reset by peer)
00:03:41 favonia joins (~favonia@user/favonia)
00:03:49 phma joins (~phma@host-67-44-209-47.hnremote.net)
00:05:17 × raehik1 quits (~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) (Ping timeout: 255 seconds)
00:05:36 × LukeHoersten quits (~LukeHoers@user/lukehoersten) (Quit: My MacBook has gone to sleep. ZZZzzz…)
00:06:02 LukeHoersten joins (~LukeHoers@user/lukehoersten)
00:06:06 × LukeHoersten quits (~LukeHoers@user/lukehoersten) (Client Quit)
00:08:09 <DigitalKiwi> spoilers; https://en.wikipedia.org/wiki/List_of_Dune_secondary_characters#Daniel_and_Marty
00:08:15 LukeHoersten joins (~LukeHoers@user/lukehoersten)
00:09:14 × chomwitt quits (~chomwitt@2a02:587:dc0e:ef00:12c3:7bff:fe6d:d374) (Remote host closed the connection)
00:11:49 raehik1 joins (~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net)
00:11:54 × LukeHoersten quits (~LukeHoers@user/lukehoersten) (Client Quit)
00:14:48 × Topsi quits (~Tobias@dyndsl-091-249-083-202.ewe-ip-backbone.de) (Quit: Leaving.)
00:18:36 vicfred joins (~vicfred@user/vicfred)
00:19:58 × drd quits (~drd@2001:b07:a70:9f1f:1562:34de:f50f:77d4) (Ping timeout: 256 seconds)
00:25:06 peterhil joins (~peterhil@mobile-access-b04801-219.dhcp.inet.fi)
00:28:28 lavaman joins (~lavaman@98.38.249.169)
00:30:34 × merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 265 seconds)
00:30:52 × lavaman quits (~lavaman@98.38.249.169) (Remote host closed the connection)
00:31:26 lavaman joins (~lavaman@98.38.249.169)
00:32:07 × Tuplanolla quits (~Tuplanoll@91-159-68-239.elisa-laajakaista.fi) (Quit: Leaving.)
00:33:36 nate1 joins (~nate@108-233-125-227.lightspeed.sntcca.sbcglobal.net)
00:35:27 nate2 joins (~nate@2600:1010:b005:5a54:c5a2:de43:b326:7069)
00:35:56 × lavaman quits (~lavaman@98.38.249.169) (Ping timeout: 252 seconds)
00:38:18 × nate1 quits (~nate@108-233-125-227.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 265 seconds)
00:39:01 lavaman joins (~lavaman@98.38.249.169)
00:39:48 × curiousgay quits (~curiousga@77-120-186-48.kha.volia.net) (Ping timeout: 256 seconds)
00:42:18 agua joins (~agua@2804:18:4d:af57:1:0:4dec:eb61)
00:43:30 × pesada quits (~agua@191.177.175.57) (Ping timeout: 250 seconds)
00:43:56 × Gurkenglas quits (~Gurkengla@dslb-002-203-144-156.002.203.pools.vodafone-ip.de) (Ping timeout: 250 seconds)
00:48:10 × econo quits (uid147250@user/econo) (Quit: Connection closed for inactivity)
00:49:31 × Axman6 quits (~Axman6@user/axman6) (Remote host closed the connection)
00:52:05 × lbseale quits (~lbseale@user/ep1ctetus) (Ping timeout: 255 seconds)
00:54:19 × lavaman quits (~lavaman@98.38.249.169) (Remote host closed the connection)
00:54:47 × favonia quits (~favonia@user/favonia) (Ping timeout: 255 seconds)
00:54:57 × laprice quits (~laprice@c-71-238-52-236.hsd1.or.comcast.net) (Quit: Lost terminal)
00:55:43 favonia joins (~favonia@user/favonia)
00:59:11 × eggplantade quits (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Remote host closed the connection)
00:59:52 eggplantade joins (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net)
01:01:19 × eggplantade quits (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Remote host closed the connection)
01:01:49 eggplantade joins (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net)
01:05:08 × favonia quits (~favonia@user/favonia) (Ping timeout: 255 seconds)
01:05:20 curiousgay joins (~curiousga@77-120-186-48.kha.volia.net)
01:07:29 favonia joins (~favonia@user/favonia)
01:08:03 lavaman joins (~lavaman@98.38.249.169)
01:09:11 Axman6 joins (~Axman6@user/axman6)
01:11:34 × albet70 quits (~xxx@2400:8902::f03c:92ff:fe60:98d8) (Remote host closed the connection)
01:12:42 albet70 joins (~xxx@2400:8902::f03c:92ff:fe60:98d8)
01:15:07 pavonia joins (~user@user/siracusa)
01:16:23 × xff0x_ quits (~xff0x@2001:1a81:53c2:cd00:83d7:3823:c8d1:341c) (Ping timeout: 255 seconds)
01:16:47 eltonpinto joins (~1ntEgr8@2601:c8:c000:3090:96d:7043:ac49:cacb)
01:18:15 × eltonpinto quits (~1ntEgr8@2601:c8:c000:3090:96d:7043:ac49:cacb) (Client Quit)
01:18:16 xff0x_ joins (~xff0x@2001:1a81:5200:1d00:97a8:d110:8021:86ce)
01:18:31 eltonpinto joins (~1ntEgr8@2601:c8:c000:3090:96d:7043:ac49:cacb)
01:20:36 × favonia quits (~favonia@user/favonia) (Ping timeout: 256 seconds)
01:23:22 favonia joins (~favonia@user/favonia)
01:23:41 econo joins (uid147250@user/econo)
01:28:06 LukeHoersten joins (~LukeHoers@user/lukehoersten)
01:31:06 × eltonpinto quits (~1ntEgr8@2601:c8:c000:3090:96d:7043:ac49:cacb) (Ping timeout: 268 seconds)
01:44:30 × Null_A quits (~null_a@2601:645:8700:2290:809c:ae43:df71:6365) (Read error: Connection reset by peer)
01:45:05 Null_A joins (~null_a@2601:645:8700:2290:809c:ae43:df71:6365)
01:46:50 × Atum_ quits (~IRC@user/atum/x-2392232) (Quit: Atum_)
01:49:30 × Null_A quits (~null_a@2601:645:8700:2290:809c:ae43:df71:6365) (Ping timeout: 256 seconds)
01:50:24 bitmapper joins (uid464869@id-464869.tooting.irccloud.com)
01:51:53 × Brumaire quits (~quassel@81-64-14-121.rev.numericable.fr) (Ping timeout: 258 seconds)
01:52:43 eltonpinto joins (~1ntEgr8@2601:c8:c000:3090:d816:bb5b:d12f:f798)
01:54:29 × eltonpinto quits (~1ntEgr8@2601:c8:c000:3090:d816:bb5b:d12f:f798) (Client Quit)
01:55:19 dajoer joins (~david@user/gvx)
01:59:32 ph88 joins (~ph88@2a02:8109:9e00:7e5c:8db8:987d:36eb:f1a6)
02:01:07 thomasjm[m] joins (~thomasjmm@2001:470:69fc:105::c6d9)
02:02:33 × waleee quits (~waleee@2001:9b0:216:8200:d457:9189:7843:1dbd) (Ping timeout: 268 seconds)
02:03:54 × ph88 quits (~ph88@2a02:8109:9e00:7e5c:8db8:987d:36eb:f1a6) (Ping timeout: 240 seconds)
02:04:09 Null_A joins (~null_a@2601:645:8700:2290:1:e11e:d55b:188f)
02:06:45 × td_ quits (~td@muedsl-82-207-238-101.citykom.de) (Ping timeout: 276 seconds)
02:07:09 Topsi joins (~Tobias@dyndsl-091-249-083-202.ewe-ip-backbone.de)
02:08:17 × fawful quits (~guy@c-76-104-217-93.hsd1.wa.comcast.net) (Quit: WeeChat 3.2)
02:08:19 td_ joins (~td@muedsl-82-207-238-027.citykom.de)
02:08:58 × shapr quits (~user@pool-100-36-247-68.washdc.fios.verizon.net) (Ping timeout: 252 seconds)
02:08:58 × MQ-17J quits (~MQ-17J@d14-69-206-129.try.wideopenwest.com) (Read error: Connection reset by peer)
02:09:25 MQ-17J joins (~MQ-17J@d14-69-206-129.try.wideopenwest.com)
02:16:02 × jao quits (~jao@cpc103048-sgyl39-2-0-cust502.18-2.cable.virginm.net) (Ping timeout: 258 seconds)
02:17:02 lbseale joins (~lbseale@user/ep1ctetus)
02:17:32 × wroathe quits (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Ping timeout: 250 seconds)
02:23:13 × lavaman quits (~lavaman@98.38.249.169) (Remote host closed the connection)
02:24:28 × curiousgay quits (~curiousga@77-120-186-48.kha.volia.net) (Ping timeout: 258 seconds)
02:24:33 × bin_ quits (~bin@user/bin/x-1583188) (Quit: ZNC - https://znc.in)
02:26:44 merijn joins (~merijn@83-160-49-249.ip.xs4all.nl)
02:26:52 _bin joins (~bin@user/bin/x-1583188)
02:28:57 × geekosaur quits (~geekosaur@xmonad/geekosaur) (Remote host closed the connection)
02:30:28 slowButPresent joins (~slowButPr@user/slowbutpresent)
02:31:25 finn_elija joins (~finn_elij@user/finn-elija/x-0085643)
02:31:25 × FinnElija quits (~finn_elij@user/finn-elija/x-0085643) (Killed (copper.libera.chat (Nickname regained by services)))
02:31:25 finn_elija is now known as FinnElija
02:32:26 × favonia quits (~favonia@user/favonia) (Ping timeout: 255 seconds)
02:33:00 geekosaur joins (~geekosaur@xmonad/geekosaur)
02:34:02 wroathe joins (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
02:34:57 favonia joins (~favonia@user/favonia)
02:35:25 machinedgod joins (~machinedg@s72-38-105-27.static.comm.cgocable.net)
02:39:33 × wroathe quits (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Ping timeout: 268 seconds)
02:44:44 nate3 joins (~nate@2600:1010:b014:ea44:558f:f06a:16ea:88da)
02:46:10 × nate2 quits (~nate@2600:1010:b005:5a54:c5a2:de43:b326:7069) (Ping timeout: 256 seconds)
02:46:42 × peterhil quits (~peterhil@mobile-access-b04801-219.dhcp.inet.fi) (Ping timeout: 240 seconds)
02:48:34 norias joins (~jaredm@c-98-219-195-163.hsd1.pa.comcast.net)
02:51:52 sim590 joins (~simon@modemcable090.207-203-24.mc.videotron.ca)
02:53:54 × raehik1 quits (~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) (Ping timeout: 240 seconds)
02:54:33 eltonpin1 joins (~1ntEgr8@2601:c8:c000:3090:20d2:58dd:3f51:cdf0)
02:55:57 Guest6667 joins (~Guest66@pool-173-71-126-18.cmdnnj.fios.verizon.net)
02:58:01 × Guest6667 quits (~Guest66@pool-173-71-126-18.cmdnnj.fios.verizon.net) (Client Quit)
03:00:53 × merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 265 seconds)
03:05:37 × Sgeo quits (~Sgeo@user/sgeo) (Read error: Connection reset by peer)
03:07:33 × Guest22 quits (~Guest22@bras-base-orlnon0604w-grc-44-74-12-3-79.dsl.bell.ca) (Quit: Client closed)
03:11:06 × nate3 quits (~nate@2600:1010:b014:ea44:558f:f06a:16ea:88da) (Ping timeout: 240 seconds)
03:17:52 × xkuru quits (~xkuru@user/xkuru) (Read error: Connection reset by peer)
03:21:36 wroathe joins (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
03:21:45 × norias quits (~jaredm@c-98-219-195-163.hsd1.pa.comcast.net) (Quit: Leaving)
03:26:39 lavaman joins (~lavaman@98.38.249.169)
03:28:06 Sgeo joins (~Sgeo@user/sgeo)
03:29:54 × alx741 quits (~alx741@186.178.108.59) (Quit: alx741)
03:31:46 Guest5 joins (~Guest5@50.47.115.102)
03:35:09 nate3 joins (~nate@108-233-125-227.lightspeed.sntcca.sbcglobal.net)
03:36:25 × lbseale quits (~lbseale@user/ep1ctetus) (Read error: Connection reset by peer)
03:37:16 <Guest5> Hello! I know that C# has a "using" statement to help correctly use manually managed resources like file readers. Is there a library that adds the same functionality in Haskell?
03:38:04 <eltonpin1> Do you mean something like "automatically close a file once it goes out of scope"?
03:38:22 × eltonpin1 quits (~1ntEgr8@2601:c8:c000:3090:20d2:58dd:3f51:cdf0) (Quit: WeeChat 3.1)
03:38:38 eltonpinto joins (~1ntEgr8@2601:c8:c000:3090:20d2:58dd:3f51:cdf0)
03:38:41 <Guest5> yes
03:39:10 <davean> Guest5: many systems are structured with "with" functions
03:39:21 <davean> Guest5: for example, bracket enables that, its pretty normal
03:40:27 <eltonpinto> https://hackage.haskell.org/package/regions
03:41:00 <Guest5> Neat, thanks!
03:41:09 <davean> I'd say the morn usual form is ? -> (a -> m b) -> m b
03:41:22 × spiunx quits (~spiun@2a01:4b00:86a9:fb00:8779:c06f:3ad1:b557) (Remote host closed the connection)
03:41:32 <davean> Theres many levels of complexity to flexability of it though, like the regions package, and others
03:43:10 <davean> withFile :: FilePath -> IOMode -> (Handle -> IO r) -> IO r for example
03:47:35 × xff0x_ quits (~xff0x@2001:1a81:5200:1d00:97a8:d110:8021:86ce) (Ping timeout: 255 seconds)
03:48:30 xff0x_ joins (~xff0x@2001:1a81:5200:1d00:ce05:e9a7:78b7:c1fe)
03:52:59 × favonia quits (~favonia@user/favonia) (Ping timeout: 255 seconds)
03:53:17 favonia joins (~favonia@user/favonia)
03:57:52 × HarveyPwca quits (~HarveyPwc@2601:246:c180:a570:29df:3b00:ad0e:3a06) (Quit: Leaving)
04:01:36 justsomeguy joins (~justsomeg@user/justsomeguy)
04:02:26 × machinedgod quits (~machinedg@s72-38-105-27.static.comm.cgocable.net) (Ping timeout: 255 seconds)
04:05:09 adanwan joins (~adanwan@gateway/tor-sasl/adanwan)
04:05:52 × adanwan quits (~adanwan@gateway/tor-sasl/adanwan) (Remote host closed the connection)
04:06:05 adanwan joins (~adanwan@gateway/tor-sasl/adanwan)
04:08:00 × adanwan_ quits (~adanwan@gateway/tor-sasl/adanwan) (Remote host closed the connection)
04:08:58 × LukeHoersten quits (~LukeHoers@user/lukehoersten) (Quit: My MacBook has gone to sleep. ZZZzzz…)
04:17:03 Topsi1 joins (~Tobias@dyndsl-095-033-017-171.ewe-ip-backbone.de)
04:19:32 × Topsi quits (~Tobias@dyndsl-091-249-083-202.ewe-ip-backbone.de) (Ping timeout: 255 seconds)
04:33:39 × pera quits (~pera@user/pera) (Ping timeout: 258 seconds)
04:33:55 × Guest5 quits (~Guest5@50.47.115.102) (Ping timeout: 246 seconds)
04:39:19 vonfry joins (~user@119.135.206.182)
04:39:31 × vonfry quits (~user@119.135.206.182) (Remote host closed the connection)
04:43:51 Guest5 joins (~Guest5@50.47.115.102)
04:45:06 × Null_A quits (~null_a@2601:645:8700:2290:1:e11e:d55b:188f) (Remote host closed the connection)
04:50:11 × eltonpinto quits (~1ntEgr8@2601:c8:c000:3090:20d2:58dd:3f51:cdf0) (Quit: WeeChat 3.1)
04:50:43 × Guest5 quits (~Guest5@50.47.115.102) (Ping timeout: 246 seconds)
04:53:51 slice joins (~slice@user/slice)
04:57:21 merijn joins (~merijn@83-160-49-249.ip.xs4all.nl)
05:03:58 wei2912 joins (~wei2912@112.199.250.21)
05:08:06 × slice quits (~slice@user/slice) (Quit: zzz)
05:13:12 falafel joins (~falafel@pool-96-255-70-50.washdc.fios.verizon.net)
05:13:59 × favonia quits (~favonia@user/favonia) (Ping timeout: 255 seconds)
05:14:48 favonia joins (~favonia@user/favonia)
05:20:05 × wroathe quits (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Ping timeout: 265 seconds)
05:22:52 eltonpinto joins (~eltonpint@169.109.136.34.bc.googleusercontent.com)
05:24:03 eltonpin1 joins (~1ntEgr8@2601:c8:c000:3090:20d2:58dd:3f51:cdf0)
05:24:23 × eltonpin1 quits (~1ntEgr8@2601:c8:c000:3090:20d2:58dd:3f51:cdf0) (Client Quit)
05:26:36 <Cajun> so one thing thats always peeved me with vectors is making recursive pattern matching functions with them. with lists its easy, but with a vector it feels dirty in a way; it needs -XViewPatterns and even then it feels like it adds an operation to make the benefits of vector (O(1) access) worthless. is there a better way of dealing with recursive
05:26:37 <Cajun> functions on vectors, or are we stuck with ViewPatterns?
05:27:29 fef joins (~thedawn@user/thedawn)
05:27:58 <Cajun> and to add on, how can this be done with Repa arrays?
05:28:20 <davean> whats the problem you have with ViewPatterns here?
05:28:47 × justsomeguy quits (~justsomeg@user/justsomeguy) (Quit: WeeChat 3.2)
05:28:51 <Cajun> just wondering if thats the only option or if there is a more "natural" (without extensions) way of pattern matching on them
05:30:11 <davean> I mean you can use guards if you want to avoid patterns, but I don't advocate that
05:30:45 <davean> ViewPatterns don't give you anything special
05:31:22 <davean> It all really depends on what your actual technical complaint is
05:31:31 <davean> For style questions, thats all up to you
05:31:41 × merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 265 seconds)
05:31:53 <davean> I might think you've got no taste because of the style you pick, but uh, I mean I can't say you're objectively wrong
05:32:45 <Cajun> im not sure if GHC would optimize it out, but its need for applying some function (like an uncons of some kind) every single time vs the default list's special syntax is what i was getting at, but its also a stylistic complain (to a way lesser degree)
05:33:07 <davean> I mean, think of waht that code actually means
05:33:17 <davean> But like, guards do create binds
05:33:43 <davean> You can look at the core, but yah, I mean it also depends on the type of Vector here for the exact details of what happens
05:33:52 <davean> clearly "head" of a boxed vector doesn't create anything
05:34:14 <davean> Things get iffier with one based on Storable instances
05:34:34 <davean> I know enough to debate you both ways on this, since your problem isn't realyl clear :)
05:34:55 <davean> The curse of knowlege is most things become more situational
05:34:56 <Cajun> i was just wondering if there was an easier way of doing it, the other more "real" question is how can this even be done on Repa arrays
05:35:12 <davean> I have no idea about Repa arrays, never used Repa seriously
05:35:23 <davean> tried it once or two years, years back
05:38:16 <Cajun> it seems overly clunky to attempt to pattern match on them, and im not even sure if thats the intended use of them or if they are strictly "bulk operations only" for stuff like image representation. im a complete beginner in terms of Repa
05:38:46 <davean> I know enough about Vector to talk about that, Repa, eh, uh
05:40:23 <davean> Cajun: why are you pattern matching down vectors anyway?
05:40:33 <davean> That seems unnatural
05:41:24 <davean> Oh right, there was a reason I don't use Repa
05:41:33 <Cajun> well thats what feels natural coming from the default List, is that just not the intended use case?
05:41:53 <davean> I mean you can pattern match down them if you have reason to
05:42:06 <davean> I just don't know many things that Vector is the optimal data structure for where I'd want to
05:42:22 <davean> I'd usually want a map or a fold in places where vector is appropriate
05:42:51 <davean> Its nothing hard and fact, I just don't think I've ever actualyl wanted to recurse down - cons and uncons occasionally, but not recurse specificly
05:43:02 <davean> I'm very much not saying you're wrong
05:43:37 <davean> I'm saying you're probably using vector in a way I haven't choosen to and I'd like to know what lead you there
05:44:34 <Cajun> well Vector just seems like the default List but with more emphasis on performance, so it would be nice to get the best of both worlds (easy recursive functions from default lists and performance from vectors)
05:44:53 <davean> But its not, it has fundimentally different characturistics
05:45:18 <davean> Like you can't edit the front of a vector, and reuse the tail in constant time
05:45:43 <davean> this is sorta the core of why I don't tend to use vector for things I recurse down - I'm usually either producing something from all the data, or I'm transforming all the data
05:45:57 <davean> also you get constant time length, which changes what you can do how
05:45:59 <Cajun> is this just not the intended use case for vectors?
05:46:03 <davean> but again, you can recurse down it all you want
05:46:25 <davean> I don't know - you keep not telling me what you're actually trying to do, so how can I answer?
05:46:40 <davean> You're litterly asking me about something you're not telling me about
05:47:17 <davean> I will say, taking the tail of a vector is constructive, unlike of a list where it isn't
05:47:46 <davean> constructive but O(1)
05:47:56 <Cajun> well its not about anything specific, its just that whenever i go to use them i hit a brick wall of weird pattern matching. also, what do you mean by "constructive"?
05:48:07 <davean> I mean it produces new data
05:48:24 × falafel quits (~falafel@pool-96-255-70-50.washdc.fios.verizon.net) (Ping timeout: 258 seconds)
05:48:30 <davean> as for pattern matching:
05:48:46 <davean> f v | h <- head v = something with the head h
05:49:14 <davean> with some vectors head isn't constructive (With some it is, varies by the vector type and optimizations)
05:49:41 falafel joins (~falafel@pool-96-255-70-50.washdc.fios.verizon.net)
05:49:55 <davean> I can't really say anything about list vs. vector though because they're so fundimentally different that they're just not alike
05:50:04 <davean> for some things one is right, for others the other
05:50:38 <Cajun> well can Vectors from Data.Vector be used for lazy lists? it doesnt mention strictness on the hackage page
05:50:51 <davean> no, of course not
05:51:16 <davean> though it can reference lazy values if you use the boxed ones
05:51:37 <davean> but vectors themselves could never be lazy, the elements in a boxed vector can be though
05:52:06 <Cajun> im assuming that even a boxed vector of lazy values still cant be infinite right?
05:52:18 <davean> No, vectors are specificly finite
05:52:33 <davean> They have to be, by construction
05:53:42 <davean> but theres a difference between a lazy list and a list of lazy values
05:54:32 × nate3 quits (~nate@108-233-125-227.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 258 seconds)
05:54:34 <davean> vector can only partially match to the second
05:55:03 <Cajun> what do you mean?
05:55:31 <davean> so first I want to be clear, theres at least 8 types of Vector
05:55:40 ubert joins (~Thunderbi@178.165.160.247.wireless.dyn.drei.com)
05:55:41 <davean> And they've all got different properties
05:56:13 <davean> but, the one closest in nature to list is the boxed vector
05:56:53 <davean> It doesn't say anything about strictness, because theres nothing about strictness for it to say
05:57:08 <davean> if you go over to Data.Vector.Unboxed though, thats a bit of a different story
05:57:21 <davean> Now for a lazy list vs a list of lazy values
05:57:32 × ubert quits (~Thunderbi@178.165.160.247.wireless.dyn.drei.com) (Client Quit)
05:57:46 <davean> theres two parts to a "list" in one way of looking at it, the "spine" which is the list constructors, and the "data" which is the 'a' in [a]
05:57:48 derelict joins (~derelict@user/derelict)
05:57:48 ubert joins (~Thunderbi@178.165.160.247.wireless.dyn.drei.com)
05:57:53 <davean> their laziness is seperate
05:57:57 <Cajun> lazy list is `_:_` for infinite values vs `_:_:_:_:_:_:_:_:_:....` for list of lazy values yeah?
05:59:25 <Cajun> well either way, thanks for clearing up my confusion about Vectors :)
05:59:31 × PinealGlandOptic quits (~PinealGla@37.115.210.35) (Quit: leaving)
05:59:31 <davean> I hope i helped?
05:59:42 <Cajun> yeah, i just didnt understand proper use case i guess lol
05:59:53 <Cajun> always imagined them as a replacement for lists
06:00:04 <davean> they're not, they can share some use cases but they're not lists
06:00:28 <davean> cons is O(1) on list, obviously
06:00:53 <davean> vectors are in a way far more "structured" than list
06:00:58 <davean> so you get a lot more structural operations
06:01:07 <davean> Thats REALLY not well defined mind you
06:01:22 <davean> but lists, for example, you can't tell up front how long they are
06:01:30 <davean> and they might not even have a definable length
06:01:38 <davean> their length is a semi-decision problem
06:01:55 <davean> vectors have an a-prior length by the nature of existing
06:02:08 × ubert quits (~Thunderbi@178.165.160.247.wireless.dyn.drei.com) (Ping timeout: 255 seconds)
06:02:10 <davean> so you can talk about the definition for every one of their values
06:02:27 takuan joins (~takuan@178-116-218-225.access.telenet.be)
06:02:37 <davean> etc
06:03:06 <davean> but yah, so about lists
06:03:27 <davean> [a] is ~ = Cons a RestOfList | EndOfList
06:03:40 <davean> both a and RestOfList's strictness is seperately defined
06:03:54 <davean> an infinite list of course must have RestOfList non-strict
06:04:10 <davean> but the 'a's might always be computed before the next Cons is constructed
06:04:28 <davean> OTOH, the RestOfLists might all be defined up front, but the 'a's left uncomputed
06:04:34 <davean> or both might be full computed, or neither
06:04:43 <davean> a vector, theres onyl one top level constructor
06:04:56 <davean> so by looking at it at all, the entire spine is done, theres only ever one piece of it
06:05:30 <davean> a vector, its self, is an atomic entity
06:06:18 <Cajun> so vector is just a chunk of data vs list being a bunch of "links" which may or may not be computed
06:06:26 × favonia quits (~favonia@user/favonia) (Ping timeout: 272 seconds)
06:06:37 <davean> yes
06:06:46 <davean> The data in a vector might not its self be computed
06:06:53 <Cajun> but its all there
06:06:57 <davean> but the vector, if you look at it, must be
06:07:08 <davean> the definitions are all linked to at least
06:07:27 <davean> in a block
06:07:47 <davean> you can't just "replace" the first element in a vector like you can in a list for example for that reason
06:08:23 favonia joins (~favonia@user/favonia)
06:08:35 <davean> (I say just, because with the correct conditions you can change it, with a mutable vector in the correct context for example, but now the old version no longer exists - where as with the list that isn't the case)
06:09:18 <davean> Theres a lot of places lists are miss-used instead of vectors, because lists are closer at hand, but they're fundimentally unrelated datastructures
06:09:51 <Cajun> ah that makes a lot of sense, i guess that makes pattern matching on them just a foolish idea, considering a new Vector must be made for each recurse, yeah?
06:09:53 <davean> with entirely different properties
06:10:15 <davean> well, ... sorta, I mean you can pattern match and pass down an index for example
06:10:25 <davean> go i v | h <- v ! i = ...
06:10:46 <davean> right? Like you can walk down it, and look at each value seperately, but why aren't you folding then?
06:11:03 <davean> go on the tail is of course go (i+1) v
06:11:08 anandprabhu joins (~anandprab@94.202.243.198)
06:11:24 <davean> But we've BASICLY just implimented a fold
06:11:28 <Cajun> well assuming the function constructs a new vector of some kind. im guessing im just using them wrong (as a list replacement)
06:11:53 <davean> well, depends on what new construction you're making
06:12:01 <davean> if the construction is of the same time, thats a map or a scan
06:12:31 <davean> if the construciton is of a known size, then thats a generate with the passed function capturing the origional list
06:12:41 <davean> if you don't know the length, you're not ready to create a vector yet!
06:13:05 <davean> and then you'd be using it wrong, or at least you'd have a LOT of book keeping to do to do a good job of using it well (fusion can take care of most of that automaticly for you)
06:14:19 × wei2912 quits (~wei2912@112.199.250.21) (Quit: Lost terminal)
06:14:51 <davean> Also, I am sorry to anyone watching for my abuse of guards here.
06:15:13 <davean> For the record I don't actually support that style, it just works and is concies and isn't Viewpatterns and I was making a point
06:15:30 <Cajun> yeah it helps to make your point more clear lol
06:15:34 wei2912 joins (~wei2912@112.199.250.21)
06:16:28 <davean> Cajun: I do expect you should stare at fold, map, scan a bit and consider if they're the actual structure you're implimenting
06:17:00 <davean> data Vector a = Vector {-# UNPACK #-} !Int {-# UNPACK #-} !Int {-# UNPACK #-} !(Array a)
06:17:10 <davean> BTW if you were interested in what Vector (at least the boxed variant) is
06:17:12 × Lord_of_Life quits (~Lord@user/lord-of-life/x-2819915) (Ping timeout: 272 seconds)
06:17:33 Lord_of_Life joins (~Lord@user/lord-of-life/x-2819915)
06:17:59 <davean> so whats tail? tail (Vector o s a) = Vector (o+1) (s-1) a
06:18:14 machinedgod joins (~machinedg@s72-38-105-27.static.comm.cgocable.net)
06:18:16 × lavaman quits (~lavaman@98.38.249.169) (Remote host closed the connection)
06:18:23 <davean> I mean with a bunch of bounds checks and stuff
06:18:34 × wei2912 quits (~wei2912@112.199.250.21) (Client Quit)
06:18:40 <davean> I'm of course leaving out al the important code :)
06:19:08 <Cajun> yeah at one point i realized what im essentially doing is reinventing map. though one time i hit the wall was when i was trying to make a function like `chunksOf` from Data.List.Split, and it doesnt seem like a map, fold, or scan would work well there
06:19:52 wei2912 joins (~wei2912@112.199.250.21)
06:20:22 <davean> sure, that'll work, you can do that as a fold for example just fine
06:20:29 <c_wraith> that's more of an unfold
06:20:56 <davean> I mean yah it is, but you can do it
06:21:07 <Cajun> well that would imply giving a single value like `Vector a -> a` no? when in reality that function would give `Vector a -> Vector (Vector a)`
06:21:11 <davean> I mean TECHNICALLY its a combination of a cata and an anna ...
06:21:15 <davean> But lets just not go there
06:21:25 <c_wraith> so it's a para. :P
06:21:25 <Cajun> yeah that went over my head lol
06:22:07 <davean> Yah I was trying to stickign to being helpful instead of being useful
06:24:27 <davean> The code with fold on vector is nicely performant but much less pretty than the list one
06:24:31 × slowButPresent quits (~slowButPr@user/slowbutpresent) (Quit: leaving)
06:24:41 <davean> or unfold
06:24:50 <davean> I think the unfold variant is cleaner frankly, but yah
06:25:12 × falafel quits (~falafel@pool-96-255-70-50.washdc.fios.verizon.net) (Ping timeout: 258 seconds)
06:28:14 burnsidesLlama joins (~burnsides@dhcp168-011.wadham.ox.ac.uk)
06:28:25 <davean> anyway, enough trying to be helpful for me :)
06:30:09 <Cajun> well you definitely helped me figuring out vectors :)
06:30:18 × favonia quits (~favonia@user/favonia) (Ping timeout: 240 seconds)
06:30:37 favonia joins (~favonia@user/favonia)
06:31:15 dyeplexer joins (~dyeplexer@user/dyeplexer)
06:33:22 dunkeln joins (~dunkeln@94.129.69.87)
06:35:49 <yorick> class First list x | list -> x -- what's this `|` syntax?
06:35:50 <c_wraith> I always feel unsatisfied when I write an unfold
06:36:00 <c_wraith> yorick: functional dependencies
06:36:04 <yorick> thanks
06:37:25 <c_wraith> yorick: that says that the type x is uniquely determined by the type list. That has two consequences. One, GHC can assume that if it knows list, it can figure out x. Two, GHC will report an error if you try to write conflicting instances.
06:37:53 <yorick> excellent, much more googleable :)
06:38:30 retroid_ joins (~retro@5ec19a54.skybroadband.com)
06:38:50 × favonia quits (~favonia@user/favonia) (Ping timeout: 250 seconds)
06:39:09 favonia joins (~favonia@user/favonia)
06:42:21 ubert joins (~Thunderbi@178.165.160.247.wireless.dyn.drei.com)
06:43:41 drd joins (~drd@93-39-151-19.ip76.fastwebnet.it)
06:45:06 × stefan-_ quits (~cri@42dots.de) (Ping timeout: 240 seconds)
06:45:31 × dunkeln quits (~dunkeln@94.129.69.87) (Ping timeout: 258 seconds)
06:46:54 jakalx parts (~jakalx@base.jakalx.net) ()
06:47:44 × derelict quits (~derelict@user/derelict) (Ping timeout: 252 seconds)
06:48:18 <c_wraith> basically, whenever I write an unfold, I wish I had a combinator like (\p f x -> f x <$ guard (p x)) conveniently named someplace already
06:49:03 lavaman joins (~lavaman@98.38.249.169)
06:49:54 stefan-_ joins (~cri@42dots.de)
06:51:32 × zmt01 quits (~zmt00@user/zmt00) (Ping timeout: 256 seconds)
06:52:32 × favonia quits (~favonia@user/favonia) (Ping timeout: 255 seconds)
06:52:57 favonia joins (~favonia@user/favonia)
06:53:28 slice joins (~slice@user/slice)
06:53:48 × lavaman quits (~lavaman@98.38.249.169) (Ping timeout: 256 seconds)
06:55:40 × burnsidesLlama quits (~burnsides@dhcp168-011.wadham.ox.ac.uk) (Remote host closed the connection)
06:56:35 pesada joins (~agua@2804:18:4e:32f1:1:0:51c9:e850)
06:59:50 × agua quits (~agua@2804:18:4d:af57:1:0:4dec:eb61) (Ping timeout: 252 seconds)
07:03:22 jakalx joins (~jakalx@base.jakalx.net)
07:05:02 mei4 joins (~mei@user/mei)
07:07:14 × favonia quits (~favonia@user/favonia) (Ping timeout: 272 seconds)
07:08:44 × mei quits (~mei@user/mei) (Ping timeout: 255 seconds)
07:08:44 mei4 is now known as mei
07:13:25 kspalaiologos joins (~kspalaiol@user/kspalaiologos)
07:18:42 favonia joins (~favonia@user/favonia)
07:19:30 × bitmapper quits (uid464869@id-464869.tooting.irccloud.com) (Quit: Connection closed for inactivity)
07:25:52 acidjnk joins (~acidjnk@p200300d0c72b958609191ed2d8f7abdf.dip0.t-ipconnect.de)
07:26:45 dunkeln joins (~dunkeln@94.129.69.87)
07:26:46 burnsidesLlama joins (~burnsides@dhcp168-011.wadham.ox.ac.uk)
07:27:58 merijn joins (~merijn@83-160-49-249.ip.xs4all.nl)
07:33:03 × xff0x_ quits (~xff0x@2001:1a81:5200:1d00:ce05:e9a7:78b7:c1fe) (Ping timeout: 276 seconds)
07:33:41 xff0x_ joins (~xff0x@port-92-195-69-103.dynamic.as20676.net)
07:41:54 × radw quits (~radw@user/radw) (Ping timeout: 252 seconds)
07:43:06 × merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 256 seconds)
07:47:05 fendor joins (~fendor@77.119.223.76.wireless.dyn.drei.com)
07:47:18 × codedmart quits (~codedmart@li335-49.members.linode.com) (Quit: ZNC 1.7.5+deb4 - https://znc.in)
07:47:33 codedmart joins (codedmart@2600:3c01::f03c:92ff:fefe:8511)
07:51:29 × tzh quits (~tzh@c-24-21-73-154.hsd1.or.comcast.net) (Quit: zzz)
07:54:16 × dunkeln quits (~dunkeln@94.129.69.87) (Ping timeout: 265 seconds)
07:57:13 dagit_ joins (~dagit@2601:1c2:1b7f:9fa0:54b1:3520:a1d6:48b1)
08:00:20 × dagit quits (~dagit@2601:1c2:1b7f:9fa0:445:559:1c8d:e5d1) (Ping timeout: 252 seconds)
08:01:43 burnside_ joins (~burnsides@dhcp168-011.wadham.ox.ac.uk)
08:01:43 × burnsidesLlama quits (~burnsides@dhcp168-011.wadham.ox.ac.uk) (Read error: Connection reset by peer)
08:04:06 burnsidesLlama joins (~burnsides@client-8-87.eduroam.oxuni.org.uk)
08:04:27 shredder joins (~user@user/shredder)
08:05:06 × anandprabhu quits (~anandprab@94.202.243.198) (Ping timeout: 240 seconds)
08:05:13 × slice quits (~slice@user/slice) (Quit: zzz)
08:05:19 Tuplanolla joins (~Tuplanoll@91-159-68-239.elisa-laajakaista.fi)
08:05:47 <Hecate> Cale: lol https://lambdacats.github.io/cale/
08:06:05 hendursa1 joins (~weechat@user/hendursaga)
08:06:42 × burnside_ quits (~burnsides@dhcp168-011.wadham.ox.ac.uk) (Ping timeout: 240 seconds)
08:08:50 × hendursaga quits (~weechat@user/hendursaga) (Ping timeout: 244 seconds)
08:12:35 × Kaiepi quits (~Kaiepi@nwcsnbsc03w-47-54-173-93.dhcp-dynamic.fibreop.nb.bellaliant.net) (Remote host closed the connection)
08:17:08 × MQ-17J quits (~MQ-17J@d14-69-206-129.try.wideopenwest.com) (Read error: Connection reset by peer)
08:17:21 MQ-17J joins (~MQ-17J@d14-69-206-129.try.wideopenwest.com)
08:17:22 × geekosaur quits (~geekosaur@xmonad/geekosaur) (Remote host closed the connection)
08:17:47 geekosaur joins (~geekosaur@xmonad/geekosaur)
08:20:20 Kaiepi joins (~Kaiepi@nwcsnbsc03w-47-54-173-93.dhcp-dynamic.fibreop.nb.bellaliant.net)
08:22:30 × Vajb quits (~Vajb@hag-jnsbng11-58c3a1-224.dhcp.inet.fi) (Read error: Connection reset by peer)
08:23:13 Vajb joins (~Vajb@2001:999:62:1d53:26b1:6c9b:c1ed:9c01)
08:26:20 × Kaiepi quits (~Kaiepi@nwcsnbsc03w-47-54-173-93.dhcp-dynamic.fibreop.nb.bellaliant.net) (Ping timeout: 258 seconds)
08:31:36 pera joins (~pera@user/pera)
08:33:44 × hnOsmium0001 quits (uid453710@id-453710.stonehaven.irccloud.com) (Quit: Connection closed for inactivity)
08:34:41 × eggplantade quits (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Remote host closed the connection)
08:37:21 <jco> Anyone know of some library to nicely render HTML in a text console?
08:37:50 × favonia quits (~favonia@user/favonia) (Ping timeout: 255 seconds)
08:37:50 × pera quits (~pera@user/pera) (Ping timeout: 268 seconds)
08:38:00 pera joins (~pera@user/pera)
08:39:28 Kaiepi joins (~Kaiepi@nwcsnbsc03w-47-54-173-93.dhcp-dynamic.fibreop.nb.bellaliant.net)
08:39:40 favonia joins (~favonia@user/favonia)
08:42:51 mnrmnaugh is now known as ID-10-T
08:43:04 ID-10-T is now known as mnrmnaugh
08:43:50 mikoto-chan joins (~mikoto-ch@ip-193-121-10-50.dsl.scarlet.be)
08:43:54 mnrmnaugh is now known as BMCC
08:45:11 BMCC is now known as mnrmnaugh
08:45:52 zeenk joins (~zeenk@2a02:2f04:a008:d600:18f2:3421:bac6:8f38)
08:46:52 × Sgeo quits (~Sgeo@user/sgeo) (Read error: Connection reset by peer)
08:46:53 × Vajb quits (~Vajb@2001:999:62:1d53:26b1:6c9b:c1ed:9c01) (Read error: Connection reset by peer)
08:48:09 Vajb joins (~Vajb@hag-jnsbng11-58c3a1-224.dhcp.inet.fi)
08:48:53 × img quits (~img@user/img) (Quit: ZNC 1.8.2 - https://znc.in)
08:49:54 × dagit_ quits (~dagit@2601:1c2:1b7f:9fa0:54b1:3520:a1d6:48b1) (Ping timeout: 240 seconds)
08:50:14 img joins (~img@user/img)
08:53:14 × pera quits (~pera@user/pera) (Ping timeout: 265 seconds)
08:56:18 radw joins (~radw@user/radw)
08:57:22 × ubert quits (~Thunderbi@178.165.160.247.wireless.dyn.drei.com) (Ping timeout: 240 seconds)
08:59:31 × favonia quits (~favonia@user/favonia) (Ping timeout: 265 seconds)
09:05:13 × burnsidesLlama quits (~burnsides@client-8-87.eduroam.oxuni.org.uk) (Remote host closed the connection)
09:07:06 yoctocell joins (~user@h87-96-130-155.cust.a3fiber.se)
09:07:23 dunkeln joins (~dunkeln@94.129.69.87)
09:08:02 slice joins (~slice@user/slice)
09:08:35 lavaman joins (~lavaman@98.38.249.169)
09:08:38 jgeerds joins (~jgeerds@55d45555.access.ecotel.net)
09:10:32 <Arahael> jco: For such an open-ended question, I'd probably just look in to links, w3m, or lynx.
09:11:54 × jespada quits (~jespada@90.254.247.46) (Ping timeout: 240 seconds)
09:12:58 × lavaman quits (~lavaman@98.38.249.169) (Ping timeout: 240 seconds)
09:13:10 <Hecate> yep
09:13:14 jespada joins (~jespada@90.254.247.46)
09:14:01 <juri_> we could use a haskell web browser.. if anyone has a giant team of haskellers with nothing to do.
09:16:41 × machinedgod quits (~machinedg@s72-38-105-27.static.comm.cgocable.net) (Quit: leaving)
09:17:13 <Hecate> hahaha
09:20:02 _ht joins (~quassel@82-169-194-8.biz.kpn.net)
09:26:24 <nitrix> They're still working on the ivory tower.
09:26:38 <nitrix> Next AI winter maybe.
09:28:53 dextaa7 is now known as dextaa
09:31:25 dhil joins (~dhil@195.213.192.47)
09:38:10 × econo quits (uid147250@user/econo) (Quit: Connection closed for inactivity)
09:38:18 anandprabhu joins (~anandprab@94.202.243.198)
09:39:11 merijn joins (~merijn@83-160-49-249.ip.xs4all.nl)
09:46:29 × jgeerds quits (~jgeerds@55d45555.access.ecotel.net) (Ping timeout: 252 seconds)
09:48:20 amahl joins (~amahl@dsl-jklbng12-54fbca-64.dhcp.inet.fi)
09:51:22 agua joins (~agua@2804:14c:8793:8e2f:8013:a595:bc17:299d)
09:53:48 × pesada quits (~agua@2804:18:4e:32f1:1:0:51c9:e850) (Ping timeout: 272 seconds)
10:04:27 ubert joins (~Thunderbi@91.141.47.26.wireless.dyn.drei.com)
10:06:34 × jonathanx quits (~jonathan@h-178-174-176-109.A357.priv.bahnhof.se) (Ping timeout: 240 seconds)
10:07:03 jonathanx joins (~jonathan@h-178-174-176-109.A357.priv.bahnhof.se)
10:13:17 × merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 258 seconds)
10:16:13 × xsperry quits (~as@user/xsperry) (Remote host closed the connection)
10:16:52 × kspalaiologos quits (~kspalaiol@user/kspalaiologos) (Quit: Leaving)
10:17:59 burnsidesLlama joins (~burnsides@client-8-87.eduroam.oxuni.org.uk)
10:19:43 × zaquest quits (~notzaques@5.128.210.178) (Quit: Leaving)
10:21:24 kenran joins (~kenran@200116b82bb5e400f1c7c01f9f0a47a0.dip.versatel-1u1.de)
10:22:14 pesada joins (~agua@2804:18:48:10d4:1:0:5286:477d)
10:25:19 × anandprabhu quits (~anandprab@94.202.243.198) (Quit: Konversation terminated!)
10:25:45 × agua quits (~agua@2804:14c:8793:8e2f:8013:a595:bc17:299d) (Ping timeout: 268 seconds)
10:35:12 eggplantade joins (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net)
10:36:18 × darxun quits (sid504814@id-504814.tinside.irccloud.com) (Ping timeout: 240 seconds)
10:36:58 × whiteline quits (~whiteline@c-cda8d954.54725-0-757473696b74.bbcust.telenor.se) (Ping timeout: 240 seconds)
10:37:33 darxun joins (sid504814@id-504814.tinside.irccloud.com)
10:37:39 Deide joins (~Deide@217.155.19.23)
10:37:39 × Deide quits (~Deide@217.155.19.23) (Changing host)
10:37:39 Deide joins (~Deide@user/deide)
10:39:22 × eggplantade quits (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 240 seconds)
10:43:52 whiteline joins (~whiteline@c-cda8d954.54725-0-757473696b74.bbcust.telenor.se)
10:43:52 × azeem quits (~azeem@dynamic-adsl-84-220-213-65.clienti.tiscali.it) (Read error: Connection reset by peer)
10:44:57 merijn joins (~merijn@83-160-49-249.ip.xs4all.nl)
10:45:06 azeem joins (~azeem@dynamic-adsl-84-220-213-65.clienti.tiscali.it)
10:46:39 andreabedini joins (~andreabed@ec2-3-25-98-120.ap-southeast-2.compute.amazonaws.com)
10:49:46 × merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 240 seconds)
10:51:05 pavonia_ joins (~user@user/siracusa)
10:51:17 × whiteline quits (~whiteline@c-cda8d954.54725-0-757473696b74.bbcust.telenor.se) (Read error: Connection reset by peer)
10:54:38 × pavonia quits (~user@user/siracusa) (Ping timeout: 255 seconds)
10:54:45 pavonia_ is now known as pavonia
10:58:53 × vicfred quits (~vicfred@user/vicfred) (Quit: Leaving)
11:00:53 pavonia_ joins (~user@user/siracusa)
11:01:14 × pavonia quits (~user@user/siracusa) (Read error: Connection reset by peer)
11:01:27 pavonia_ is now known as pavonia
11:01:57 × slice quits (~slice@user/slice) (Quit: zzz)
11:05:23 ahdyt joins (~ahdyt@180.246.61.107)
11:06:38 <ahdyt> map solve problems
11:07:38 AlexNoo_ joins (~AlexNoo@178.34.150.234)
11:08:06 eggplantade joins (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net)
11:10:18 × AlexZenon quits (~alzenon@178.34.162.117) (Ping timeout: 240 seconds)
11:10:18 × Alex_test quits (~al_test@178.34.162.117) (Ping timeout: 240 seconds)
11:11:10 × AlexNoo quits (~AlexNoo@178.34.162.117) (Ping timeout: 258 seconds)
11:12:16 × eggplantade quits (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 250 seconds)
11:15:32 Alex_test joins (~al_test@178.34.150.234)
11:15:44 AlexZenon joins (~alzenon@178.34.150.234)
11:17:07 anandprabhu joins (~anandprab@94.202.243.198)
11:28:25 eggplantade joins (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net)
11:29:26 agua joins (~agua@191.177.175.57)
11:32:42 × eggplantade quits (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 240 seconds)
11:33:11 × pesada quits (~agua@2804:18:48:10d4:1:0:5286:477d) (Ping timeout: 252 seconds)
11:38:18 eggplantade joins (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net)
11:39:01 × dunkeln quits (~dunkeln@94.129.69.87) (Ping timeout: 265 seconds)
11:41:37 × ahdyt quits (~ahdyt@180.246.61.107) (Quit: Client closed)
11:41:43 dunkeln joins (~dunkeln@94.129.69.87)
11:42:32 × eggplantade quits (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 252 seconds)
11:43:51 hacker1234 joins (~weijiafu@2409:8a74:c90:3400:2193:78b:c8a3:31b7)
11:44:44 <hacker1234> he
11:47:50 hacker1234 parts (~weijiafu@2409:8a74:c90:3400:2193:78b:c8a3:31b7) ()
11:48:35 hacker1234 joins (~weijiafu@2409:8a74:c90:3400:2193:78b:c8a3:31b7)
11:57:38 hacker1234 parts (~weijiafu@2409:8a74:c90:3400:2193:78b:c8a3:31b7) ()
11:58:25 eggplantade joins (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net)
12:03:11 × eggplantade quits (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 265 seconds)
12:04:20 jakalx parts (~jakalx@base.jakalx.net) ()
12:10:26 × zeenk quits (~zeenk@2a02:2f04:a008:d600:18f2:3421:bac6:8f38) (Quit: Konversation terminated!)
12:12:02 LukeHoersten joins (~LukeHoers@user/lukehoersten)
12:15:45 × dunkeln quits (~dunkeln@94.129.69.87) (Ping timeout: 265 seconds)
12:18:38 eggplantade joins (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net)
12:18:46 jakalx joins (~jakalx@base.jakalx.net)
12:21:32 Atum_ joins (~IRC@user/atum/x-2392232)
12:22:42 × eggplantade quits (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 240 seconds)
12:32:33 × LukeHoersten quits (~LukeHoers@user/lukehoersten) (Quit: My MacBook has gone to sleep. ZZZzzz…)
12:35:02 favonia joins (~favonia@user/favonia)
12:39:14 curiousgay joins (~curiousga@77-120-186-48.kha.volia.net)
12:41:00 xsperry joins (~as@user/xsperry)
12:42:40 AlexNoo_ is now known as AlexNoo
12:45:11 eggplantade joins (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net)
12:45:52 merijn joins (~merijn@83-160-49-249.ip.xs4all.nl)
12:49:33 LukeHoersten joins (~LukeHoers@user/lukehoersten)
12:49:40 × eggplantade quits (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 256 seconds)
12:53:06 Gurkenglas joins (~Gurkengla@dslb-002-203-144-156.002.203.pools.vodafone-ip.de)
12:54:14 × burnsidesLlama quits (~burnsides@client-8-87.eduroam.oxuni.org.uk) (Remote host closed the connection)
12:55:40 hacker1234 joins (~weijiafu@2409:8a74:c90:3400:2193:78b:c8a3:31b7)
12:56:15 hacker1234 parts (~weijiafu@2409:8a74:c90:3400:2193:78b:c8a3:31b7) ()
13:00:56 alx741 joins (~alx741@186.178.108.59)
13:05:01 × mjs2600 quits (~mjs2600@c-24-91-3-49.hsd1.vt.comcast.net) (Ping timeout: 258 seconds)
13:07:01 × Atum_ quits (~IRC@user/atum/x-2392232) (Quit: Atum_)
13:10:46 × curiousgay quits (~curiousga@77-120-186-48.kha.volia.net) (Ping timeout: 258 seconds)
13:11:56 mjs2600 joins (~mjs2600@c-24-91-3-49.hsd1.vt.comcast.net)
13:16:32 <arkanoid> is it more idiomatic to do not pollute the module by defining function in "where" block of other functions, or there's a better way?
13:16:32 __monty__ joins (~toonn@user/toonn)
13:17:49 <Hecate> arkanoid: the module is not polluted as long as you only export what needs to be exported
13:18:55 <arkanoid> Hecate: right, but is it still considereg good practice to control function visibility within a single module by embedding functions into where blocks?
13:19:53 × merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 252 seconds)
13:20:37 <Logio> you can't test a non-visible function, so I'd say that's bad practice more than anything
13:21:40 tlaxkit joins (~hexchat@170.253.39.204)
13:22:39 Atum_ joins (~IRC@user/atum/x-2392232)
13:24:28 <Logio> unless your function definition depends on the local scope there's hardly any benefits to it, and even then I usually find myself refactoring code to do the opposite, for the aforementioned reason
13:24:36 <[exa]> arkanoid: if the function doesn't benefit from sharing the parameter context with the bigger function, I'd just leave it at top level. If it looks polluted, add comments.
13:26:15 <Hecate> arkanoid: what [exa] and Logio said ^
13:26:44 <Hecate> don't think too much about this, most of your library's consumers will take what you give them, and your code will largely stay unread
13:26:46 <arkanoid> it makes sense, an embedded function cannot be tested separately. Thanks!
13:26:48 <[exa]> there might not even be any extra considerations, except perhaps from possible memoization vs. monomorphism
13:28:14 <[exa]> well yea, if you can make it parameterless and reuse the result manu times, it might be much better in the where block. :]
13:33:17 <arkanoid> I've another noob question, if you don't mind. When writing functions I tend to start by using static types and make it work, and then after all the test passes I feel guilty not having used polymorphism and typeclasses. Is it considered "wrong" non using "a -> b" but "Int -> Float"?
13:33:35 <[exa]> not at all
13:33:46 <[exa]> that's why we have the typesystems right
13:34:09 <[exa]> you can always ask the compiler for the most general type using the hole, as `myfunc :: _`
13:34:32 <Hecate> arkanoid: it is not, and you will gain in runtime perf with monomorphic functions
13:34:58 <[exa]> (generally, "prototype then polish" is wildly underestimated rule for good programming)
13:36:12 <arkanoid> good :) thanks. [exa] what do you mean by "ask the compiler for the most general type using the hole"?
13:36:29 curiousgay joins (~curiousga@77-120-186-48.kha.volia.net)
13:36:39 tremon joins (~tremon@217-63-61-89.cable.dynamic.v4.ziggo.nl)
13:37:25 burnsidesLlama joins (~burnsides@client-8-87.eduroam.oxuni.org.uk)
13:38:55 <Hecate> arkanoid: if you literally write a type signature "foo :: _", GHC will try to fill the hole (the underscore) with what it thinks is the best type
13:39:41 <[exa]> let's try
13:39:57 <[exa]> % "asd" + [_]
13:40:03 <yahb> [exa]: [Timed out]
13:40:12 <[exa]> oh noes
13:40:59 <[exa]> (I forgot a +, let's retry with lambdabot)
13:41:04 <[exa]> > "asd" ++ [ _ ]
13:41:08 <lambdabot> error:
13:41:08 <lambdabot> • Found hole: _ :: Char
13:41:08 <lambdabot> • In the expression: _
13:41:39 <[exa]> arkanoid: it tells you what type fits there ^. if you put _ instead of the whole function type signature, you'll get a type derived for free.
13:42:16 × burnsidesLlama quits (~burnsides@client-8-87.eduroam.oxuni.org.uk) (Ping timeout: 265 seconds)
13:42:53 <arkanoid> very interesting. Is it something that's used by programmers?
13:43:10 <arkanoid> I mean, whenever you get lost on the type of something, just compile with _ and read the result?
13:43:39 <[exa]> I do that all the time
13:44:08 <arkanoid> :D
13:44:32 <[exa]> like, people invested unbelievable amount of time to make the error messages good, so why not utilize that?
13:44:34 × jneira_ quits (~jneira_@28.red-80-28-169.staticip.rima-tde.net) (Ping timeout: 240 seconds)
13:45:03 peterhil joins (~peterhil@mobile-access-5d6af6-209.dhcp.inet.fi)
13:45:09 merijn joins (~merijn@83-160-49-249.ip.xs4all.nl)
13:45:31 <arkanoid> I wonder how many cool tricks are there that I'm missing
13:45:45 × wei2912 quits (~wei2912@112.199.250.21) (Quit: Lost terminal)
13:46:39 <[exa]> arkanoid: this is priceless: http://dev.stephendiehl.com/hask/tutorial.pdf
13:46:51 <arkanoid> :D
13:48:20 × mjs2600 quits (~mjs2600@c-24-91-3-49.hsd1.vt.comcast.net) (Ping timeout: 255 seconds)
13:48:26 × hendursa1 quits (~weechat@user/hendursaga) (Quit: hendursa1)
13:48:54 hendursaga joins (~weechat@user/hendursaga)
13:49:01 × oso quits (~oso@2601:58c:c080:a950:f275:2530:b398:680b) (Ping timeout: 246 seconds)
13:50:30 jumper149 joins (~jumper149@80.240.31.34)
13:53:29 gehmehgeh joins (~user@user/gehmehgeh)
13:58:14 lbseale joins (~lbseale@user/ep1ctetus)
14:02:44 × MQ-17J quits (~MQ-17J@d14-69-206-129.try.wideopenwest.com) (Read error: Connection reset by peer)
14:03:14 × ubert quits (~Thunderbi@91.141.47.26.wireless.dyn.drei.com) (Quit: ubert)
14:03:27 MQ-17J joins (~MQ-17J@d14-69-206-129.try.wideopenwest.com)
14:03:32 ubert joins (~Thunderbi@91.141.47.26.wireless.dyn.drei.com)
14:03:53 <arkanoid> I'm confused by type IO [Integer] and ([Integer], World)
14:04:06 × ubert quits (~Thunderbi@91.141.47.26.wireless.dyn.drei.com) (Client Quit)
14:04:22 ubert joins (~Thunderbi@91.141.47.26.wireless.dyn.drei.com)
14:07:27 × geekosaur quits (~geekosaur@xmonad/geekosaur) (Remote host closed the connection)
14:07:50 × jmorris quits (uid433911@id-433911.stonehaven.irccloud.com) (Quit: Connection closed for inactivity)
14:08:22 ph88 joins (~ph88@2a02:8109:9e00:7e5c:8db8:987d:36eb:f1a6)
14:10:19 geekosaur joins (~geekosaur@xmonad/geekosaur)
14:10:44 × LukeHoersten quits (~LukeHoers@user/lukehoersten) (Quit: My MacBook has gone to sleep. ZZZzzz…)
14:13:27 × ph88 quits (~ph88@2a02:8109:9e00:7e5c:8db8:987d:36eb:f1a6) (Ping timeout: 276 seconds)
14:13:57 <arkanoid> if feels just like syntax sugar
14:14:36 <geekosaur> it is, sort of; it ensures you have a data dependency in the invocation and therefore things happen in the right order
14:15:20 × ubert quits (~Thunderbi@91.141.47.26.wireless.dyn.drei.com) (Ping timeout: 255 seconds)
14:15:21 <geekosaur> you could do it manually (although the actual type is a little more complicated)
14:16:44 <geekosaur> but it has nothing to do with IO other than ensuring that ordering
14:16:58 flounders joins (~flounders@173.246.200.33)
14:19:01 LukeHoersten joins (~LukeHoers@user/lukehoersten)
14:20:43 hacker1234 joins (~weijiafu@2409:8a74:c90:3400:2193:78b:c8a3:31b7)
14:20:59 hacker1234 parts (~weijiafu@2409:8a74:c90:3400:2193:78b:c8a3:31b7) ()
14:21:00 hacker1234 joins (~weijiafu@2409:8a74:c90:3400:2193:78b:c8a3:31b7)
14:21:14 <hacker1234> hacker hacker
14:21:49 <hacker1234> :-D
14:23:29 hacker1234 parts (~weijiafu@2409:8a74:c90:3400:2193:78b:c8a3:31b7) ()
14:24:59 × Vajb quits (~Vajb@hag-jnsbng11-58c3a1-224.dhcp.inet.fi) (Read error: Connection reset by peer)
14:25:29 hacker1234 joins (~weijiafu@2409:8a74:c90:3400:2193:78b:c8a3:31b7)
14:25:33 hacker1234 parts (~weijiafu@2409:8a74:c90:3400:2193:78b:c8a3:31b7) ()
14:26:11 zebrag joins (~chris@user/zebrag)
14:26:12 <arkanoid> geekosaur: if I got it right it is just to ensure that the "world changes" on every IO operation, but this get's properly hidden with bind/do, correct?
14:27:25 <geekosaur> there is no world :) its size is zero. but otherwise yes
14:28:21 <arkanoid> ?_?
14:29:03 <geekosaur> as I said, its whole point is to make sure things happen in the right order, by forcing a data dependency
14:29:13 <geekosaur> after it's done that, it goes away
14:30:30 × shredder quits (~user@user/shredder) (Quit: quitting)
14:30:43 <geekosaur> \(goes away in the sense that the compiler doesn't see it any more, since its representation has size zero it vanishes after the typechecker)
14:31:19 shredder joins (~user@user/shredder)
14:31:31 <geekosaur> I is special because it is IO, not because of RealWorld#
14:31:41 <geekosaur> *IO
14:31:49 <yushyin> a bit like a baton that is passed along
14:32:34 <[exa]> (wasn't that called a token? :D)
14:33:01 <arkanoid> olympic times, it's a baton now
14:33:06 <arkanoid> thanks! I got it
14:33:41 <yushyin> right! :D
14:33:59 <arkanoid> well, I don't get the "since its representation has size zero" thing, but not sure if I should dive into this now
14:34:11 <geekosaur> that's an internal compiler thing
14:34:27 <geekosaur> nut it points up that in reality there's no "world" to be "updated"
14:34:38 <geekosaur> there's just the baton
14:37:17 × nf quits (~n@monade.li) (Quit: Fairfarren.)
14:37:51 × anandprabhu quits (~anandprab@94.202.243.198) (Quit: Leaving)
14:38:15 <arkanoid> I start to see the Matrix
14:40:40 turlando joins (~turlando@93-42-250-112.ip89.fastwebnet.it)
14:40:41 × turlando quits (~turlando@93-42-250-112.ip89.fastwebnet.it) (Changing host)
14:40:41 turlando joins (~turlando@user/turlando)
14:40:44 × acidjnk quits (~acidjnk@p200300d0c72b958609191ed2d8f7abdf.dip0.t-ipconnect.de) (Ping timeout: 256 seconds)
14:41:54 hexfive joins (~eric@50.35.83.177)
14:43:32 nf joins (~n@monade.li)
14:43:54 chomwitt joins (~chomwitt@2a02:587:dc0e:ef00:12c3:7bff:fe6d:d374)
14:44:58 × curiousgay quits (~curiousga@77-120-186-48.kha.volia.net) (Ping timeout: 240 seconds)
14:49:08 <arkanoid> not sure when I should prefer the "do" and when I should prefer the ">>=/>>" thing
14:51:20 slowButPresent joins (~slowButPr@user/slowbutpresent)
14:52:21 Vajb joins (~Vajb@hag-jnsbng11-58c3a1-224.dhcp.inet.fi)
14:58:53 × merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 252 seconds)
15:02:26 derelict joins (~derelict@user/derelict)
15:03:22 jao joins (~jao@cpc103048-sgyl39-2-0-cust502.18-2.cable.virginm.net)
15:03:43 × adanwan quits (~adanwan@gateway/tor-sasl/adanwan) (Ping timeout: 244 seconds)
15:03:45 adanwan_ joins (~adanwan@gateway/tor-sasl/adanwan)
15:05:19 curiousgay joins (~curiousga@77-120-186-48.kha.volia.net)
15:05:21 <geekosaur> I generally use >>= when it's short
15:05:36 <geekosaur> do notation just looks better for long stuff
15:08:51 <arkanoid> k, thanks
15:09:38 × drd quits (~drd@93-39-151-19.ip76.fastwebnet.it) (Ping timeout: 256 seconds)
15:09:59 × Maxdamantus quits (~Maxdamant@user/maxdamantus) (Ping timeout: 258 seconds)
15:11:14 × _xor quits (~xor@74.215.232.67) (Quit: WeeChat 3.2)
15:13:36 × Vajb quits (~Vajb@hag-jnsbng11-58c3a1-224.dhcp.inet.fi) (Read error: Connection reset by peer)
15:14:11 drd joins (~drd@93-39-151-19.ip76.fastwebnet.it)
15:14:50 × curiousgay quits (~curiousga@77-120-186-48.kha.volia.net) (Ping timeout: 252 seconds)
15:17:27 lavaman joins (~lavaman@98.38.249.169)
15:24:11 Vajb joins (~Vajb@hag-jnsbng11-58c3a1-224.dhcp.inet.fi)
15:25:34 ph88 joins (~ph88@2a02:8109:9e00:7e5c:8db8:987d:36eb:f1a6)
15:27:28 wroathe joins (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
15:30:09 × ph88 quits (~ph88@2a02:8109:9e00:7e5c:8db8:987d:36eb:f1a6) (Ping timeout: 276 seconds)
15:33:17 × Vajb quits (~Vajb@hag-jnsbng11-58c3a1-224.dhcp.inet.fi) (Read error: Connection reset by peer)
15:33:42 × lavaman quits (~lavaman@98.38.249.169) (Remote host closed the connection)
15:33:57 lavaman joins (~lavaman@98.38.249.169)
15:34:03 × lavaman quits (~lavaman@98.38.249.169) (Remote host closed the connection)
15:34:05 × tlaxkit quits (~hexchat@170.253.39.204) (Ping timeout: 268 seconds)
15:34:40 curiousgay joins (~curiousga@77-120-186-48.kha.volia.net)
15:35:34 Null_A joins (~null_a@2601:645:8700:2290:707f:6ddd:516:dcea)
15:37:59 Vajb joins (~Vajb@hag-jnsbng11-58c3a1-224.dhcp.inet.fi)
15:38:58 Sgeo joins (~Sgeo@user/sgeo)
15:39:45 × Vajb quits (~Vajb@hag-jnsbng11-58c3a1-224.dhcp.inet.fi) (Read error: Connection reset by peer)
15:40:16 × slycelote quits (~slycelote@user/slycelote) (Quit: Leaving)
15:40:51 LukeHoersten is now known as nth
15:45:24 mr-red joins (~drd@2001:b07:a70:9f1f:1562:34de:f50f:77d4)
15:45:57 Maxdamantus joins (~Maxdamant@user/maxdamantus)
15:46:47 × drd quits (~drd@93-39-151-19.ip76.fastwebnet.it) (Ping timeout: 245 seconds)
15:46:59 eggplantade joins (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net)
15:47:45 Vajb joins (~Vajb@hag-jnsbng11-58c3a1-224.dhcp.inet.fi)
15:48:35 pera joins (~pera@user/pera)
15:48:35 raehik1 joins (~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net)
15:51:34 × eggplantade quits (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 256 seconds)
15:51:56 _xor joins (~xor@74.215.232.67)
15:59:28 <monochrom> Ah, missed the RealWorld# discussion.
16:00:13 <monochrom> People need to look at the asm code and see that RealWorld# is compiled to nothing. It's a phantom type.
16:02:10 drd joins (~drd@93-39-151-19.ip76.fastwebnet.it)
16:02:56 × Vajb quits (~Vajb@hag-jnsbng11-58c3a1-224.dhcp.inet.fi) (Read error: Connection reset by peer)
16:02:59 tlaxkit joins (~hexchat@170.253.39.204)
16:03:38 <geekosaur> I mentioned that
16:03:46 Vajb joins (~Vajb@hag-jnsbng11-58c3a1-224.dhcp.inet.fi)
16:03:47 <monochrom> It's present in IR to prevent the optimizer from re-ordering supposed sequential IO code. That's it. It's just to fool the optimizer.
16:04:18 × mr-red quits (~drd@2001:b07:a70:9f1f:1562:34de:f50f:77d4) (Ping timeout: 240 seconds)
16:04:48 <maerwald> can't the optimizer be type-aware?
16:04:49 lavaman joins (~lavaman@98.38.249.169)
16:04:56 <maerwald> I've no idea about the pipeline :)
16:05:06 econo joins (uid147250@user/econo)
16:05:35 × drd quits (~drd@93-39-151-19.ip76.fastwebnet.it) (Client Quit)
16:05:39 × Vajb quits (~Vajb@hag-jnsbng11-58c3a1-224.dhcp.inet.fi) (Read error: Connection reset by peer)
16:06:22 drd joins (~drd@2001:b07:a70:9f1f:1562:34de:f50f:77d4)
16:07:21 × zebrag quits (~chris@user/zebrag) (Remote host closed the connection)
16:09:41 × lavaman quits (~lavaman@98.38.249.169) (Ping timeout: 265 seconds)
16:10:03 zaquest joins (~notzaques@5.128.210.178)
16:10:13 mc47 joins (~mc47@xmonad/TheMC47)
16:11:05 × drd quits (~drd@2001:b07:a70:9f1f:1562:34de:f50f:77d4) (Ping timeout: 268 seconds)
16:11:34 zmt01 joins (~zmt00@user/zmt00)
16:11:44 drd joins (~drd@2001:b07:a70:9f1f:1562:34de:f50f:77d4)
16:13:15 slycelote joins (~slycelote@user/slycelote)
16:13:56 zebrag joins (~chris@user/zebrag)
16:14:37 × drd quits (~drd@2001:b07:a70:9f1f:1562:34de:f50f:77d4) (Read error: Connection reset by peer)
16:16:30 × zebrag quits (~chris@user/zebrag) (Remote host closed the connection)
16:17:20 × dajoer quits (~david@user/gvx) (Quit: leaving)
16:18:55 Vajb joins (~Vajb@hag-jnsbng11-58c3a1-224.dhcp.inet.fi)
16:19:07 eggplantade joins (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net)
16:20:19 drd joins (~drd@93-39-151-19.ip76.fastwebnet.it)
16:20:55 <monochrom> Type-aware optimizer may end up being two optimizers that are similar-yet-different enough that you have to write twice.
16:21:27 × drd quits (~drd@93-39-151-19.ip76.fastwebnet.it) (Read error: Connection reset by peer)
16:21:45 drd joins (~drd@93-39-151-19.ip76.fastwebnet.it)
16:21:55 <monochrom> There is something nice about "the optimizer for pure code works for IO code too if it sees a fictional data dependency".
16:21:58 dunkeln joins (~dunkeln@94.129.69.87)
16:22:12 <monochrom> or code generator
16:22:41 × drd quits (~drd@93-39-151-19.ip76.fastwebnet.it) (Client Quit)
16:24:46 drd joins (~drd@2001:b07:a70:9f1f:1562:34de:f50f:77d4)
16:32:04 × lambdap quits (~lambdap@static.167.190.119.168.clients.your-server.de) (Quit: lambdap)
16:32:22 lambdap joins (~lambdap@static.167.190.119.168.clients.your-server.de)
16:33:48 × curiousgay quits (~curiousga@77-120-186-48.kha.volia.net) (Ping timeout: 250 seconds)
16:34:39 <arkanoid> [x**2 | x <- [1,2,3,4,5]] returns floats. I see that ** accepts Fractional typeclass. Is there a pow operator for Integers?
16:34:59 <monochrom> ^
16:35:12 <arkanoid> thanks!
16:37:22 × gehmehgeh quits (~user@user/gehmehgeh) (Quit: Leaving)
16:39:46 × dunkeln quits (~dunkeln@94.129.69.87) (Ping timeout: 272 seconds)
16:40:59 × jespada quits (~jespada@90.254.247.46) (Quit: My MacBook has gone to sleep. ZZZzzz…)
16:41:14 curiousgay joins (~curiousga@77-120-186-48.kha.volia.net)
16:46:20 × nth quits (~LukeHoers@user/lukehoersten) (Quit: My MacBook has gone to sleep. ZZZzzz…)
16:46:26 tzh joins (~tzh@c-24-21-73-154.hsd1.wa.comcast.net)
16:47:36 × drd quits (~drd@2001:b07:a70:9f1f:1562:34de:f50f:77d4) (Quit: ZNC 1.8.2 - https://znc.in)
16:48:23 drd joins (~drd@2001:b07:a70:9f1f:1562:34de:f50f:77d4)
16:49:22 × drd quits (~drd@2001:b07:a70:9f1f:1562:34de:f50f:77d4) (Read error: Connection reset by peer)
16:49:34 burnsidesLlama joins (~burnsides@client-8-87.eduroam.oxuni.org.uk)
16:49:58 drd joins (~drd@93-39-151-19.ip76.fastwebnet.it)
16:54:37 <arkanoid> How to deal with overflow errors when using Int? "let foo :: Int -> Int; foo x = x^1000", "foo 7" returns -5479429532463080511 . I'm learning haskell to do scientific calculations, and I'd like to ensure that these kind of problems would arise at least as warnings when importing libs
16:55:18 × burnsidesLlama quits (~burnsides@client-8-87.eduroam.oxuni.org.uk) (Ping timeout: 276 seconds)
16:55:31 merijn joins (~merijn@83-160-49-249.ip.xs4all.nl)
16:56:22 abbie parts (~abbie@offtopia/offtopian/abbie) (Bye!)
16:56:58 <arkanoid> I mean, I would use Integer for my own functions, but what about if external module uses Int and returned values overflows without a warning?
16:57:46 <jumper149> arkanoid: Well, if it's an external module I don't see any way to fix it.
16:57:47 × Maxdamantus quits (~Maxdamant@user/maxdamantus) (Ping timeout: 255 seconds)
16:58:41 mr-red joins (~drd@2001:b07:a70:9f1f:1562:34de:f50f:77d4)
16:59:24 <nitrix> You cannot deal with the overflow once it happened. You have to check for the _would be_ overflow before hand.
16:59:26 × mr-red quits (~drd@2001:b07:a70:9f1f:1562:34de:f50f:77d4) (Client Quit)
16:59:33 <arkanoid> this is surprising
16:59:56 mr-red joins (~drd@2001:b07:a70:9f1f:1562:34de:f50f:77d4)
17:00:15 <nitrix> What were your expectations? You seem to be fairly aware of that behavior.
17:00:30 × drd quits (~drd@93-39-151-19.ip76.fastwebnet.it) (Ping timeout: 276 seconds)
17:00:43 <lbseale> Would the Scientific type help you? https://hackage.haskell.org/package/scientific-0.3.7.0/docs/Data-Scientific.html
17:01:24 dunkeln joins (~dunkeln@94.129.69.87)
17:01:48 × turlando quits (~turlando@user/turlando) (Remote host closed the connection)
17:02:17 LukeHoersten joins (~LukeHoers@user/lukehoersten)
17:02:41 <arkanoid> I'm aware of it, and I can deal with it within my own code, but this lack of error control or warning makes importing modules unsafe unless checking every internal machinery
17:05:07 jespada joins (~jespada@90.254.247.46)
17:05:58 <Cale> Hecate: I'm not even really opposed to undecidable instances, it's the overlapping ones where things start to get bad. Undecidable ones, the worst that will happen is your build won't finish.
17:06:13 <Cale> (but the cat is funny :)
17:06:39 drd joins (~drd@93-39-151-19.ip76.fastwebnet.it)
17:06:54 <davean> Cale: Its troubling when it might be non-determistic, but yah
17:06:56 × pera quits (~pera@user/pera) (Ping timeout: 256 seconds)
17:07:53 aliosablack joins (~chomwitt@ppp-94-67-193-120.home.otenet.gr)
17:07:59 × drd quits (~drd@93-39-151-19.ip76.fastwebnet.it) (Client Quit)
17:08:04 × xff0x_ quits (~xff0x@port-92-195-69-103.dynamic.as20676.net) (Ping timeout: 256 seconds)
17:08:36 <nitrix> It's the behavior chosen for Int and also what distinguishes it from Integer. If the libraries have been using Int, then they presumably think that edge case wont happen or they're satisfied with the behavior.
17:08:46 drd joins (~drd@93-39-151-19.ip76.fastwebnet.it)
17:09:47 Maxdamantus joins (~Maxdamant@user/maxdamantus)
17:09:56 × chomwitt quits (~chomwitt@2a02:587:dc0e:ef00:12c3:7bff:fe6d:d374) (Ping timeout: 255 seconds)
17:10:15 × mr-red quits (~drd@2001:b07:a70:9f1f:1562:34de:f50f:77d4) (Ping timeout: 276 seconds)
17:11:33 <arkanoid> nitrix: but that's very unsafe
17:11:52 aerona joins (~aerona@2600:6c54:4600:f300:2418:37e9:50f:bf32)
17:12:33 <arkanoid> also, have a look at https://en.wikipedia.org/wiki/Arbitrary-precision_arithmetic , the page is proving my point. It says
17:12:42 <arkanoid> Some programming languages such as Lisp, Python, Perl, Haskell and Ruby use, or have an option to use, arbitrary-precision numbers for all integer arithmetic. Although this reduces performance, it eliminates the possibility of incorrect results (or exceptions) due to simple overflow.
17:12:58 <monochrom> You know what, asm programmers have access to the "carry flag", they can know that overflow has happened if they want to.
17:13:00 <nitrix> What is unsafe about it? There aren't side-effects and the program isn't halting. The arithmetic is defined to behave that way, it's predictable.
17:13:24 <monochrom> Then C goes on to throw away that information and starts a great tradition.
17:13:30 <Cale> Maybe we could have an erroring-Int
17:13:43 <geekosaur> also as I read that I think someone misunderstood "integer-simple"
17:13:45 <Cale> But Int is Z/2^kZ for some k
17:14:23 <monochrom> OTOH you look at the floating point world, they do have floating-point exceptions. Then people go on to suppress it and turn it into NaN. It's a mess either way.
17:14:38 <arkanoid> nitrix: not predictable, as overflow is not sign-checked. "let foo :: Int -> Int; foo x = x^1000", "foo 7" returns -5479429532463080511
17:14:45 <Cale> The fact that k is unspecified and you have to look at maxBound or similar to figure out which ring you're working in is a bit silly.
17:15:04 <nitrix> arkanoid, Your argument boils down to "other languages have the option to ...", but ignore that Haskell has that option as well.
17:15:09 × LukeHoersten quits (~LukeHoers@user/lukehoersten) (Quit: My MacBook has gone to sleep. ZZZzzz…)
17:15:35 LukeHoersten joins (~LukeHoers@user/lukehoersten)
17:16:11 <Cale> arkanoid: 7^1000 = -5479429532463080511 (mod 2^64)
17:17:45 <Cale> There is a bit of tension here though, I get where you're coming from. People use Int as though it were Integer but faster.
17:18:48 <nitrix> Choosing Int implies giving away the arbitrary precision and accepting the overflow behavior.
17:19:13 <arkanoid> Cale: I'm ok with using Integer in all my code, but I'm not ok in importing libraries that could return overflows without warnings or errors.
17:19:25 <Cale> Probably most users of Int don't really want modular arithmetic
17:19:37 <Cale> But that is indeed what they get
17:19:41 <c_wraith> Int is definitely *way* overused
17:20:35 <nitrix> The libraries where it matters don't make that mistake. I think arkanoid is hunting witches.
17:20:38 <Cale> On the other hand, I'm not sure I'd be happy if Int just threw exceptions. That's almost scarier.
17:20:50 <arkanoid> so what I'm asking is if there's a way to raise security level by checking if Int is used or overflow is triggered at runtime in all code, including the imported one
17:20:59 <davean> Cale: I've really wanted to choose the behaviors for my types :/
17:21:04 <davean> I've often wanted saturation
17:21:05 × aliosablack quits (~chomwitt@ppp-94-67-193-120.home.otenet.gr) (Ping timeout: 258 seconds)
17:21:06 <dsal> Can someone help me with a type definition? I'm trying to do stuff with `linear` such that I can build out arbitrary ranges of points. i.e., I've got `class Projector a b where project :: a -> b -> [a]` and I want to be able to have a `V a` and a value of `a` and produce a list of `V`s from the given point to point + size in every dimension.
17:21:32 <Cale> I think if you want to use signalling int, you also probably want an interface to its functionality which is entirely unlike Num
17:21:32 <dsal> So I've got `instance (Enum a, Integral a) => Projector (V2 a) a` which seems to do the right thing, but requires `AllowAmbiguousTypes` to work. That seems odd to me.
17:21:40 <Cale> i.e. you want operations which produce Maybe results
17:22:10 <nitrix> (+?) :: SafeNum n => n -> n -> Maybe n ?
17:22:28 <Cale> Yeah
17:22:32 × johnw quits (~johnw@2600:1700:cf00:db0:4d8f:94c5:5bf3:4c24) (Ping timeout: 255 seconds)
17:23:01 <nitrix> Probably annoying to write expressions in, lifting everything all the time.
17:23:16 <monochrom> "you would go bind"
17:23:27 Clint squints.
17:23:30 <arkanoid> nitrix: I might be hunting witches, but it's a safe thing to do if there's no proof that they doesn not exist
17:23:41 <dsal> The class definition doesn't seem to imply any dependency between `a` and `b` which there probably should be.
17:23:50 johnw joins (~johnw@76-234-69-149.lightspeed.frokca.sbcglobal.net)
17:24:46 <dsal> Oh, and that's my answer, I just defined a functional dependency. Neat.
17:25:05 lavaman joins (~lavaman@98.38.249.169)
17:28:00 waleee joins (~waleee@2001:9b0:216:8200:d457:9189:7843:1dbd)
17:28:08 <arkanoid> I also see that the fromInteger function does not return Error/Maybe, but just a Num, which Int is, so that means that also conversion in unchecked by default. https://wiki.haskell.org/Converting_numbers
17:28:23 × azeem quits (~azeem@dynamic-adsl-84-220-213-65.clienti.tiscali.it) (Ping timeout: 255 seconds)
17:28:47 <geekosaur> int-cast package
17:28:50 × LukeHoersten quits (~LukeHoers@user/lukehoersten) (Ping timeout: 255 seconds)
17:29:06 × lavaman quits (~lavaman@98.38.249.169) (Ping timeout: 240 seconds)
17:29:19 azeem joins (~azeem@176.200.214.29)
17:29:55 × merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 265 seconds)
17:31:43 LukeHoersten joins (~LukeHoers@user/lukehoersten)
17:32:02 <arkanoid> no, I'm not looking for a solution in my code, I'm looking for a solution that checks if the code I'm importing and calling contains these unchecked errors. As for now I have only 2 solutions: test my calling functions for all input domains OR check manually all the imported/called code
17:32:23 <nitrix> Ideally both.
17:33:03 <dsal> arkanoid: This is one of the reasons we like property tests.
17:34:53 burnsidesLlama joins (~burnsides@client-8-87.eduroam.oxuni.org.uk)
17:36:05 <arkanoid> it depends on the input domain. I'm dealing with a 25 dimensional model that's already works in python and another imperative language I'm planning to use, but I wanted to learn haskell to get better handle complexity. This is a show stopper to me
17:36:33 <nitrix> I understand where you're coming from, you now have to trust code written by others instead of relying on the language enforcing these things, which can be frustrating and require additional work if you're the paranoid type. Though, I want to address the "unsafe" you keep bringing up. A mismatch between your expectation and the specification isn't what makes a feature unsafe; it just means your expectations are wrong.
17:37:21 <nitrix> The code is safe. It exhibits the very behavior it's meant to do -- assuming it's the behavior you wanted.
17:37:22 <arkanoid> debatable. Overflow check is part of the safe check list
17:37:40 <nitrix> I disagree.
17:37:40 × tlaxkit quits (~hexchat@170.253.39.204) (Quit: Leaving)
17:38:06 × azeem quits (~azeem@176.200.214.29) (Ping timeout: 256 seconds)
17:38:32 azeem joins (~azeem@dynamic-adsl-84-220-213-65.clienti.tiscali.it)
17:38:58 × burnsidesLlama quits (~burnsides@client-8-87.eduroam.oxuni.org.uk) (Ping timeout: 240 seconds)
17:39:20 <arkanoid> nitrix: just check how other high level languages deal with it. C# for example gives the possibility to enable checked calculations (checked block)
17:39:38 <nitrix> You're conflating "surprising"/"error-prone" with "safety".
17:39:53 Guest92 joins (~Guest92@50.47.115.102)
17:40:32 xff0x_ joins (~xff0x@2001:1a81:5200:1d00:bb8d:5843:c31e:244e)
17:41:14 <arkanoid> overflows compromise program's reliability and security, though safe programming wants you to check that
17:41:18 <monochrom> I used to defend the status quo of wrap-around because it benefitted some of my niche code. But I don't defend it now, my love of "w00t it does mod 2^64" is very, very niche. Most people don't want that.
17:42:16 <monochrom> But the status quo doesn't need to be defended. It has been settled for so long that it is too costly to change.
17:43:27 <monochrom> And while add-on is less costly than change, well let me tell you my favourite Aesop fable.
17:43:34 <nitrix> A knife has a sharp edge and a blunt edge. You use the sharp edge towards the things it needs to cut and the blunt edge to apply pressure. If you accidently use it in the wrong orientation, you'll hurt yourself, and that's surprising. If it's not clear which side is which, then that's error-prone, but the knife isn't more or less safe because of it. It'll cut on it's sharp edge exactly like it's intended to do, whether it's vegetables or your fingers.
17:44:06 <monochrom> The mice hold an internation mice conference to discuss how to mitigate the threat of cats.
17:44:20 <nitrix> I've been on both side of the status-quo. I mostly just think that Haskell's safety has zero to do with it.
17:44:28 <monochrom> They agree on two resolutions.
17:44:50 <[exa]> arkanoid: this might sound harsh but if you want to do x^1000 outside of modular arithmetic, you want to do it on paper and not on computer
17:44:59 <monochrom> 1. A bell is to be worn on the neck of the cat so every mouse can hear the cat coming.
17:45:07 <monochrom> 2. Someone else should do it.
17:45:51 lavaman joins (~lavaman@98.38.249.169)
17:46:20 × Teacup_ quits (~teacup@user/teacup) (Quit: Teacup_)
17:46:28 <[exa]> arkanoid: also, as famously proven in 1930's, where there are large integers, there won't be any provable security.
17:47:07 Teacup joins (~teacup@user/teacup)
17:48:14 mr-red joins (~drd@93-39-151-19.ip76.fastwebnet.it)
17:50:13 × drd quits (~drd@93-39-151-19.ip76.fastwebnet.it) (Ping timeout: 258 seconds)
17:50:36 <arkanoid> point is that while Haskell gives good control on the complexity of the task, gives less safety on the output than other imperative languages
17:50:48 <arkanoid> while being less performant, too
17:51:27 <nitrix> Here it comes.
17:53:08 × mr-red quits (~drd@93-39-151-19.ip76.fastwebnet.it) (Ping timeout: 255 seconds)
17:53:36 × dunkeln quits (~dunkeln@94.129.69.87) (Ping timeout: 265 seconds)
17:54:11 drd joins (~drd@93-39-151-19.ip76.fastwebnet.it)
17:55:00 <nitrix> We're thankful of your assessment and will take it into consideration for our next safety training. Safety is very important to us.
17:55:45 [exa] imports some monadic explosives
17:58:09 dunkeln joins (~dunkeln@94.129.69.87)
17:58:44 gehmehgeh joins (~user@user/gehmehgeh)
17:58:48 × drd quits (~drd@93-39-151-19.ip76.fastwebnet.it) (Read error: Connection reset by peer)
17:59:34 drd joins (~drd@2001:b07:a70:9f1f:1562:34de:f50f:77d4)
18:00:52 × gehmehgeh quits (~user@user/gehmehgeh) (Remote host closed the connection)
18:01:32 gehmehgeh joins (~user@user/gehmehgeh)
18:02:59 <nitrix> head :: [a] -> a, now that's potentially unsafe, though there's very little chance that ever changes.
18:03:46 <Guest92> Haskell could support truthy and falsy values (for example by using a typeclass that represents values that can be converted to Bool) but it doesn't. Why not?
18:04:18 <dsal> Guest92: why do you want this?
18:04:44 <dsal> It's rather nice reducing truth to one possible value and false to another.
18:05:07 <c_wraith> in python, 0 is falsy. In ruby, it's truthy. Which one of them is correct?
18:05:18 <vaibhavsagar[m]> Guest92: you could write your own typeclass that implements the truthy/falsy logic
18:05:28 × drd quits (~drd@2001:b07:a70:9f1f:1562:34de:f50f:77d4) (Quit: ZNC 1.8.2 - https://znc.in)
18:05:32 <vaibhavsagar[m]> but you haven't. why not?
18:05:40 <Guest92> that is correct
18:06:03 <Guest92> I actually did as an experiment
18:06:11 drd joins (~drd@93-39-151-19.ip76.fastwebnet.it)
18:06:11 <vaibhavsagar[m]> the reason we don't do it in Haskell is that it's not actually a good idea
18:06:27 <Guest92> ok, why not?
18:06:32 <c_wraith> the broader context is that it's going the wrong direction. Booleans kind of are bad ideas.
18:06:46 <c_wraith> Treating things as if they were booleans isn't any better.
18:06:55 <nitrix> You would have to demonstrate the laws hold for things like Eq and that wouldn't be pretty.
18:06:58 <flounders> Isn't that more like weak typing like what C does with char?
18:07:07 <c_wraith> You should prefer pattern-matching on domain types
18:07:19 <dsal> See also: Boolean blindness
18:08:01 <Guest92> makes sense, thanks!
18:09:06 × Guest92 quits (~Guest92@50.47.115.102) (Quit: Client closed)
18:10:31 × curiousgay quits (~curiousga@77-120-186-48.kha.volia.net) (Ping timeout: 265 seconds)
18:13:41 <arkanoid> nitrix: https://hackage.haskell.org/package/safeint-0.6/docs/Data-SafeInt.html exist for a reason. Other languages have compiler options to enable overflow check at program level, or better at code level. Where's haskell solution to this? Using Integer in my code is just the tip of the iceberg. Do haskell programmers grep "Int" in all imported code and process it manually?
18:14:51 <dsal> I don't exactly understand your problem. If you use a data type that doesn't satisfy all of your requirements, then it won't satisfy all of your requirements.
18:15:16 <dsal> Is it just that you're using Int and that's not an appropriate type for your problem?
18:16:09 <vaibhavsagar[m]> it sounds like their problem is that overflow might be happening in their dependencies
18:16:21 <vaibhavsagar[m]> and there isn't a language-level way of preventing this
18:16:39 <arkanoid> vaibhavsagar[m]: thanks
18:16:43 <[exa]> apparently some other languages can prevent that
18:16:47 <[exa]> are there examples?
18:16:56 <vaibhavsagar[m]> C# apparently
18:17:05 <arkanoid> https://docs.microsoft.com/en-us/dotnet/csharp/language-reference/keywords/checked
18:17:20 <nitrix> They're worried about code not under their control that would be responsible to overflow, somehow obsessed on the overflow part and not concerned about any other malicious thing that vendor code could be doing.
18:17:21 Guest57 joins (~Guest57@50.47.115.102)
18:18:00 × drd quits (~drd@93-39-151-19.ip76.fastwebnet.it) (Read error: Connection reset by peer)
18:18:08 <nitrix> But my stance is the same. As far as Int goes, that's exactly it's behavior. If you don't want that behavior or can't trust people did their homework when they use it, then apply your policy and refuse that code.
18:18:23 <dsal> I don't understand how this C# thing is any different. So if the code in the dependency uses `checked` that's effectively using the correct data type.
18:18:24 <arkanoid> https://doc.rust-lang.org/std/primitive.i32.html#method.checked_add
18:18:28 × Null_A quits (~null_a@2601:645:8700:2290:707f:6ddd:516:dcea) (Remote host closed the connection)
18:18:47 drd joins (~drd@2001:b07:a70:9f1f:1562:34de:f50f:77d4)
18:19:01 <arkanoid> dsal: the C# check goes all down the stack and check imported logic too
18:19:28 <dsal> The rust checked add is basically function I wrote yesterday for a semigroup implementation of a type that ensures addition only goes up to `maxBound`
18:19:45 <nitrix> Yeah. They mentioned earlier "arbitrary-precision integers in higher-level languages like Lisp, Python, Perl, Ruby" which is again the proper type and Haskell has that too.
18:20:41 × drd quits (~drd@2001:b07:a70:9f1f:1562:34de:f50f:77d4) (Client Quit)
18:20:46 <arkanoid> dsal: but you can enforce it with preprocessing, there are also other tools at type and compiler level. https://doc.rust-lang.org/stable/std/num/struct.Wrapping.html
18:21:04 <arkanoid> nitrix: you are not seeing the problem, apparently
18:21:25 <vaibhavsagar[m]> I'm not seeing the problem either
18:21:26 drd joins (~drd@2001:b07:a70:9f1f:1562:34de:f50f:77d4)
18:21:29 <vaibhavsagar[m]> use `Integer`
18:21:31 <arkanoid> having it for MY code doesn't make it into imported logic
18:21:38 <vaibhavsagar[m]> or `toIntegralSized`
18:21:47 <dsal> I don't know rust, but nothing you're describing there sounds much different from how I'd do it in Haskell.
18:21:59 <[exa]> arkanoid: do all rust packages use the checked_add ?
18:22:03 <nitrix> I understand your problem. "What if someone has a malicious call to exit(), or launchTheNukes() in their library that I'm not expecting".
18:22:24 <vaibhavsagar[m]> https://hackage.haskell.org/package/base-4.15.0.0/docs/Data-Bits.html#v:toIntegralSized
18:23:08 <nitrix> And I also understand that you're under the impression that this is something that the type system would prevent, but you're misunderstanding the situation. There is _nothing_ to prevent, this is the desired behavior for Int.
18:23:14 <arkanoid> this is at compiler level https://doc.rust-lang.org/rustc/codegen-options/index.html#overflow-checks
18:24:06 <[exa]> arkanoid: is downing an airplane because of an overflow better than just continuing on a slightly wrong trajectory?
18:24:12 <dsal> Does the compiler have checks for other mathematical errors that might exist in the code?
18:24:14 <vaibhavsagar[m]> that's not a type system check
18:24:29 × drd quits (~drd@2001:b07:a70:9f1f:1562:34de:f50f:77d4) (Client Quit)
18:24:46 drd joins (~drd@93-39-151-19.ip76.fastwebnet.it)
18:25:39 <vaibhavsagar[m]> it looks like it checks for division by zero errors: https://stackoverflow.com/questions/42544491/can-i-disable-checking-for-zero-division-every-time-the-division-happens
18:25:39 <DigitalKiwi> [exa]: what if it's a rocket on a slightly wrong trajectory lol
18:26:08 <[exa]> DigitalKiwi: might be useful tbh :D
18:26:16 <nitrix> The wrong trajectory is a bad analogy. The result still has to be mathematically correct for Int.
18:26:47 <nitrix> The difference here is that Int semantics follows modulo-arithmetic, which arkanoid refuses to believe in.
18:27:18 <DigitalKiwi> https://twitter.com/hdevalence/status/1413559229672165380
18:27:18 <[exa]> nitrix: for a programmer who didn't expect the overflow the trajectory is going to be literally the wrong one :]
18:27:21 <dsal> Does that mean that in C# code that's otherwise correct will start throwing an exceptions under certain contexts?
18:28:52 <DigitalKiwi> oh yeah this one https://twitter.com/pee_zombie/status/1413567104679387143
18:29:12 <nitrix> [exa], Except you would expect the overflow, since you chose Int and you know that it does overflow.
18:29:22 <arkanoid> checking overflows means that you know when it happens. The effect my vary. May throw an exception, may print a warning, and so on. Surely not return 0 or something else
18:29:41 <nitrix> That's literally it's behavior. If you don't like the behavior then pick a type with a better behavior.
18:29:44 leeper joins (leeper@gateway/vpn/nordvpn/leeper)
18:29:52 <arkanoid> nitrix: other-people-code
18:29:56 × drd quits (~drd@93-39-151-19.ip76.fastwebnet.it) (Read error: Connection reset by peer)
18:30:02 <arkanoid> you keep ignoring the point
18:30:03 <[exa]> nitrix: yeah but we are talking about the other programmers now
18:30:13 <nitrix> And yes, people sometimes use Int when they should use Integer. It's acceptable for some programs, for programs that it's not, then of course you don't use those.
18:30:39 slice joins (~slice@user/slice)
18:30:45 drd joins (~drd@2001:b07:a70:9f1f:1562:34de:f50f:77d4)
18:30:48 <DigitalKiwi> http://www.math.sjsu.edu/~foster/m143m/ariane_rocket_overflow.pdf
18:30:53 <nitrix> Then don't use the code that's problematic.
18:31:06 <c_wraith> I pretty much only use Int if it's describing the cardinality of something in memory.
18:31:07 <nitrix> Why are you making this so complicated. Use what work, don't use what doesn't.
18:31:24 × drd quits (~drd@2001:b07:a70:9f1f:1562:34de:f50f:77d4) (Client Quit)
18:31:40 drd joins (~drd@93-39-151-19.ip76.fastwebnet.it)
18:31:47 <[exa]> DigitalKiwi: okay that was the unlucky one
18:32:37 <[exa]> DigitalKiwi: my airplane overflowed the seatbelt ding statistic counter and somehow survived
18:32:43 <DigitalKiwi> https://www-users.cse.umn.edu/~arnold/disasters/patriot.html
18:33:07 × drd quits (~drd@93-39-151-19.ip76.fastwebnet.it) (Read error: Connection reset by peer)
18:33:25 <arkanoid> I'm really quite surprised that haskell ignores a problem that literally killed people
18:33:55 drd joins (~drd@93-39-151-19.ip76.fastwebnet.it)
18:34:14 × dyeplexer quits (~dyeplexer@user/dyeplexer) (Remote host closed the connection)
18:34:49 <nitrix> There are a multitude of other ways for logic or arithmetic in software to be wrong that Haskell (or any language for that matter) can prove incorrect.
18:35:01 <dsal> Haskell lets you use types to express problems safely. It also lets you choose the wrong solutions to problems.
18:35:16 × drd quits (~drd@93-39-151-19.ip76.fastwebnet.it) (Read error: Connection reset by peer)
18:35:28 <nitrix> cannot*
18:35:55 <jumper149> arkanoid: If you really feel like `Int` is so bad, feel free to create a new Prelude, where all functions take `Integer`. At that point you might as well start to use `Natural` though.
18:35:56 × mc47 quits (~mc47@xmonad/TheMC47) (Remote host closed the connection)
18:36:05 drd joins (~drd@93-39-151-19.ip76.fastwebnet.it)
18:36:36 <nitrix> They said they could; they're worried about "other code".
18:36:37 <DigitalKiwi> i use peno numbers in all of my rocket guaidance systems
18:36:58 <DigitalKiwi> peano
18:37:07 <arkanoid> yeah, I can run quickcheck on the entire problem domain to ensure that the called code doesn not contain Integer to Int conversion or whatever may raise overflow. Grep is more officient on that
18:37:08 <[exa]> DigitalKiwi: my point was, roughly, would throwing an exception instead of overflowing save anything there?
18:37:12 <nitrix> Not understanding that the moment they bring vendor code, the "other code" becomes "their code" and therefore their own liability.
18:37:13 <vaibhavsagar[m]> arkanoid: you might be under the impression that Haskell is the most advanced programming language that enables you to avoid all correctness and safety issues. Unfortunately that will never be tru
18:37:47 <vaibhavsagar[m]> it's still possible to write awful awful code with glaringly obvious logic bugs
18:38:03 × drd quits (~drd@93-39-151-19.ip76.fastwebnet.it) (Client Quit)
18:38:18 <vaibhavsagar[m]> we can help avoid some classes of issues, but not others
18:38:50 drd joins (~drd@93-39-151-19.ip76.fastwebnet.it)
18:38:59 <dsal> That's generally true. Any language that doesn't let you write bugs doesn't let you write much of anything.
18:39:40 <vaibhavsagar[m]> but particularly in this case contrasted with e.g. Rust that cares a lot about memory safety but not so much about side effects
18:39:43 curiousgay joins (~curiousga@77-120-186-48.kha.volia.net)
18:39:48 <vaibhavsagar[m]> the tradeoffs are different
18:40:14 <nitrix> For what it's worth, Rust's int types have the same behavior.
18:40:31 <nitrix> There's tooling to catch it and you can write tests too, but it's the exact same.
18:40:52 <DigitalKiwi> [exa]: oh yeah also the 737 MAX ;_;
18:40:56 soft-warm joins (~soft-warm@2600:8801:db01:8f0:9615:1e45:d06d:2d70)
18:41:11 <dsal> arkanoid: grep will help you find the one thing you're worried about once. quickcheck will help you ensure your properties hold true. Using the right types will make it difficult to express incorrect logic (e.g. if you use `finite-typelits` you won't be able to have a value outside of your defined range)
18:41:43 <arkanoid> vaibhavsagar[m]: I had the illusion that having such high level control and math-rooted logic would have been a safer choice over other system programming languages, but I'm actually realising that it's not so different from others, Yeah I was expecting tradeoffs, but not on int overflow.
18:42:06 <vaibhavsagar[m]> ah, but haskell isn't a systems programming language
18:42:16 <vaibhavsagar[m]> you can use it to write systems programs
18:42:24 <vaibhavsagar[m]> but that's definitely not where its focus is
18:43:04 <arkanoid> I know. https://programatica.cs.pdx.edu//House/
18:43:21 <dsal> You can represent all your numbers as `String`s and have all kinds of bizarre problems. Being able to to use the wrong type isn't a bug.
18:45:06 <dsal> "`Int` does the thing your processor does with ints" doesn't seem like a misfeature.
18:46:08 <DigitalKiwi> https://en.wikipedia.org/wiki/Boeing_737_MAX#Accidents_and_incidents
18:46:21 <davean> Just going to say, this seems like the world's most boring argument
18:46:25 <arkanoid> proving the whole input domain is a solution available in all languages used the industry, but that's not always feasible and kinda last resort. Modern languages use to have checks at program level
18:46:33 <davean> "Thing that does the thing it was selected to do, doesn't do the thing I want it to do"
18:46:40 <davean> So, uh, use the thing that does the thing you want it to do
18:46:52 <arkanoid> davean: you're missing the point
18:47:17 <DigitalKiwi> davean: https://twitter.com/leftpaddotpy/status/1416279646253895680?s=20 lol
18:47:31 <arkanoid> Ints do overflow, it's normal. Check that your program does not overflow, that's also desiderable. Doing that early is an indistry requirement
18:47:41 × peterhil quits (~peterhil@mobile-access-5d6af6-209.dhcp.inet.fi) (Ping timeout: 252 seconds)
18:47:57 × fef quits (~thedawn@user/thedawn) (Ping timeout: 244 seconds)
18:48:12 × hrnz quits (~ulli@irc.plumbing) (Quit: das ist mir zu bld hier; bb)
18:48:26 hrnz joins (~ulli@irc.plumbing)
18:49:30 × lavaman quits (~lavaman@98.38.249.169) (Ping timeout: 256 seconds)
18:49:40 <arkanoid> whatever, I got my answer. Haskell is not better on this than C, but hopefully it is easier to assure later on in production than C
18:49:41 × drd quits (~drd@93-39-151-19.ip76.fastwebnet.it) (Quit: ZNC 1.8.2 - https://znc.in)
18:50:07 <dsal> I don't think that "I'd like to use the wrong type and then also enforce a property that it doesn't have the wrong behavior" is a solution that makes sense. We have different types with different properties. You can't say the entire language is bad because it lets someone use the wrong type for a problem.
18:50:29 drd joins (~drd@2001:b07:a70:9f1f:1562:34de:f50f:77d4)
18:50:35 <davean> dsal: as I said, this is the stupidest argument ever
18:50:52 <arkanoid> language is not bad, lack of compiler option or linter tool to solve this is
18:51:04 <davean> arkanoid: if you want a tool for this, use liquid haskell?
18:51:11 <davean> But no, theres no linting or anything that makes sense here
18:51:17 <davean> Int *is* correct for a bunch of stuff
18:51:44 <davean> You'd need a spec to show when it might be wrong, I SPECIFICLY overflow Int all the time, on purpose - its a ring
18:51:51 <davean> if you want a spec, use liquid Haskell
18:51:56 <davean> then you can check you don't violate it
18:52:27 × drd quits (~drd@2001:b07:a70:9f1f:1562:34de:f50f:77d4) (Read error: Connection reset by peer)
18:53:12 drd joins (~drd@2001:b07:a70:9f1f:1562:34de:f50f:77d4)
18:53:26 <DigitalKiwi> davean: https://dpaste.com/8Z6NE5XXT#wrap
18:54:24 <davean> DigitalKiwi: *cries tears of hours lost to not quite getting something as good as debian via nixos*
18:54:34 <davean> DigitalKiwi: I've lost production data to having used nix though
18:54:40 <DigitalKiwi> :(
18:54:40 <davean> specificly nixpkgs though
18:54:55 <davean> because IT VIOLATED ALL SANITY AND SPECIFICLY STRIPPED OUT MY DEPENDENCY REQUIREMENTS ON ME
18:55:17 <davean> TO be specific, I said "I MUST have a version of directory at least as new as this patch level"
18:55:21 <DigitalKiwi> i have a very much love hate relationship with it
18:55:30 <davean> and it went "Nah, lier, you'll take what the compiler ships and I'll just do that instead"
18:56:45 <davean> They claimed all constraints on packages shipped with GHC were bogus and unneccissary and thus to be ignored
18:56:51 <davean> which is frankly ... insane
18:57:12 <davean> So instead of not building something, nixpkgs decided it was ok to just force it to build wrong
18:57:31 <davean> which of *course* it didn't work right under
18:57:51 <DigitalKiwi> oh yeah i spend a lot of time fighting haskel4nix ;(
18:57:52 <davean> I required that damn patch because it fixed a bug I was impacted by!
18:58:29 <c_wraith> I really like the idea of nix, but every time I've tried to use it I end up confused by how they can take a good idea and implement it with so many gotchas
18:58:46 <davean> c_wraith: yah, nix is a wonderful idea, but the actual implimentation is fucked
18:58:58 <davean> I want nix's successor
18:59:02 <DigitalKiwi> https://github.com/pulls?q=is%3Apr+author%3AKiwi+archived%3Afalse+is%3Aclosed
19:00:34 <davean> c_wraith: I mean, a lot of nix's issues seem to come from its limitations, of not being built *quite* well enough
19:00:40 × drd quits (~drd@2001:b07:a70:9f1f:1562:34de:f50f:77d4) (Ping timeout: 268 seconds)
19:00:42 <davean> c_wraith: So like, I get why it has them
19:00:46 <davean> but that doesn't mean it doesn't have them
19:00:58 <davean> And I don't know how you fix the core engenering at the bottom of it all
19:01:25 nate3 joins (~nate@108-233-125-227.lightspeed.sntcca.sbcglobal.net)
19:01:33 <DigitalKiwi> a lot of the trouble i've had with nix is more directly because of just how broken everything else is >.>
19:01:54 <davean> DigitalKiwi: fair, theres some of that too
19:01:59 pera joins (~pera@user/pera)
19:03:47 dagit_ joins (~dagit@2601:1c2:1b7f:9fa0:54b1:3520:a1d6:48b1)
19:03:47 × fradet_ quits (~fradet@216.252.75.247) (Read error: Connection reset by peer)
19:03:56 <davean> DigitalKiwi: though I've realized I've got a 3rd problem with nix, and thats that everything is done entirely differently so every time I have to fix something in nix, its always "learn an entire new thing from scratch" because nothing shares approaches in nixpkgs
19:04:30 <davean> and its not like Haskell where theres some pretty clear cut interface signaling
19:04:44 <DigitalKiwi> haskell.nix is a lot better than haskell4nix for versions i think
19:04:49 <davean> you have to get under the hood and into the implimentation of every package, and from there every seperate ecosystem
19:04:53 <davean> to have a hope of getting anything fixed
19:05:27 dagit_ is now known as dagit
19:05:40 <DigitalKiwi> yeah like i have a lot of electron apps i maintain and at least 3 different ways they're packaged lol >.>
19:06:01 <davean> yah, and you maintain those
19:06:17 <davean> I know of very few nix pkgs that have actually worked for me directly
19:06:21 <davean> they've ALMOST all had bugs
19:06:21 <juri_> rewrite electron in haskell. *runs*
19:06:31 <davean> juri_: I'd prefer to rewrite nix in Haskell
19:07:01 <juri_> fair enough.
19:07:16 <DigitalKiwi> https://github.com/haskell-nix/hnix done
19:07:24 <davean> I think the weaknesses of nix as a language - and as a system - get to the core of a lot of why nix has so many issues
19:07:28 <DigitalKiwi> (needs work lol)
19:07:33 Null_A joins (~null_a@2601:645:8700:2290:707f:6ddd:516:dcea)
19:07:45 <davean> DigitalKiwi: Thats the language, I mean I think nix as a language spec is a large portion of the problem
19:08:10 doyougnu joins (~user@c-73-25-202-122.hsd1.or.comcast.net)
19:08:14 <davean> There are a lot of things that are hard to solve in it
19:08:21 <davean> and its very expensive to have a lot of nix code
19:08:35 <davean> it also doesn't really allow pushing stuff to being data
19:08:50 zebrag joins (~chris@user/zebrag)
19:09:30 <davean> Its abstraction budget is near zero
19:11:05 <davean> You really have to translate tihngs *into* nix instead of have nix reference stuff also
19:11:38 <flounders> I don't have any real experience with either Nix or Guix, but how does Guix compare?
19:12:04 <davean> flounders: no idea, does anyone have experience with Guix?
19:12:22 <DigitalKiwi> i know some people do
19:12:46 <DigitalKiwi> at least one of them seems to like it
19:13:21 <davean> DigitalKiwi: wow, well thats infinitely more people than I know of even having tried Guix!
19:15:00 berberman_ joins (~berberman@user/berberman)
19:15:54 × berberman quits (~berberman@user/berberman) (Ping timeout: 240 seconds)
19:16:11 zeenk joins (~zeenk@2a02:2f04:a008:d600:18f2:3421:bac6:8f38)
19:16:48 drakonis joins (drakonis@user/drakonis)
19:16:49 <Clint> i know more guix people than nix people
19:16:50 <Clint> different circles
19:17:25 shapr joins (~user@pool-100-36-247-68.washdc.fios.verizon.net)
19:17:55 DigitalKiwi hugs shapr
19:18:07 <drakonis> hullo
19:18:36 <DigitalKiwi> drakonis: here's one now lol
19:18:39 <DigitalKiwi> bah
19:18:47 <DigitalKiwi> davean: ^
19:18:50 <drakonis> i have been invoked
19:19:07 tommd joins (~tommd@75-164-130-101.ptld.qwest.net)
19:19:46 × oxide quits (~lambda@user/oxide) (Ping timeout: 250 seconds)
19:20:26 × acro quits (~acro@user/acro) (Quit: Bye.)
19:20:26 × ouroboros quits (~ouroboros@user/ouroboros) (Quit: Bye.)
19:20:52 oxide joins (~lambda@user/oxide)
19:21:00 <shapr> o hi DigitalKiwi
19:22:38 ouroboros joins (~ouroboros@user/ouroboros)
19:23:08 acro joins (~acro@user/acro)
19:23:10 × Null_A quits (~null_a@2601:645:8700:2290:707f:6ddd:516:dcea) (Remote host closed the connection)
19:23:42 burnsidesLlama joins (~burnsides@client-8-87.eduroam.oxuni.org.uk)
19:24:03 drd joins (~drd@93-39-151-19.ip76.fastwebnet.it)
19:24:20 Null_A joins (~null_a@2601:645:8700:2290:707f:6ddd:516:dcea)
19:25:38 <DigitalKiwi> drakonis: is guix better than nix/pkgs
19:26:00 <DigitalKiwi> davean has been burned by haskell4nix as many have ;_;
19:26:08 merijn joins (~merijn@83-160-49-249.ip.xs4all.nl)
19:26:09 <drakonis> hmm, i would that it is an improvement in many regards
19:26:12 <drakonis> say
19:26:57 × ouroboros quits (~ouroboros@user/ouroboros) (Client Quit)
19:26:57 × acro quits (~acro@user/acro) (Client Quit)
19:27:39 acro joins (~acro@user/acro)
19:27:42 <DigitalKiwi> davean: there you go 100% of people you know use guix say it's an improvement
19:28:18 <davean> Apparently
19:28:22 <davean> Hard to argue with that
19:28:23 <drakonis> basically, one of the things that i can't say i like about nix is that the underlying language doesnt scale as well as a full language
19:28:26 <DigitalKiwi> and Clint knows more guix people than nix people so more people like guix than nix
19:28:27 <DigitalKiwi> qed
19:28:40 ouroboros joins (~ouroboros@user/ouroboros)
19:28:42 Clint grins.
19:28:48 <davean> drakonis: I said that!
19:28:52 <drakonis> there have been a lot of changes to paper over issues with nixlang handing off a lot of tasks to other languages
19:29:20 <drakonis> guix, being built with guile scheme can avoid these issue
19:29:22 <drakonis> issues
19:30:05 <drakonis> it is entirely a set of libraries in scheme that can be reused for other tasks
19:30:16 <drakonis> so there's a much nicer design
19:30:58 × soft-warm quits (~soft-warm@2600:8801:db01:8f0:9615:1e45:d06d:2d70) (Ping timeout: 246 seconds)
19:31:31 <drakonis> heck, i think nix would've been significantly nicer if it was done in ocaml back in the day instead of building a whole new thing just for it
19:33:15 <drakonis> this is also a strike against the nix language, not just what the package manager is written with
19:33:55 <drakonis> i'd rather have it built as a dsl of a full language than cooking up a specific language for handling the tasks
19:34:54 pesada joins (~agua@2804:18:4f:4b5e:1:0:5480:48f9)
19:35:43 <davean> So who's rewriting nix?
19:36:05 geekosaur invokes previously mentioned fable
19:36:49 <maerwald> davean: lol
19:36:54 <drakonis> hmm, there's no nix rewrite except for the descendents
19:37:02 × curiousgay quits (~curiousga@77-120-186-48.kha.volia.net) (Ping timeout: 265 seconds)
19:37:23 <maerwald> the biggest problem with nix isn't even the language, imo, but the anarchy of packaging methodologies
19:37:33 <davean> maerwald: also mentioned that!
19:37:40 × agua quits (~agua@191.177.175.57) (Ping timeout: 268 seconds)
19:38:19 <drakonis> there's a nix/guix descendent written in racket but it is too soon to be competitive with nix/nixos/nixpkgs and guix
19:38:21 <DigitalKiwi> <butterfly meme> is this an echo chamber?
19:38:32 <drakonis> also tell you what
19:39:11 <maerwald> drakonis: IDC what language they use... do they have actual QA and non-broken workflows?
19:39:22 <drakonis> gosh, they sure do
19:39:29 <maerwald> people treat nixpkgs like hackage, upload whatever
19:39:42 <drakonis> guix doesnt have nixpkgs' package churn
19:39:42 × alx741 quits (~alx741@186.178.108.59) (Ping timeout: 250 seconds)
19:39:48 <drakonis> what's available is generally pretty decent
19:40:05 <drakonis> there isnt four thousand commits a month but what's there has standards
19:40:06 <sm> arkanoid: on a practical level, you can forbid use of Int in your code, and audit your libraries, trying to minimize the use of Int there too. hlint might help here, otherwise it shouldn't be too hard to do yourself
19:40:25 <drakonis> ie: guix doesnt include new langs unless it can successfully bootstrap them all the way to the current release
19:40:53 × leeper quits (leeper@gateway/vpn/nordvpn/leeper) (Quit: Leaving)
19:41:27 <sm> arkanoid: also you might like the new Witch lib which helps convert number types safely
19:41:48 <drakonis> there's also a stronger focus on reproducibility
19:42:00 <drakonis> also serious talk
19:42:06 <drakonis> i don't enjoy using the nix lang
19:42:12 <drakonis> i'd rather write everything in scheme
19:42:25 <drakonis> its simpler and cleaner to get to where i want
19:43:22 <DigitalKiwi> i never even learned nix lang real well which is probably part of my problem ;_;
19:43:39 <drakonis> that's indeed part of the problem
19:43:53 <drakonis> a thing i've been repeating for a little bit is that working with the nix lang is a lot like banging rocks until it works
19:44:02 <drakonis> because everything is so poorly explained
19:44:54 <DigitalKiwi> https://twitter.com/ArchKiwi/status/1249937493308387328?s=20
19:45:15 vicfred joins (~vicfred@user/vicfred)
19:45:35 <drakonis> so let me start by posting the most important thing about guix
19:45:37 hnOsmium0001 joins (uid453710@id-453710.stonehaven.irccloud.com)
19:45:41 <drakonis> those docs, they're so good
19:46:03 <drakonis> the cli, the docs, the repo organization
19:46:06 <drakonis> its so clean and minty
19:46:09 <DigitalKiwi> .glirclogs/#haskell/2021-04-29.log:[18:20:18] <DigitalKiwi> i'm not even good at nix lol i just hit shit with hammers until it works
19:46:11 <DigitalKiwi> lolol
19:46:11 <drakonis> fresh and minty
19:46:25 <drakonis> beautiful
19:46:33 <drakonis> https://guix.gnu.org/en/manual/devel/en/guix.html
19:46:34 × mrus quits (~mrus@149.28.61.155) (Ping timeout: 240 seconds)
19:47:09 × burnsidesLlama quits (~burnsides@client-8-87.eduroam.oxuni.org.uk) (Remote host closed the connection)
19:47:14 <drakonis> so, one obnoxious nix thing is that there's an severe overuse of wrappers to create execution environments, this has caused nix package interop to be a pain
19:47:35 <drakonis> rather than cleanly designing packages to not require a lot of cheating during builds to function
19:48:19 × drd quits (~drd@93-39-151-19.ip76.fastwebnet.it) (Quit: ZNC 1.8.2 - https://znc.in)
19:49:56 <drakonis> so you need to install a bunch of ghc packages on nix, you're going to need to invoke haskellpackages.ghcwithpackages
19:50:14 <drakonis> with guix you just include the packages you want, no weird closure drudgery
19:50:42 <drakonis> also no programatically generated packages everywhere lol
19:50:54 <drakonis> you just invoke importers if you need something off hackage
19:51:12 <drakonis> the importers themselves are available by default and arent written by third parties
19:51:49 burnsidesLlama joins (~burnsides@client-8-87.eduroam.oxuni.org.uk)
19:52:04 <drakonis> https://guix.gnu.org/en/manual/devel/en/guix.html#Contributing maerwald this is for you
19:52:25 <maerwald> too much work
19:52:32 agua joins (~agua@191.177.175.57)
19:52:36 <maerwald> distros give you burnout :)
19:52:36 <drakonis> is it ever
19:52:52 <drakonis> well, the general experience has been pretty smooth
19:52:55 × jonathanx quits (~jonathan@h-178-174-176-109.A357.priv.bahnhof.se) (Remote host closed the connection)
19:52:56 alx741 joins (~alx741@186.178.108.3)
19:53:18 jonathanx joins (~jonathan@h-178-174-176-109.A357.priv.bahnhof.se)
19:53:58 ubert joins (~Thunderbi@91.141.46.134.wireless.dyn.drei.com)
19:54:25 <drakonis> anyways, life is easier on guix
19:54:52 <drakonis> it hasnt spired out of control the way nixos has
19:55:08 <maerwald> does steam work?
19:55:20 <maerwald> with gpu acceleration
19:55:26 <drakonis> sure does
19:55:40 <drakonis> but it requires using nonguix to get the stuff that doesnt go on the mainline repos
19:55:46 <drakonis> pretty clean affair i suppose?
19:55:57 × pesada quits (~agua@2804:18:4f:4b5e:1:0:5480:48f9) (Ping timeout: 245 seconds)
19:56:40 <drakonis> except for nvidia, but that one's because nobody really put a ton of effort on making sure it works seamlessly
19:56:56 <drakonis> you can install and use it but it has a couple issues that still need ironing out
19:57:44 <drakonis> the repo is called nonguix
19:57:56 <drakonis> there's an irc channel with the same name here in libera
20:00:17 × merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 252 seconds)
20:05:09 × juhp quits (~juhp@128.106.188.220) (Ping timeout: 258 seconds)
20:06:45 juhp joins (~juhp@128.106.188.220)
20:08:56 × gehmehgeh quits (~user@user/gehmehgeh) (Remote host closed the connection)
20:09:40 gehmehgeh joins (~user@user/gehmehgeh)
20:09:59 curiousgay joins (~curiousga@77-120-186-48.kha.volia.net)
20:10:58 × xff0x_ quits (~xff0x@2001:1a81:5200:1d00:bb8d:5843:c31e:244e) (Ping timeout: 268 seconds)
20:11:43 xff0x_ joins (~xff0x@port-92-195-69-103.dynamic.as20676.net)
20:12:42 × ubert quits (~Thunderbi@91.141.46.134.wireless.dyn.drei.com) (Ping timeout: 240 seconds)
20:14:32 × eagleflo quits (~aku@eagleflow.fi) (Remote host closed the connection)
20:14:37 ubert joins (~Thunderbi@91.141.46.134.wireless.dyn.drei.com)
20:14:56 jeetelongname joins (~jeet@host-89-241-98-229.as13285.net)
20:16:41 <janus> is there a way in haskell to transform do { x<-receive; send x } into StateT $ \case State0 -> do { x<-receive; pure (State1 x, Nothing); }; State1 x -> (State0, Just x) }
20:17:45 <janus> i suspect not, unless i add a "yield" between receive and send... but even if i do, how would i generate those state constructors automatically?
20:18:29 <janus> maybe with templateHaskell there is a way to say "stuff every captured binding of the do into a parameter list" ?
20:18:56 <janus> or maybe with RebindableSyntax?
20:19:33 chomwitt joins (~chomwitt@ppp-94-67-193-120.home.otenet.gr)
20:20:23 <janus> if do notation is "reprogrammable semicolon", what is the "reprogrammable monadic bind" ?
20:20:47 jkachmar[m] joins (~jkachmarm@2001:470:69fc:105::c72d)
20:21:07 <xerox> oh I know that one
20:21:35 <xerox> https://ghc.gitlab.haskell.org/ghc/doc/users_guide/exts/rebindable_syntax.html?highlight=rebindable#extension-RebindableSyntax
20:22:10 <yushyin> QualifiedDo?
20:22:46 <geekosaur> or in 9.2 https://downloads.haskell.org/ghc/latest/docs/html/users_guide/exts/qualified_do.html
20:25:28 × _ht quits (~quassel@82-169-194-8.biz.kpn.net) (Remote host closed the connection)
20:26:17 jkachmar[m] is now known as jkachmar
20:29:28 × nate3 quits (~nate@108-233-125-227.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 268 seconds)
20:30:40 × jkachmar quits (~jkachmarm@2001:470:69fc:105::c72d) (Quit: Reconnecting)
20:30:54 jkachmar joins (~jkachmar@2001:470:69fc:105::c72d)
20:31:05 × acro quits (~acro@user/acro) (Quit: Bye.)
20:31:05 × ouroboros quits (~ouroboros@user/ouroboros) (Quit: Bye.)
20:31:24 jmorris joins (uid433911@id-433911.stonehaven.irccloud.com)
20:31:47 acro joins (~acro@user/acro)
20:32:47 ouroboros joins (~ouroboros@user/ouroboros)
20:33:07 <arkanoid> sm: thanks for the answer, that's exactly what I'm planning. I'm also looking into hlint for the option to restrict type usage (it is just hinted in the readme)
20:38:16 <arkanoid> I'm also considering Safe Haskell https://downloads.haskell.org/~ghc/7.8.4/docs/html/users_guide/safe-haskell.html
20:39:15 chris_ joins (~chris@81.96.113.213)
20:39:30 Guest14 joins (~Guest14@2a02:1210:601c:a300:5935:4f81:fbf2:115c)
20:40:35 <monochrom> Safe Haskell only avoids unsafePerformIO and unchecked type casting, not arithmetic overflow.
20:40:51 <janus> arkanoid: did you see this? https://libredd.it/r/haskell/comments/msa3oq/safe_haskell/
20:41:00 <monochrom> Yes one has to eventually realized that everyone defines "safe" differently.
20:41:18 <janus> yushyin: ooooh i'll check it out.. didn't cross my mind somehow
20:42:37 <janus> xerox: i think qualifiedDo looks superior to RebindableSyntax.. so i'll check that out first
20:43:30 vicfred_ joins (~vicfred@fixed-187-190-192-58.totalplay.net)
20:45:35 <arkanoid> janus: thanks, I've just met Safe Haskell didn't know about it's background story
20:45:49 <drakonis> davean: is your issue with nix either technical or social?
20:45:56 vicfred__ joins (~vicfred@94.198.42.69)
20:46:05 × Vajb quits (~Vajb@hag-jnsbng11-58c3a1-224.dhcp.inet.fi) (Remote host closed the connection)
20:46:29 <drakonis> just to be sure
20:46:34 <davean> drakonis: i'm in a meeting ATM, the conversatio nwas right before you joined
20:46:35 <janus> arkanoid: i like this quote by Cale
20:46:38 × dunkeln quits (~dunkeln@94.129.69.87) (Ping timeout: 265 seconds)
20:46:41 <janus> > Cale: Safe Haskell doesn't mean it's safe to compile the code, it means a bunch of random stuff which has to do with trying to make sure expression evaluation is referentially transparent...
20:46:42 <lambdabot> <hint>:1:62: error: parse error on input ‘,’
20:46:45 <drakonis> ah i see
20:46:46 × vicfred quits (~vicfred@user/vicfred) (Ping timeout: 272 seconds)
20:47:04 × Null_A quits (~null_a@2601:645:8700:2290:707f:6ddd:516:dcea) (Remote host closed the connection)
20:47:13 <geekosaur> quick summary of davean's expressed position: both
20:47:27 <geekosaur> both issues with the language, and issues with QA/procedures
20:47:51 <davean> The concept is still a great one
20:48:03 <monochrom> Technical problems have social origins. Humans are the cause of human problems.
20:48:05 <davean> drakonis: https://ircbrowse.tomsmeding.com/browse/lchaskell is probably useful though
20:48:27 × vicfred_ quits (~vicfred@fixed-187-190-192-58.totalplay.net) (Ping timeout: 245 seconds)
20:48:37 × Guest14 quits (~Guest14@2a02:1210:601c:a300:5935:4f81:fbf2:115c) (Quit: Client closed)
20:48:52 MorrowM joins (~Morrow@bzq-110-168-31-106.red.bezeqint.net)
20:49:18 <arkanoid> monochrom: I know that Safe Haskell was not covering that, but as I'm studying haskell to improve my control over the complexity. I generally like the options to lockdown the language in that direction, as I tend to do the same with every one
20:49:32 × jco quits (~jco@213-64-226-9-no542.tbcn.telia.com) (Ping timeout: 265 seconds)
20:50:01 × Morrow quits (~Morrow@bzq-110-168-31-106.red.bezeqint.net) (Ping timeout: 265 seconds)
20:50:16 ub joins (~Thunderbi@91.141.46.134.wireless.dyn.drei.com)
20:50:32 Vajb joins (~Vajb@hag-jnsbng11-58c3a1-224.dhcp.inet.fi)
20:51:04 acidjnk joins (~acidjnk@p200300d0c72b9549b83720658b9c4b74.dip0.t-ipconnect.de)
20:52:02 × vicfred__ quits (~vicfred@94.198.42.69) (Quit: Leaving)
20:52:12 vicfred joins (~vicfred@user/vicfred)
20:52:17 × ubert quits (~Thunderbi@91.141.46.134.wireless.dyn.drei.com) (Ping timeout: 268 seconds)
20:52:18 ub is now known as ubert
20:52:28 nate3 joins (~nate@108-233-125-227.lightspeed.sntcca.sbcglobal.net)
20:54:34 <drakonis> davean: fair enough
20:54:40 <drakonis> i checked the logs
20:54:52 <drakonis> but yes, i think guix can do much better in both regards
20:55:00 × eggplantade quits (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Remote host closed the connection)
20:55:05 <davean> drakonis: I've love more of a conversation when I have the ability to be present
20:55:30 <drakonis> cool
20:55:38 <arkanoid> drakonis: I'm a new nix user, may I ask what's the deal?
20:56:17 <drakonis> nix has grown incredibly fast and hasn't adapted to it
20:56:36 <drakonis> i'd say its ideas are great but the implementation is archaic
20:57:08 <drakonis> nix is something that is best implemented inside a complete language instead of rolling out your own
20:57:16 × ouroboros quits (~ouroboros@user/ouroboros) (Quit: Bye.)
20:57:17 × acro quits (~acro@user/acro) (Quit: Bye.)
20:57:55 <arkanoid> drakonis: what scares me is the git commit requirements to keep everything on track. I mean, every package update is a git commit, the effort is massive
20:58:35 × nate3 quits (~nate@108-233-125-227.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 252 seconds)
20:58:41 <janus> how is that a problem? rebasing is easy
20:58:59 acro joins (~acro@user/acro)
20:59:27 <drakonis> nix routinely has gobs of commits aiming to clean up the inconsistent packaging
20:59:39 × meinside_ quits (uid24933@id-24933.brockwell.irccloud.com) (Quit: Connection closed for inactivity)
21:00:01 <arkanoid> I mean that the pressure on admins is huge
21:00:40 <janus> ah right... yeah i guess that's what they're trying to solve with flakes
21:00:47 <janus> just to open up another can of worms ;)
21:01:00 <arkanoid> exactly
21:01:09 <DigitalKiwi> .glirclogs/#haskell/2021-03-27.log:[00:42:11] <DigitalKiwi> nix is great in that it solves a ton of problems i had, even more i didn't know i had, makes things trivial that i didn't even think were possible or know i wanted, and creates a bunch of problems along the way! (and solves those too though lol)
21:01:50 <drakonis> flakes is one of those things trying to paper over the issues
21:02:00 <drakonis> because nix does not do multiple sources all that well
21:02:06 <sm> arkanoid there's also Liquid Haskell
21:02:34 <arkanoid> DigitalKiwi: yes but is a moving target. I mean, not your nix-shell, but the project is a huge machine with one million gears that have to be perfectly aligned to work
21:02:49 <drakonis> arkanoid: it has a rather large amount of leaf packages
21:02:59 <drakonis> it has very little quality control too
21:03:28 lavaman joins (~lavaman@98.38.249.169)
21:03:38 <janus> can nix be typed? would it solve the problem of aligning 1M gears?
21:04:02 ouroboros joins (~ouroboros@user/ouroboros)
21:04:07 × fendor quits (~fendor@77.119.223.76.wireless.dyn.drei.com) (Remote host closed the connection)
21:04:25 <arkanoid> drakonis: well hydra does kinda large work for quality control
21:04:32 <drakonis> guix has cuirass as well
21:04:41 <drakonis> janus: they tried that once, it became a new lang
21:04:49 <drakonis> i'm not exactly happy with that but well
21:04:57 <janus> drakonis: oh, what is that called?
21:05:01 <drakonis> nickel
21:05:16 <drakonis> they're going for the config lang crowd lol
21:05:28 <drakonis> it feels like a vanity project at this point
21:05:55 <drakonis> hydra is not quality control though
21:06:02 <drakonis> its for building the archive
21:06:28 <arkanoid> yeah but at least it tell you which derivation builds
21:07:04 <drakonis> sure, but when someone's already writing a package for submission, they've already made sure it works to some degree
21:07:41 <maerwald> heh
21:07:46 <maerwald> that degree can vary wildly
21:07:50 <drakonis> indeed it can
21:07:58 <drakonis> and with how nix works, there are a lot of edge cases
21:08:01 × lavaman quits (~lavaman@98.38.249.169) (Ping timeout: 258 seconds)
21:08:05 <drakonis> so, exhibit A:
21:08:14 <arkanoid> yeah, but then one dependency gets updated and you're back to hydra until libc get's updated and you rebuild all
21:08:16 <drakonis> have you noticed that nobody recommends you to use profiles these days?
21:08:18 <monochrom> Yes, it works on their computer.
21:08:31 <DigitalKiwi> good luck getting the hydra ui to load before the heat death of the universe
21:08:38 <drakonis> cuirass is very sane thankfully
21:08:43 <drakonis> but back to A
21:09:09 <drakonis> as it turns out, the nix community has pretty much reduced nix-env/profiles to irrelevance
21:09:11 <sm> I'm hoping tweag's nickel might be nix 2
21:09:33 <sm> I assume it's closer to that than guix is
21:09:35 <drakonis> due to the majority of packages expecting you to run them with nix-shell
21:09:36 <drakonis> nahhhh
21:09:36 <arkanoid> to me the best nix feature is nix-shell
21:09:42 <drakonis> its not going to be nix 2
21:09:44 <DigitalKiwi> i'm under the impression nickel is diw
21:09:50 <drakonis> diw?
21:09:54 <DigitalKiwi> dead in water
21:10:08 × ubert quits (~Thunderbi@91.141.46.134.wireless.dyn.drei.com) (Ping timeout: 252 seconds)
21:10:10 <drakonis> nickel is a vanity project that isnt going to reasonably compete with guix because, first of all
21:10:24 <drakonis> guile scheme is a general purpose language
21:10:39 <monochrom> http://math.andrej.com/2008/02/02/the-hydra-game/ also has a chance of not ending until the heat death of the universe :)
21:11:01 <drakonis> nix-shell is imo a way to corner yourself with package design
21:11:41 <drakonis> it makes package interop a lot harder than it needs to be
21:12:10 <hendursaga> drakonis: pardon, what's nickel?
21:12:31 <DigitalKiwi> https://github.com/tweag/nickel
21:12:32 <drakonis> https://github.com/tweag/nickel
21:12:34 <arkanoid> drakonis: I find nix-shell much more convenient than docker environment to make portable/reproducible projects
21:12:34 <drakonis> thre
21:12:35 <drakonis> there
21:12:38 <drakonis> indeed it is
21:12:56 × curiousgay quits (~curiousga@77-120-186-48.kha.volia.net) (Ping timeout: 255 seconds)
21:13:10 <drakonis> however making environments that require package interop can be a pain
21:13:25 <drakonis> i wanted to try ocaml with nix and as it turns out, there are multiple ways to get ocaml to work
21:13:38 <drakonis> each one of them has a specific function you have to invoke in order to generate an environment
21:13:40 × acro quits (~acro@user/acro) (Quit: Bye.)
21:13:40 × ouroboros quits (~ouroboros@user/ouroboros) (Quit: Bye.)
21:13:53 × zeenk quits (~zeenk@2a02:2f04:a008:d600:18f2:3421:bac6:8f38) (Quit: Konversation terminated!)
21:14:30 <drakonis> the way nixpkgs works is that it does not assume you're going to want interop
21:14:41 <DigitalKiwi> [12:36:15] * DigitalKiwi has 4 SML compilers
21:14:41 <DigitalKiwi> [12:36:19] * DigitalKiwi rarely writes SML
21:14:45 <drakonis> lol
21:14:58 <drakonis> let me find the manual, the new website is uhhh
21:15:04 <drakonis> not as good as i originally thought it'd be
21:15:10 <monochrom> haha
21:15:15 <geekosaur> isn't that always true?
21:15:17 <hendursaga> arkanoid: have you tried buildah yet? for containers.
21:15:54 <drakonis> when i was running nixos, i had to turn to running containers, as otherwise i'd have to bang my head against the weird interactions
21:16:19 <drakonis> https://nixos.org/manual/nixpkgs/stable/#chap-language-support refer to this
21:16:34 <arkanoid> hendursaga: yeah, tried buildah, podman and others. I'm generally speaking about containers. Nix gives stronger assumptions, also you can build docker images with nix
21:16:51 <maerwald> I can also build them without nix
21:17:04 <drakonis> we're in a world where languages have to do interop, heck, even nix has to call out to other languages, since it is so limited
21:17:11 acro joins (~acro@user/acro)
21:17:14 Null_A joins (~null_a@2601:645:8700:2290:b1d7:1b8a:64ba:1a81)
21:17:14 <DigitalKiwi> https://christine.website/blog/i-was-wrong-about-nix-2020-02-10
21:17:16 <drakonis> 15.25.2.3.2. Python package using maturin
21:17:22 <drakonis> Python packages that use Maturin can be built with fetchCargoTarball, cargoSetupHook, and maturinBuildHook. For example, the following (partial) derivation builds the retworkx Python package. fetchCargoTarball and cargoSetupHook are used to fetch and set up the crate dependencies. maturinBuildHook is used to perform the build.
21:17:24 <drakonis> see this lol
21:17:53 <DigitalKiwi> maerwald: you can build them better with nix lol
21:18:04 <bryan[m]> Nixpkgs has grown organically and exponentially, and because flakes didn't exist it was all thrown into the same repo to solve the dependency question. Thus multiple ways to package $foolang packages, etc. I think the Nix ecosystem will grow beyond this state of affairs
21:18:05 <hendursaga> arkanoid: you can build Docker images with Guix too, I've done that, it's pretty good
21:18:06 <drakonis> there's python packages with rust deps these days, if you want to build something that requries rust, you need to do hoop jumping
21:18:07 × amahl quits (~amahl@dsl-jklbng12-54fbca-64.dhcp.inet.fi) (Remote host closed the connection)
21:18:11 ouroboros joins (~ouroboros@user/ouroboros)
21:18:21 <maerwald> DigitalKiwi: one of my best decisions was getting rid of nix in a company :p
21:18:23 <drakonis> bryan[m]: it has to grow beyond that quickly
21:18:32 <drakonis> because this is not a good state of affairs
21:18:36 <maerwald> I'd do it again
21:19:07 <bryan[m]> Ok, sure :)
21:19:07 × gentauro quits (~gentauro@user/gentauro) (Read error: Connection reset by peer)
21:19:09 <drakonis> basically, i still cant believe i can install some emacs deps and it'll show on my emacs install
21:19:16 <drakonis> no weird nix-shell magic required
21:19:30 <drakonis> nix-shell is the root of many of my nix issues
21:19:42 <arkanoid> how?
21:19:47 <arkanoid> I'm not following you
21:19:51 <drakonis> i've already said it a dozen times
21:19:58 <arkanoid> sorry :(
21:19:59 <drakonis> half a dozen times, rather.
21:20:07 gentauro joins (~gentauro@user/gentauro)
21:20:09 <arkanoid> joined the discussion late
21:20:12 <drakonis> https://nixos.org/manual/nixpkgs/stable/#chap-language-support check this chapter in the manual
21:20:29 <drakonis> count how many times you have to do something like withpackages
21:20:51 <drakonis> or invoke weird nixlang magic to actually make something work
21:21:06 × mikoto-chan quits (~mikoto-ch@ip-193-121-10-50.dsl.scarlet.be) (Ping timeout: 250 seconds)
21:21:12 <drakonis> the issue here is that you have to use nix-shell nowadays because otherwise things dont work as they should
21:21:16 <arkanoid> I know, I wrote dozen of python derivations for my nix-shells
21:21:41 <drakonis> you're not expected to mix things together with those environments
21:21:53 <drakonis> i don't think this is a very pleasant thing to deal with
21:22:10 <DigitalKiwi> https://github.com/NixOS/nixpkgs/pull/65775/commits this took me several months ;_;
21:22:11 <arkanoid> much better than pip, conda, or docker
21:22:15 <drakonis> certainly
21:22:20 <drakonis> but have you dealt with guix yet?
21:22:29 <arkanoid> no, not yet
21:22:35 <drakonis> the python situation there is as simple as dropping into an environment or installing to the profile
21:22:51 <drakonis> you can run python and it'll work as expected
21:23:14 <drakonis> let me link to a nixcon talk by a nix contributor that used guix for a while
21:23:14 nate3 joins (~nate@108-233-125-227.lightspeed.sntcca.sbcglobal.net)
21:23:36 <arkanoid> drakonis: how are the millions of python packages with their multi-language compiled dependencies handled in guix?
21:24:24 <drakonis> cleanly, really.
21:24:31 <janus> DigitalKiwi: why is Nickel dead in the water? still contributed to by Eelco and Tweag, so seems to have official blessing. and similar to the nix language
21:24:42 <drakonis> janus: you presume people will migrate to it
21:24:49 <janus> doesn't demand a clean break since it allows dynamic typing also
21:24:58 × yoctocell quits (~user@h87-96-130-155.cust.a3fiber.se) (Ping timeout: 240 seconds)
21:24:59 <drakonis> https://guix.gnu.org/manual/en/html_node/Python-Modules.html
21:25:18 <drakonis> Anything that does not fall in the previous categories goes to inputs, for example programs or C libraries required for building Python packages containing C extensions.
21:25:51 <drakonis> if i want to build something with rust, all i need to do is add it to inputs
21:25:52 <janus> drakonis: if Tweag hires a bunch of interns to make a Nickel based Alpine distro, with nickelpkgs full of the some common flakes, many nixpkgs contributors will jump right in
21:25:59 <drakonis> we'll see about that
21:26:12 eggplantade joins (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net)
21:26:17 × kenran quits (~kenran@200116b82bb5e400f1c7c01f9f0a47a0.dip.versatel-1u1.de) (Quit: WeeChat info:version)
21:26:25 <drakonis> https://github.com/pjotrp/guix-notes/blob/master/PYTHON.org
21:26:29 <janus> and written in Rust, can even get all the C++-haters on board
21:26:32 <DigitalKiwi> comments i've seen by people at tweag lol
21:27:25 <drakonis> you once again assume that rust will contribute to it
21:27:38 <arkanoid> drakonis: let's start from the fact that there's no search function on the packages page of the official website :D https://guix.gnu.org/en/packages/
21:27:48 <drakonis> ah yes
21:27:54 <drakonis> but there's on guix-hpc i guess
21:27:56 <drakonis> hold on
21:28:02 <janus> i don't think it will detract from it! so given that nixpkgs "works" as a community, i don't see why there can't be another community around Nickel
21:28:09 <drakonis> https://hpc.guix.info/browse
21:29:01 <bryan[m]> It's almost like... all software has flaws... but often manages to provide value anyway. I feel like I walked into a technology roast in here just now.
21:29:15 <arkanoid> half of the python packages I need are missing. I'm not talking about fringe packages, but important tools used for science by thousands of users.
21:29:49 <drakonis> oh?
21:29:52 <drakonis> do tell though
21:30:05 <drakonis> guix has a decent amount of science users from what i hear
21:30:31 × pera quits (~pera@user/pera) (Ping timeout: 268 seconds)
21:30:35 <janus> guix is the preferred build system of bitcoiners
21:30:40 <janus> religion... even stronger than science
21:30:45 <janus> ;)
21:31:39 <drakonis> ha
21:31:41 <drakonis> idk
21:31:44 <drakonis> i'm not a bitcoiner
21:31:51 <arkanoid> but not enough to cover at least the numfocus affiliated projects https://numfocus.org/sponsored-projects/affiliated-projects
21:32:00 <drakonis> on the other hand, nix has quite a lot of bitcoin adjacent packages
21:32:01 pera joins (~pera@user/pera)
21:32:07 <janus> ok but seriously, one thing i don't understand about guix: people say it is good to use a general purpose programming language. but why? i don't see many mainstream algorithms used in nixpkgs
21:32:23 <janus> so why are they useful in guix? this is _not_ general-purpose computing
21:32:33 <drakonis> janus: because it lets them reuse the code for a variety of tasks
21:32:45 <drakonis> its not a language running on top of a c++ runtime
21:32:45 <bryan[m]> I'm following this email thread about open source foundations, and it's making me realize how long I've been tracking open source stuff as a user or occasional contributor, and how things have changed in that time. I think it's interesting that whether OS lives or dies is now seen as depending on which companies support it and pay people to work on it. I think that's been the case for a long while, but I never really thought about it
21:33:07 <drakonis> arkanoid: maybe it would help if someone packaged them i suppose
21:33:08 <janus> drakonis: python is a language running on top of a C runtime. why does the runtime matter so much?
21:33:16 <drakonis> because its scheme
21:33:26 <drakonis> the ability to reuse code is very much useful
21:33:36 <janus> why can't you reuse a nix function?
21:33:39 <maerwald> bryan[m]: what thread?
21:33:53 <janus> what makes a scheme function more reusable than a nix function?
21:34:04 <drakonis> because nix isn't as capable as a scheme procedure
21:34:17 <drakonis> one moment
21:34:31 <arkanoid> drakonis: so the point stands, AFAIKS the science community that shares my shoes are better served with nix ... still
21:34:33 <bryan[m]> There's an email list ostensibly for members of foundations (Linux Foundation, Apache Foundation, etc etc)
21:34:45 <drakonis> hpc loves guix right now
21:34:51 <davean> janus: My claim earlier was you didn't see such things used in nix because effectively you *couldn't do them in nix*
21:34:55 <davean> not because you didn't want to
21:35:03 <drakonis> ^
21:35:16 <drakonis> its not a matter of not using, its a matter of being unable to.
21:35:39 <drakonis> also, adding new features to nix requires going through the underlying c++ code used to write the package manager
21:35:53 <Hecate> Cale: yes, overlapping instances are terrible
21:36:08 <janus> but it is a system that generates a bunch of calls to a shell, why do you need a large runtime?
21:36:11 <drakonis> also i'm not sure how it is better served by nix when its goals do not align with the science community's
21:36:22 <drakonis> that's the problem lol
21:36:24 <drakonis> calls to a shell
21:36:41 <drakonis> https://hpc.guix.info/blog/2021/05/hpc-reproducible-research-in-guix-1.3.0/
21:36:55 <drakonis> scheme's runtime isnt large, its very minimal btw
21:37:02 <drakonis> it is very powerful however.
21:37:12 <janus> ok but i don't wanna rewrite the build systems of every single package. they are more or less all written in shell
21:37:35 <drakonis> you want to implement something new in guile? you can do it in a very reasonable amount of time and share that across other libraries
21:38:01 <drakonis> the deployment code in guix reuses existing guix library code
21:38:12 <monochrom> Any haskell discussion?
21:38:55 <drakonis> monochrom: c'mon
21:38:56 <drakonis> dont end the fun
21:39:20 <monochrom> Take note that I haven't raised it for, what, hours.
21:39:20 <maerwald> I think it was more of him begging us to talk about haskell
21:39:25 <drakonis> perhaps we should continue on #haskell-offtopic?
21:39:25 × jonathanx quits (~jonathan@h-178-174-176-109.A357.priv.bahnhof.se) (Remote host closed the connection)
21:39:28 <drakonis> idk
21:39:33 <arkanoid> drakonis: yeah, sure, it says to have "upgraded Scipy to 1.6.0", but as you can see from the webpage https://www.scipy.org/ it says "Large parts of the SciPy ecosystem (including all six projects above) are fiscally sponsored by NumFOCUS". Point is that most of the NumFocus projects are still not in guix, so that's "scipy is in guix" is a false statement
21:39:43 jonathanx joins (~jonathan@h-178-174-176-109.A357.priv.bahnhof.se)
21:39:50 <drakonis> uh
21:39:50 <maerwald> #haskell-nix?
21:39:52 <drakonis> but it is on guix
21:40:01 <drakonis> what do you mean scipy isnt
21:40:30 <maerwald> I wish pattern matches were first-class
21:40:42 <arkanoid> I think we're offtopic here, what about continuing somewhere else?
21:40:54 <davean> I support taking over nix channels with chat about improvements over nix
21:41:05 <monochrom> heh
21:41:07 <drakonis> we can take it to #nixos-chat instead
21:41:15 <drakonis> or the guix owned channels, i dont know
21:41:38 <arkanoid> whatever
21:41:41 <monochrom> #haskell-offtopic is a good place on count of "same set of people"
21:41:49 <drakonis> to haskell-ofttopic then
21:41:56 <arkanoid> k
21:44:14 <DigitalKiwi> monochrom: fun hater ;(
21:45:20 × pera quits (~pera@user/pera) (Quit: leaving)
21:45:37 × hgolden quits (~hgolden2@cpe-172-114-84-61.socal.res.rr.com) (Quit: Konversation terminated!)
21:46:25 × slice quits (~slice@user/slice) (Quit: zzz)
21:53:09 × jumper149 quits (~jumper149@80.240.31.34) (Quit: WeeChat 3.2)
21:56:46 merijn joins (~merijn@83-160-49-249.ip.xs4all.nl)
21:59:32 × gehmehgeh quits (~user@user/gehmehgeh) (Quit: Leaving)
22:02:56 curiousgay joins (~curiousga@77-120-186-48.kha.volia.net)
22:09:16 × takuan quits (~takuan@178-116-218-225.access.telenet.be) (Remote host closed the connection)
22:11:53 × dhil quits (~dhil@195.213.192.47) (Ping timeout: 255 seconds)
22:13:28 × tommd quits (~tommd@75-164-130-101.ptld.qwest.net) (Remote host closed the connection)
22:13:49 slice joins (~slice@user/slice)
22:13:54 tommd joins (~tommd@75-164-130-101.ptld.qwest.net)
22:14:13 × Null_A quits (~null_a@2601:645:8700:2290:b1d7:1b8a:64ba:1a81) (Read error: Connection reset by peer)
22:14:46 × burnsidesLlama quits (~burnsides@client-8-87.eduroam.oxuni.org.uk) (Remote host closed the connection)
22:15:02 Null_A joins (~null_a@2601:645:8700:2290:fccc:f134:46b0:cde6)
22:15:58 × __monty__ quits (~toonn@user/toonn) (Quit: leaving)
22:17:36 falafel joins (~falafel@pool-96-255-70-50.washdc.fios.verizon.net)
22:26:38 × Topsi1 quits (~Tobias@dyndsl-095-033-017-171.ewe-ip-backbone.de) (Quit: Leaving.)
22:27:44 × wroathe quits (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Quit: Reconnecting)
22:27:56 wroathe joins (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
22:30:19 × Xnuk quits (~xnuk@vultr.xnu.kr) (Quit: ZNC - https://znc.in)
22:30:36 Xnuk joins (~xnuk@45.76.202.58)
22:31:16 × merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 272 seconds)
22:31:36 fossdd joins (~fossdd@sourcehut/user/fossdd)
22:32:02 dajoer joins (~david@user/gvx)
22:32:07 × eggplantade quits (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Remote host closed the connection)
22:32:46 × wroathe quits (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Ping timeout: 256 seconds)
22:34:35 delYsid joins (~user@84-115-55-45.cable.dynamic.surfer.at)
22:35:14 <delYsid> How do I create "a Handle that writes to /dev/null"?
22:35:37 <geekosaur> openFile "/dev/null" WriteMode
22:35:45 <geekosaur> need to import System.IO
22:35:52 <delYsid> oh
22:36:13 <delYsid> is this portable? (just curious)?
22:36:39 <geekosaur> won't work on windows, no, because windows calls it NUL:
22:37:01 <delYsid> well, I guess vty doesnt work on windows either, so... thanks!
22:42:02 × raehik1 quits (~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) (Ping timeout: 255 seconds)
22:43:07 × Gurkenglas quits (~Gurkengla@dslb-002-203-144-156.002.203.pools.vodafone-ip.de) (Ping timeout: 265 seconds)
22:46:44 × hiruji quits (~hiruji@user/hiruji) (Read error: Connection reset by peer)
22:47:07 hiruji joins (~hiruji@user/hiruji)
22:47:54 × LukeHoersten quits (~LukeHoers@user/lukehoersten) (Ping timeout: 240 seconds)
22:50:02 × Null_A quits (~null_a@2601:645:8700:2290:fccc:f134:46b0:cde6) (Remote host closed the connection)
22:51:35 eggplantade joins (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net)
22:52:13 LukeHoersten joins (~LukeHoers@user/lukehoersten)
22:52:47 × jeetelongname quits (~jeet@host-89-241-98-229.as13285.net) (Ping timeout: 265 seconds)
22:53:26 × curiousgay quits (~curiousga@77-120-186-48.kha.volia.net) (Ping timeout: 258 seconds)
22:54:32 <delYsid> hmm, this doesnt work. System:process says to set std_err to UseHandle devNull where devNull <- openFile "/dev/null" WriteMode? It compiles, but I still see the output to stderr from the subprocess. How is this supposed to be done?
22:55:00 × awth13 quits (~user@user/awth13) (Read error: Connection reset by peer)
22:55:54 <geekosaur> @where paste
22:55:54 <lambdabot> Help us help you: please paste full code, input and/or output at e.g. https://paste.tomsmeding.com
22:56:10 × eggplantade quits (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 265 seconds)
22:58:29 vicfred_ joins (~vicfred@fixed-187-190-192-58.totalplay.net)
22:59:11 <delYsid> ahh, createProcess_ maybe
23:00:23 <delYsid> nah, it ignores me.
23:01:14 × vicfred quits (~vicfred@user/vicfred) (Ping timeout: 252 seconds)
23:01:58 × LukeHoersten quits (~LukeHoers@user/lukehoersten) (Ping timeout: 265 seconds)
23:04:50 lavaman joins (~lavaman@98.38.249.169)
23:05:12 Null_A joins (~null_a@2601:645:8700:2290:fccc:f134:46b0:cde6)
23:05:48 <hpc> do you just want to suppress stderr on a subprocess?
23:05:59 <koz> Anyone familiar with freer-simple (or its methods in general) - any chance you know how to solve my issue? https://github.com/lexi-lambda/freer-simple/issues/33
23:06:12 <hpc> you can let it give you the handle to stderr and just not read from it
23:06:51 × nate3 quits (~nate@108-233-125-227.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 258 seconds)
23:07:21 <geekosaur> well, as long as it doesn't overflow the pipe
23:07:26 nate3 joins (~nate@108-233-125-227.lightspeed.sntcca.sbcglobal.net)
23:07:50 <hpc> ah right
23:09:06 × lavaman quits (~lavaman@98.38.249.169) (Ping timeout: 240 seconds)
23:09:42 <geekosaur> also /dev/null worked for me here
23:09:55 <geekosaur> which is why I asked for a paste of what you're doing
23:10:06 × mnrmnaugh quits (~mnrmnaugh@pool-96-252-87-182.bstnma.fios.verizon.net) (Quit: Leaving)
23:12:19 <delYsid> geekosaur: https://blind.guru/UCI.hs function start'
23:14:26 LukeHoersten joins (~LukeHoers@user/lukehoersten)
23:18:33 <delYsid> I guess I can only just write the draining code, but it looks like this should actually work.
23:18:48 <delYsid> s/only/also/
23:19:21 ph88 joins (~ph88@2a02:8109:9e00:7e5c:8db8:987d:36eb:f1a6)
23:20:55 <hpc> ugh, it has a download-y content-disposition
23:21:23 <hpc> oh
23:21:42 <hpc> in your createProcess_ you aren't putting it into the process properties thingy
23:21:56 <hpc> you just have (proc cmd args)
23:22:07 <hpc> (
23:22:09 <hpc> er
23:22:44 <hpc> you want (proc cmd args {std_err = UseHandle devNull})
23:22:52 × LukeHoersten quits (~LukeHoers@user/lukehoersten) (Ping timeout: 250 seconds)
23:23:19 <hpc> or maybe outside the parens
23:23:30 <hpc> there's an example on https://hackage.haskell.org/package/process-1.6.12.0/docs/System-Process.html#v:createProcess for std_out
23:23:58 <hpc> ... i just saw the open squiggly brace
23:24:01 hpc dies of embarassment
23:24:20 × acidjnk quits (~acidjnk@p200300d0c72b9549b83720658b9c4b74.dip0.t-ipconnect.de) (Ping timeout: 252 seconds)
23:25:09 <delYsid> I think I do the record update right :-)
23:25:36 curiousgay joins (~curiousga@77-120-186-48.kha.volia.net)
23:25:59 × ikex quits (ash@user/ikex) (Quit: ZNC - https://znc.in)
23:26:07 <hpc> yeah, that code looks like it should work
23:26:12 × jao quits (~jao@cpc103048-sgyl39-2-0-cust502.18-2.cable.virginm.net) (Remote host closed the connection)
23:26:13 ikex joins (ash@user/ikex)
23:26:53 <delYsid> It compiles, but laughs at me when I run it. So much about "it builds, so ship it!"
23:29:32 wroathe joins (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
23:30:11 pesada joins (~agua@2804:18:4f:4b5e:1:0:5480:48f9)
23:31:46 fawful joins (~guy@c-76-104-217-93.hsd1.wa.comcast.net)
23:31:58 × nate3 quits (~nate@108-233-125-227.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 250 seconds)
23:32:11 <delYsid> gah, never mind, I am an idiot.
23:32:27 <delYsid> sorry for wasting your time <facepalm>
23:32:31 <hpc> what was it?
23:32:48 <hpc> testing the wrong code?
23:32:50 × agua quits (~agua@191.177.175.57) (Ping timeout: 256 seconds)
23:32:54 × vicfred_ quits (~vicfred@fixed-187-190-192-58.totalplay.net) (Ping timeout: 265 seconds)
23:33:17 <delYsid> I was remembering the external processes behaviour wrongly. It writes its banner to stdout actually...
23:33:25 <hpc> hah
23:33:49 <hpc> i hate when that sort of thing happens
23:36:58 jao joins (~jao@cpc103048-sgyl39-2-0-cust502.18-2.cable.virginm.net)
23:37:32 <delYsid> Today lesson: Trust your compiler!
23:37:40 <eltonpinto> yee
23:37:52 × Null_A quits (~null_a@2601:645:8700:2290:fccc:f134:46b0:cde6) (Remote host closed the connection)
23:40:02 × Tuplanolla quits (~Tuplanoll@91-159-68-239.elisa-laajakaista.fi) (Quit: Leaving.)
23:40:59 × ph88 quits (~ph88@2a02:8109:9e00:7e5c:8db8:987d:36eb:f1a6) (Ping timeout: 255 seconds)
23:42:18 nate3 joins (~nate@108-233-125-227.lightspeed.sntcca.sbcglobal.net)
23:42:36 × Vajb quits (~Vajb@hag-jnsbng11-58c3a1-224.dhcp.inet.fi) (Remote host closed the connection)
23:43:16 betelgeuse joins (~john2gb@94-225-47-8.access.telenet.be)
23:43:23 <delYsid> silence = const $ pure ()
23:43:34 <delYsid> gnight :-)
23:44:18 Null_A joins (~null_a@2601:645:8700:2290:fccc:f134:46b0:cde6)
23:45:23 Vajb joins (~Vajb@hag-jnsbng11-58c3a1-224.dhcp.inet.fi)
23:46:53 × nate3 quits (~nate@108-233-125-227.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 252 seconds)
23:46:59 × jushur quits (~human@user/jushur) (Quit: ¯\_(ツ)_/¯)
23:48:47 × hexfive quits (~eric@50.35.83.177) (Quit: WeeChat 3.0)
23:49:22 vsiddharth joins (~user@23.252.50.92)
23:51:12 <vsiddharth> Hi everyone! I'm trying to use Alternative with Maybe, but in the instance that both values are Just, then I apply a function. Right now I have `liftA2 f a b <|> a <|> b`. Is there a more obvious way of doing this?
23:52:41 × hiruji quits (~hiruji@user/hiruji) (Ping timeout: 255 seconds)
23:55:21 eggplantade joins (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net)
23:55:22 <hpc> (f <$> a <*> b) <|> a <|> b, if you just want syntactic regularity
23:55:44 <hpc> but that seems perfectly fine to me, i would stop golfing it there if i was writing it
23:55:46 × shapr quits (~user@pool-100-36-247-68.washdc.fios.verizon.net) (Ping timeout: 240 seconds)
23:55:57 <vsiddharth> Thanks hpc!
23:56:21 nate3 joins (~nate@108-233-125-227.lightspeed.sntcca.sbcglobal.net)
23:58:09 <monochrom> Perhaps you also like: https://hackage.haskell.org/package/these
23:58:22 hiruji joins (~hiruji@user/hiruji)
23:58:44 × hololeap quits (~hololeap@user/hololeap) (Quit: Bye)
23:58:51 <arkanoid> out of curiosity, what's the haskell feature that required most phd brain power? "deriving" seems magic to me
23:59:40 <monochrom> The Haskell 2010 Report details what deriving does. It's highly mechanical and boring.
23:59:48 <arkanoid> oh :(
23:59:58 <arkanoid> well, wrong guess

All times are in UTC on 2021-07-25.