Home liberachat/#haskell: Logs Calendar

Logs on 2023-09-22 (liberachat/#haskell)

00:00:01 × emmanuelux quits (~emmanuelu@user/emmanuelux) (Ping timeout: 255 seconds)
00:01:06 × Lord_of_Life quits (~Lord@user/lord-of-life/x-2819915) (Ping timeout: 258 seconds)
00:02:04 Lord_of_Life joins (~Lord@user/lord-of-life/x-2819915)
00:02:17 × califax quits (~califax@user/califx) (Remote host closed the connection)
00:02:22 hyiltiz joins (~hyiltiz@2620:149:13d1::5a2)
00:03:19 × waleee quits (~waleee@2001:9b0:21c:4000:5bf9:6515:c030:57b7) (Ping timeout: 264 seconds)
00:04:15 × xff0x quits (~xff0x@178.255.149.135) (Ping timeout: 240 seconds)
00:05:22 × emmanuelux_ quits (~emmanuelu@user/emmanuelux) (Ping timeout: 244 seconds)
00:05:58 × deriamis quits (deriamis@2600:1f14:1251:ba02:2994:f9dc:75a8:113b) (Quit: ZNC - https://znc.in)
00:06:14 xff0x joins (~xff0x@2405:6580:b080:900:7a46:13e1:bddb:2397)
00:06:35 × hyiltiz quits (~hyiltiz@2620:149:13d1::5a2) (Ping timeout: 240 seconds)
00:07:05 hyiltiz joins (~hyiltiz@2620:149:13d1::5a2)
00:07:19 deriamis joins (deriamis@2600:1f14:1251:ba02:2994:f9dc:75a8:113b)
00:08:39 × Alex_test quits (~al_test@178.34.160.78) (Ping timeout: 240 seconds)
00:10:39 × AlexZenon quits (~alzenon@178.34.160.78) (Ping timeout: 240 seconds)
00:11:49 × hyiltiz quits (~hyiltiz@2620:149:13d1::5a2) (Ping timeout: 258 seconds)
00:13:21 califax joins (~califax@user/califx)
00:13:59 × remedan quits (~remedan@ip-94-112-0-18.bb.vodafone.cz) (Ping timeout: 246 seconds)
00:15:50 hyiltiz joins (~hyiltiz@2620:149:13d1::5a2)
00:16:56 × g quits (g@libera/staff/glguy) (Remote host closed the connection)
00:17:00 g joins (g@libera/staff/glguy)
00:17:33 remedan joins (~remedan@ip-94-112-0-18.bb.vodafone.cz)
00:18:40 Alex_test joins (~al_test@178.34.160.78)
00:20:18 AlexZenon joins (~alzenon@178.34.160.78)
00:23:51 × wroathe quits (~wroathe@user/wroathe) (Ping timeout: 240 seconds)
00:26:43 × hyiltiz quits (~hyiltiz@2620:149:13d1::5a2) (Ping timeout: 264 seconds)
00:33:53 yosef` joins (~yosef`@user/yosef/x-2947716)
00:35:41 hyiltiz joins (~hyiltiz@2620:149:13d1::5a2)
00:37:50 × Unicorn_Princess quits (~Unicorn_P@user/Unicorn-Princess/x-3540542) (Remote host closed the connection)
00:38:32 × machinedgod quits (~machinedg@d198-53-218-113.abhsia.telus.net) (Ping timeout: 260 seconds)
00:40:25 × tremon quits (~tremon@83.80.159.219) (Quit: getting boxed in)
00:40:27 Square3 joins (~Square4@user/square)
00:43:12 × hyiltiz quits (~hyiltiz@2620:149:13d1::5a2) (Ping timeout: 260 seconds)
00:47:16 hyiltiz joins (~hyiltiz@2620:149:13d1::5a2)
00:58:31 × hyiltiz quits (~hyiltiz@2620:149:13d1::5a2) (Ping timeout: 264 seconds)
00:58:33 bienjensu joins (~user@user/bienjensu)
00:59:45 shapr joins (~user@2600:1700:c640:3100:cd69:69ab:9143:deea)
01:02:47 hyiltiz joins (~hyiltiz@2620:149:13d1::5a2)
01:09:42 × dagit quits (~dagit@2001:558:6025:38:71c6:9d58:7252:8976) (Ping timeout: 258 seconds)
01:10:08 dagit joins (~dagit@2001:558:6025:38:71c6:9d58:7252:8976)
01:12:00 × libertyprime quits (~libertypr@203.96.203.44) (Ping timeout: 258 seconds)
01:13:00 merijn joins (~merijn@088-129-128-083.dynamic.caiway.nl)
01:16:09 × bienjensu quits (~user@user/bienjensu) (Ping timeout: 244 seconds)
01:17:43 × merijn quits (~merijn@088-129-128-083.dynamic.caiway.nl) (Ping timeout: 264 seconds)
01:18:54 <albet70> what's the difference between State and ST?
01:19:58 <geekosaur> uh? they're very different
01:20:41 <geekosaur> ST has a "state" but it's phantom, and that's the point: it's untouchable, so you can hide impure data by associating it with the untouchable state so it can never escape ST
01:21:36 bilegeek joins (~bilegeek@2600:1008:b08d:e679:af4d:681:cfe8:969c)
01:21:40 <geekosaur> so now you can have mutable variables (STRef) and mutable arrays (STArray/STUArray), and can write mutating code as long as what you finally return is pure
01:22:26 <c_wraith> State is a convenience wrapper for a pattern you can write by hand.
01:22:45 <c_wraith> ST provides a unique interface that allows you to use true mutability in an externally-pure interface
01:23:35 × vulpine quits (xfnw@tilde.team) (Quit: Connection reset by purr)
01:30:53 <dmj`> is valderman around ?
01:31:30 powderhorn joins (~powderhor@207-153-12-54.static.fttp.usinternet.com)
01:38:56 vulpine joins (xfnw@tilde.team)
01:45:19 × otto_s quits (~user@p5b044509.dip0.t-ipconnect.de) (Ping timeout: 264 seconds)
01:46:46 wroathe joins (~wroathe@207-153-38-140.fttp.usinternet.com)
01:46:47 × wroathe quits (~wroathe@207-153-38-140.fttp.usinternet.com) (Changing host)
01:46:47 wroathe joins (~wroathe@user/wroathe)
01:46:54 otto_s joins (~user@p4ff27dc1.dip0.t-ipconnect.de)
01:47:43 libertyprime joins (~libertypr@203.96.203.44)
01:58:09 × eggplantade quits (~Eggplanta@2600:1700:38c5:d800:182a:8598:da7e:1049) (Remote host closed the connection)
01:58:25 eggplantade joins (~Eggplanta@2600:1700:38c5:d800:182a:8598:da7e:1049)
01:59:55 × hyiltiz quits (~hyiltiz@2620:149:13d1::5a2) (Ping timeout: 258 seconds)
02:01:45 hyiltiz joins (~hyiltiz@2603-8080-1f00-082f-15d9-d49d-e7d8-6241.res6.spectrum.com)
02:03:28 × yosef` quits (~yosef`@user/yosef/x-2947716) (Ping timeout: 245 seconds)
02:07:35 × xff0x quits (~xff0x@2405:6580:b080:900:7a46:13e1:bddb:2397) (Ping timeout: 240 seconds)
02:07:55 <albet70> what's the relationship of STRef and ST?
02:09:23 <glguy> STRef : ST :: IORef : IO
02:09:36 <glguy> do you know the relationship between IORef and IO?
02:09:43 <albet70> no
02:10:25 <glguy> OK, then don't worry about ST and STRef yet. Are you familiar with the IO type yet?
02:10:34 <albet70> yes
02:11:07 <glguy> IORefs are mutable references. You can make a new one: newIORef :: a -> IO a
02:11:17 <glguy> You can read what's stored in one: readIORef :: IORef a -> IO a
02:11:40 <glguy> and you can store something in one: writeIORef :: IORef a -> a -> IO ()
02:11:52 <glguy> What you get back when you read from one is the last thing you wrote to it
02:12:00 <glguy> (or the initial value you provided with newIORef
02:12:24 <albet70> IORef can construct an IO a?
02:12:45 <glguy> err
02:12:46 <albet70> but 2 :: IO Int is ok?
02:12:51 <glguy> newIORef :: a -> IO (IORef a)
02:13:59 <monochrom> I don't know what "IORef can construct an IO a?" means. But you can use IORef in IO. (And STRef in ST.)
02:16:24 × td_ quits (~td@i5387091A.versanet.de) (Ping timeout: 258 seconds)
02:17:28 nate2 joins (~nate@c-98-45-169-16.hsd1.ca.comcast.net)
02:18:05 td_ joins (~td@i5387090B.versanet.de)
02:23:07 × nate2 quits (~nate@c-98-45-169-16.hsd1.ca.comcast.net) (Ping timeout: 264 seconds)
02:24:22 finn_elija joins (~finn_elij@user/finn-elija/x-0085643)
02:24:23 × FinnElija quits (~finn_elij@user/finn-elija/x-0085643) (Killed (NickServ (Forcing logout FinnElija -> finn_elija)))
02:24:23 finn_elija is now known as FinnElija
02:26:40 <dmj`> albet70: if you're trying to implement mutable algorithms in ST, use an Int accumulator before an STRef Int, faster
02:37:07 × hpc quits (~juzz@ip98-169-35-163.dc.dc.cox.net) (Ping timeout: 258 seconds)
02:37:20 hpc joins (~juzz@ip98-169-35-163.dc.dc.cox.net)
02:53:40 × qqq quits (~qqq@92.43.167.61) (Quit: leaving)
02:57:00 xff0x joins (~xff0x@125x103x176x34.ap125.ftth.ucom.ne.jp)
02:57:55 × mysl quits (~mysl@user/mysl) (Ping timeout: 252 seconds)
02:59:30 mysl joins (~mysl@user/mysl)
03:00:51 merijn joins (~merijn@088-129-128-083.dynamic.caiway.nl)
03:08:34 × [itchyjunk] quits (~itchyjunk@user/itchyjunk/x-7353470) (Remote host closed the connection)
03:16:41 Inst joins (~Inst@120.244.192.250)
03:20:47 <Inst> danse-nr3: remember ICQ?
03:25:19 <monochrom> I remember that.
03:27:37 <int-e> . o O ( bad AIM )
03:30:16 lisbeths joins (uid135845@id-135845.lymington.irccloud.com)
03:32:26 <EvanR> you were only cool if you were on Jabber
03:35:17 × merijn quits (~merijn@088-129-128-083.dynamic.caiway.nl) (Ping timeout: 260 seconds)
03:36:10 × wroathe quits (~wroathe@user/wroathe) (Ping timeout: 244 seconds)
03:41:55 × azimut quits (~azimut@gateway/tor-sasl/azimut) (Ping timeout: 252 seconds)
03:53:02 <jackdk> I remember writing and IRC<->jabber bot to ping my friends when someone wanted to challenge us to games
03:53:37 <jackdk> the jabber side of the bot had my friends' MSN etc contacts imported via bridge. Amazing that we'd basically solved instant messaging in the 2000s and then decided to break it all again.
03:55:17 × ystael quits (~ystael@user/ystael) (Ping timeout: 244 seconds)
03:56:19 aforemny_ joins (~aforemny@2001:9e8:6cd8:8a00:99a8:9435:f04:65fe)
03:56:50 × aforemny quits (~aforemny@i59F516F1.versanet.de) (Ping timeout: 244 seconds)
04:07:04 _ht joins (~Thunderbi@28-52-174-82.ftth.glasoperator.nl)
04:09:25 wroathe joins (~wroathe@207-153-38-140.fttp.usinternet.com)
04:09:25 × wroathe quits (~wroathe@207-153-38-140.fttp.usinternet.com) (Changing host)
04:09:25 wroathe joins (~wroathe@user/wroathe)
04:10:32 × sabino quits (~sabino@user/sabino) (Quit: Lambda _ -> x)
04:15:37 jargon joins (~jargon@184.101.67.95)
04:23:53 × chexum quits (~quassel@gateway/tor-sasl/chexum) (Remote host closed the connection)
04:24:06 chexum joins (~quassel@gateway/tor-sasl/chexum)
04:24:39 vglfr joins (~vglfr@188.239.201.89)
04:27:03 khumba joins (~khumba@user/khumba)
04:36:35 michalz joins (~michalz@185.246.207.197)
04:38:43 × wroathe quits (~wroathe@user/wroathe) (Ping timeout: 264 seconds)
04:40:14 misterfish joins (~misterfis@84-53-85-146.bbserv.nl)
04:40:41 × vglfr quits (~vglfr@188.239.201.89) (Remote host closed the connection)
04:41:05 × dcoutts_ quits (~duncan@2a02:8012:ae9a:0:217c:5666:d075:6292) (Ping timeout: 240 seconds)
04:41:43 vglfr joins (~vglfr@188.239.201.89)
04:42:00 × vglfr quits (~vglfr@188.239.201.89) (Remote host closed the connection)
04:45:17 vglfr joins (~vglfr@cli-188-239-201-89.bbn.slav.dn.ua)
04:51:54 merijn joins (~merijn@088-129-128-083.dynamic.caiway.nl)
05:03:49 acidjnk_new joins (~acidjnk@p200300d6e7072f380063779f7ab954b0.dip0.t-ipconnect.de)
05:03:55 × Inst quits (~Inst@120.244.192.250) (Ping timeout: 258 seconds)
05:10:42 Inst joins (~Inst@120.244.192.250)
05:10:56 <Inst> jackdk: monetization
05:11:27 <Inst> end of the day, labor -> trading off a bit of your life for value, opportunity costs -> what else you could be doing with your time
05:11:42 <Inst> I wish, say, EU, US, Chinese, any one of the three, were subsidizing FOSS development
05:12:51 <Inst> would tremendously increase efficiency and productivity in the field, because end of the day, FOSS is a public good, and governments should be taking care of public goods
05:17:43 idgaen joins (~idgaen@2a01:e0a:498:fd50:fcc6:bb5d:489a:ce8c)
05:22:38 takuan joins (~takuan@178-116-218-225.access.telenet.be)
05:24:41 × takuan quits (~takuan@178-116-218-225.access.telenet.be) (Read error: Connection reset by peer)
05:25:25 takuan joins (~takuan@178-116-218-225.access.telenet.be)
05:26:13 × merijn quits (~merijn@088-129-128-083.dynamic.caiway.nl) (Ping timeout: 244 seconds)
05:29:06 × stiell_ quits (~stiell@gateway/tor-sasl/stiell) (Remote host closed the connection)
05:29:48 stiell_ joins (~stiell@gateway/tor-sasl/stiell)
05:29:54 × monochrom quits (~trebla@216.138.220.146) (Quit: Leaving)
05:31:51 monochrom joins (~trebla@216.138.220.146)
05:32:23 sm joins (~sm@plaintextaccounting/sm)
05:33:57 × monochrom quits (~trebla@216.138.220.146) (Client Quit)
05:36:44 × sm quits (~sm@plaintextaccounting/sm) (Ping timeout: 245 seconds)
05:37:40 <phma> I'm writing the same program in both Rust and Haskell and timing how long it takes to run.
05:38:23 × _ht quits (~Thunderbi@28-52-174-82.ftth.glasoperator.nl) (Quit: _ht)
05:38:44 CiaoSen joins (~Jura@2a05:5800:29e:d200:664b:f0ff:fe37:9ef)
05:39:04 <phma> Compiled with -O2 -fllvm, the Haskell program takes 12.3 s real, 18.1 s user (it's multithreaded), to hash a megabyte.
05:39:51 × lisbeths quits (uid135845@id-135845.lymington.irccloud.com) (Quit: Connection closed for inactivity)
05:40:02 <phma> The Rust program, which is not multithreaded, takes 8.8 s to do the same thing. That's compiled in debug mode.
05:41:11 <phma> So far, Haskell taking half again as long as Rust isn't bad. But then I compiled the Rust program in release mode
05:41:25 <phma> and it took only half a second to hash a megabyte.
05:42:13 <phma> That means it's spending over eight seconds checking bounds and such.
05:43:03 × powderhorn quits (~powderhor@207-153-12-54.static.fttp.usinternet.com) (Ping timeout: 245 seconds)
05:43:19 <phma> The Haskell program spends most of its time manipulating unboxed arrays. Is it possible to disable bounds checking and such,
05:43:22 <int-e> Hmmmm was that https://github.com/phma/wring-twistree/ ?
05:43:35 <phma> int-e: yes
05:43:58 <phma> without using unsafe functions?
05:47:30 <int-e> no, the bounds checks are just plain Haskell code, not guarded by any compiler flag
05:48:12 <phma> How much speedup would I get by switching to unboxed vectors?
05:49:09 <int-e> only one way to find out
05:53:36 × khumba quits (~khumba@user/khumba) ()
05:55:17 × misterfish quits (~misterfis@84-53-85-146.bbserv.nl) (Ping timeout: 260 seconds)
05:58:09 × ddellacosta quits (~ddellacos@ool-44c738de.dyn.optonline.net) (Ping timeout: 252 seconds)
06:02:21 × FinnElija quits (~finn_elij@user/finn-elija/x-0085643) (Ping timeout: 252 seconds)
06:02:47 FinnElija joins (~finn_elij@user/finn-elija/x-0085643)
06:03:57 dsrt^ joins (~cd@c-66-56-7-24.hsd1.ga.comcast.net)
06:04:33 × idgaen quits (~idgaen@2a01:e0a:498:fd50:fcc6:bb5d:489a:ce8c) (Quit: WeeChat 4.0.2)
06:07:20 merijn joins (~merijn@088-129-128-083.dynamic.caiway.nl)
06:13:05 × merijn quits (~merijn@088-129-128-083.dynamic.caiway.nl) (Ping timeout: 246 seconds)
06:14:43 × notzmv quits (~zmv@user/notzmv) (Ping timeout: 264 seconds)
06:19:13 nate2 joins (~nate@c-98-45-169-16.hsd1.ca.comcast.net)
06:19:14 × vglfr quits (~vglfr@cli-188-239-201-89.bbn.slav.dn.ua) (Read error: Connection reset by peer)
06:19:36 vglfr joins (vglfr@gateway/vpn/protonvpn/vglfr)
06:24:02 × nate2 quits (~nate@c-98-45-169-16.hsd1.ca.comcast.net) (Ping timeout: 258 seconds)
06:24:51 yosef` joins (~yosef`@user/yosef/x-2947716)
06:25:49 jackneill__ joins (~Jackneill@20014C4E1E062E0011575DEE5212F0F8.dsl.pool.telekom.hu)
06:29:41 lortabac joins (~lortabac@2a01:e0a:541:b8f0:882f:270a:9fdd:8778)
06:29:44 notzmv joins (~zmv@user/notzmv)
06:38:55 × tv quits (~tv@user/tv) (Read error: Connection reset by peer)
06:39:06 merijn joins (~merijn@088-129-128-083.dynamic.caiway.nl)
06:40:44 × vglfr quits (vglfr@gateway/vpn/protonvpn/vglfr) (Ping timeout: 246 seconds)
06:40:50 <phma> Does profiling with -hc, -hy, or the like work properly on multithreaded programs?
06:41:45 sm joins (~sm@plaintextaccounting/sm)
06:42:18 Teestt3434 joins (~User@2001:1970:5199:fa00::a4bf)
06:43:20 vglfr joins (~vglfr@cli-188-239-201-89.bbn.slav.dn.ua)
06:46:05 akegalj joins (~akegalj@93-142-180-5.adsl.net.t-com.hr)
06:46:28 × FinnElija quits (~finn_elij@user/finn-elija/x-0085643) (Remote host closed the connection)
06:46:50 FinnElija joins (~finn_elij@user/finn-elija/x-0085643)
06:47:02 × smoothdev quits (~smoothdev@91-169-231-236.subs.proxad.net) (Ping timeout: 258 seconds)
06:50:34 <Inst> https://downloads.haskell.org/ghc/8.8.1-alpha1/docs/html/libraries/Cabal-2.5.0.0/Distribution-Simple-Flag.html
06:50:36 <Inst> what's going on here?
06:50:55 <Inst> AFAIK, it's a custom Maybe type with Just being on the 0 index, and different monoid / semigroup instances
06:51:08 × ChaiTRex quits (~ChaiTRex@user/chaitrex) (Remote host closed the connection)
06:51:31 ChaiTRex joins (~ChaiTRex@user/chaitrex)
06:52:24 smoothdev joins (~smoothdev@2a01:e0a:279:fb20:6dba:5cf9:a0d3:5827)
06:56:47 × akegalj quits (~akegalj@93-142-180-5.adsl.net.t-com.hr) (Ping timeout: 255 seconds)
06:56:54 akegalj_ joins (~akegalj@93-142-166-66.adsl.net.t-com.hr)
06:57:41 × sm quits (~sm@plaintextaccounting/sm) (Ping timeout: 255 seconds)
07:04:59 dove_ is now known as dove
07:05:17 × FinnElija quits (~finn_elij@user/finn-elija/x-0085643) (Remote host closed the connection)
07:06:21 smoothdev_ joins (~smoothdev@91-169-231-236.subs.proxad.net)
07:06:58 × smoothdev quits (~smoothdev@2a01:e0a:279:fb20:6dba:5cf9:a0d3:5827) (Ping timeout: 258 seconds)
07:06:59 smoothdev_ is now known as smoothdev
07:09:33 FinnElija joins (~finn_elij@user/finn-elija/x-0085643)
07:10:39 tromp joins (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
07:11:27 × tcard quits (~tcard@2400:4051:5801:7500:cf17:befc:ff82:5303) (Quit: Leaving)
07:11:59 aforemny_ is now known as aforemny
07:13:25 tcard joins (~tcard@2400:4051:5801:7500:cf17:befc:ff82:5303)
07:17:37 × Inst quits (~Inst@120.244.192.250) (Remote host closed the connection)
07:18:02 Inst joins (~Inst@120.244.192.250)
07:18:12 × dsrt^ quits (~cd@c-66-56-7-24.hsd1.ga.comcast.net) (Remote host closed the connection)
07:20:10 random-jellyfish joins (~random-je@user/random-jellyfish)
07:21:40 fendor joins (~fendor@2a02:8388:1640:be00:aab:1226:f274:5021)
07:24:21 <jackdk> The link at the top of the haddocks is still live: https://mail.haskell.org/pipermail/cabal-devel/2007-December/001509.html
07:25:33 sord937 joins (~sord937@gateway/tor-sasl/sord937)
07:30:12 arahael joins (~arahael@119-18-1-27.771201.syd.nbn.aussiebb.net)
07:33:07 mc47 joins (~mc47@xmonad/TheMC47)
07:34:34 coot joins (~coot@89-69-206-216.dynamic.chello.pl)
07:38:05 × tzh quits (~tzh@c-71-193-181-0.hsd1.or.comcast.net) (Quit: zzz)
07:38:26 sm joins (~sm@plaintextaccounting/sm)
07:42:39 × merijn quits (~merijn@088-129-128-083.dynamic.caiway.nl) (Ping timeout: 240 seconds)
07:45:02 gmg joins (~user@user/gehmehgeh)
07:46:01 <Inst> just a question, what is the value of foldr?
07:46:13 <Inst> I mean, I know how foldr is implemented for lists, I can probably grok how it's implemented via foldable
07:46:27 <Inst> but it's what I'd consider way too powerful
07:47:05 <Inst> is it wrong to consider it equivalent to for, or even while?
07:47:28 <Inst> (then again, all recursion can be expressed as while + some complexities)
07:48:22 × Vajb quits (~Vajb@2001:999:500:7771:18aa:c4e5:e7a9:f44b) (Read error: Connection reset by peer)
07:49:07 cfricke joins (~cfricke@user/cfricke)
07:49:10 Vajb joins (~Vajb@2001:999:500:7771:18aa:c4e5:e7a9:f44b)
07:50:52 danza joins (~francesco@rm-19-27-218.service.infuturo.it)
07:54:50 <lortabac> Inst: foldr gives you an easy way to iterate on a structure and accumulate a result in a right-associative way
07:55:43 <Inst> on lists, at least, foldr's inefficient and for most uses foldl' is better
07:55:57 <Inst> i'm aware that foldr has an advantage insofar as it's usefully lazy on lists
07:56:01 <lortabac> it's true that with 'foldr' you can theoretically do much more, but in practice it's too complex to be done for real
07:56:19 <lortabac> Inst: there is no better and worse, foldl and foldr do different things
07:58:39 <Inst> i think there's an implementation of foldl' in prelude using foldr as a continuation builder
07:59:05 <jackdk> foldr performs constructor replacement. http://web.archive.org/web/20230103210800/data.tmorris.net/talks/list-folds/b30aa0fdff296c731bc5b1c824adf1d02b3b69d9/list-folds.pdf
07:59:56 × Teestt3434 quits (~User@2001:1970:5199:fa00::a4bf) (Quit: Leaving)
08:00:28 <Inst> yeah, in that case foldr is better, since it can exploit laziness
08:00:37 <Inst> foldl' i tend to default toward for performance reasons
08:00:56 <Inst> i'd guessing with Hughes Lists / Diff Lists foldl' is likely to be more inefficient, though
08:01:08 machinedgod joins (~machinedg@d198-53-218-113.abhsia.telus.net)
08:01:45 <lortabac> imagine you are implementing a compiler, and you need to convert all multi-argument lambdas in curried one-argument ones
08:02:12 <lortabac> you would use foldr since Lam is right-associative
08:02:31 <lortabac> now if you want to do the same thing for function application
08:02:39 <lortabac> you would use foldl since it's left-associative
08:03:08 × eggplantade quits (~Eggplanta@2600:1700:38c5:d800:182a:8598:da7e:1049) (Remote host closed the connection)
08:04:38 <Inst> yeah and I'd assume I'd have Foldable instances for Lam for this purpose, no?
08:04:46 <lortabac> no
08:04:59 <lortabac> you fold over the arguments of the lambda
08:05:10 <Inst> I guess I'm just thinking operationally
08:05:11 <lortabac> foldr Lam arguments body
08:05:39 <lortabac> foldl App arguments function
08:06:13 <lortabac> sorry I inverted the last two arguments
08:06:21 <lortabac> but I hope you get the idea
08:06:28 <Inst> and, I'm guessing, on Vector, at least, foldr' and foldl' are essentially identical when it comes to performance characteristics, except that foldl' would have to get the vector length first?
08:08:36 × Sgeo quits (~Sgeo@user/sgeo) (Read error: Connection reset by peer)
08:08:36 × gentauro quits (~gentauro@user/gentauro) (Read error: Connection reset by peer)
08:13:48 tv joins (~tv@user/tv)
08:13:59 × bilegeek quits (~bilegeek@2600:1008:b08d:e679:af4d:681:cfe8:969c) (Quit: Leaving)
08:14:02 gentauro joins (~gentauro@user/gentauro)
08:16:12 mfg joins (~user@128.176.164.115)
08:18:12 × Square3 quits (~Square4@user/square) (Ping timeout: 260 seconds)
08:20:03 × danza quits (~francesco@rm-19-27-218.service.infuturo.it) (Ping timeout: 252 seconds)
08:20:46 <mfg> Hi, i'm using bench (a wrapper around criterion) to benchmark some command line applications and was wondering what is the minimum amount of actual program runs this performs, if this is configurable and how exactly is determined how many runs are actually done.
08:24:15 <Inst> tbh do I have the wrong concept of foldr / foldl @lortabac?
08:24:44 <Inst> i.e, I'm thinking of them specifically in the sense of how they interact with a value of type [a], not in the core semantics (right to left fold, left to right fold)
08:25:45 <lortabac> Inst: the difference is not in how they interact with the list, it's in how they accumulate the value
08:26:09 <Inst> i mean i know the definition, foldr with lists replaces the cons data constructor with the function
08:26:24 <Inst> the accumulation, unless you're doing an outside accumulation via continuation building
08:27:26 <Inst> but i get the feeling i'd be better off reading jack dk (avoid highlighting)'s link for more information on that
08:27:54 × ft quits (~ft@p3e9bc680.dip0.t-ipconnect.de) (Quit: leaving)
08:29:20 chele joins (~chele@user/chele)
08:29:22 <lortabac> > foldl (+) 0 [x, y, z]
08:29:24 <lambdabot> 0 + x + y + z
08:29:27 × myme quits (~myme@2a01:799:d60:e400:e336:7d0f:f75f:76b1) (Ping timeout: 240 seconds)
08:29:40 <lortabac> (+) is left-associative so the parentheses are omitted
08:30:00 <lortabac> but this would be ((0 + x) + y) + z
08:30:11 <lortabac> > foldr (+) 0 [x, y, z]
08:30:13 <lambdabot> x + (y + (z + 0))
08:30:21 <lortabac> Inst: ↑
08:30:33 myme joins (~myme@2a01:799:d60:e400:2874:313d:614e:da9)
08:31:37 <probie> > foldr (\n k acc -> k (acc + n)) id [x, y, z] 0
08:31:39 <lambdabot> 0 + x + y + z
08:32:24 <Inst> yeah, i think we have like a miscommunication, I'm familiar with the semantics of foldr and foldl, my issue is more that I've asserted that foldr is equivalent to for or while in the past, i.e, foldr with its short-circuiting capability being able to implement any algorithm, is a bit smelly
08:32:34 <Inst> whereas foldl' is, at least on lists, more constrained and more performant
08:33:05 <lortabac> (+) is confusing because you can fold it both ways and the result won't change
08:33:07 <Inst> i'm assuming that if i assert that any foldl can be implemented as a foldr
08:33:18 <Inst> someone will bring up a counterexample
08:33:29 <lortabac> but in other cases you can't really choose, one of the two is correct and the other is wrong
08:33:31 <Inst> but of course, foldr implemented as foldl isn't possible for infinite lists, as a minimum counterexample
08:33:46 <Inst> let f = flip g
08:34:59 <Inst> and i suppose for a left associative data structure, foldl takes the properties of foldr for that data structure
08:35:01 <lortabac> flip is not enough
08:35:45 <lortabac> you can try, flip doesn't transform foldl into foldr (nor viceversa)
08:36:05 <lortabac> the transformation is more complex, but I think you already know
08:36:29 <probie> Inst: No, _every_ foldl (over lists) can be implemented as a foldr
08:37:24 <Inst> yeah, but i was saying, if the data structure is different the same property may not hold
08:38:05 <Inst> and actually, i'm wrong, : is right associative
08:41:36 __monty__ joins (~toonn@user/toonn)
08:42:45 danse-nr3_ joins (~francesco@rm-19-27-218.service.infuturo.it)
08:43:01 eggplantade joins (~Eggplanta@2600:1700:38c5:d800:182a:8598:da7e:1049)
08:56:30 misterfish joins (~misterfis@87.215.131.102)
08:58:13 × Xe quits (~cadey@tailscale/xe) (Ping timeout: 240 seconds)
08:58:36 merijn joins (~merijn@088-129-128-083.dynamic.caiway.nl)
08:59:42 Pickchea joins (~private@user/pickchea)
08:59:53 × sm quits (~sm@plaintextaccounting/sm) (Quit: sm)
09:00:27 Xe joins (~cadey@tailscale/xe)
09:00:44 fweht joins (uid404746@id-404746.lymington.irccloud.com)
09:01:36 danse-nr3__ joins (~francesco@151.47.77.179)
09:02:45 × danse-nr3_ quits (~francesco@rm-19-27-218.service.infuturo.it) (Read error: Connection reset by peer)
09:03:30 × merijn quits (~merijn@088-129-128-083.dynamic.caiway.nl) (Ping timeout: 252 seconds)
09:05:10 × econo_ quits (uid147250@id-147250.tinside.irccloud.com) (Quit: Connection closed for inactivity)
09:07:50 × libertyprime quits (~libertypr@203.96.203.44) (Quit: leaving)
09:08:37 × cptaffe quits (~cptaffe@user/cptaffe) (Ping timeout: 252 seconds)
09:08:49 cptaffe` joins (~cptaffe@user/cptaffe)
09:13:26 × jespada quits (~jespada@cpc121308-nmal25-2-0-cust15.19-2.cable.virginm.net) (Quit: Textual IRC Client: www.textualapp.com)
09:18:41 DoubleB joins (~DoubleB@202.126.88.184)
09:18:56 dcoutts_ joins (~duncan@2a02:8012:ae9a:0:217c:5666:d075:6292)
09:20:11 ubert joins (~Thunderbi@178.165.190.116.wireless.dyn.drei.com)
09:20:56 × DoubleB quits (~DoubleB@202.126.88.184) (Client Quit)
09:28:11 RSCASTILHO joins (~RSCASTILH@187.40.124.54)
09:31:20 × random-jellyfish quits (~random-je@user/random-jellyfish) (Quit: Client closed)
09:35:40 jespada joins (~jespada@cpc121308-nmal25-2-0-cust15.19-2.cable.virginm.net)
09:36:48 × yosef` quits (~yosef`@user/yosef/x-2947716) (Ping timeout: 245 seconds)
09:43:16 × Inst quits (~Inst@120.244.192.250) (Read error: Connection reset by peer)
09:49:12 × xmachina quits (~xmachina@modemcable048.127-56-74.mc.videotron.ca) (Ping timeout: 260 seconds)
09:53:08 Inst joins (~Inst@120.244.192.250)
09:55:48 sm joins (~sm@plaintextaccounting/sm)
09:57:17 Unicorn_Princess joins (~Unicorn_P@user/Unicorn-Princess/x-3540542)
10:02:56 × tromp quits (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Read error: Connection reset by peer)
10:03:16 merijn joins (~merijn@088-129-128-083.dynamic.caiway.nl)
10:03:26 xmachina joins (xmachina@gateway/vpn/protonvpn/xmachina)
10:03:55 × notzmv quits (~zmv@user/notzmv) (Ping timeout: 264 seconds)
10:09:19 × xff0x quits (~xff0x@125x103x176x34.ap125.ftth.ucom.ne.jp) (Ping timeout: 264 seconds)
10:10:32 × sm quits (~sm@plaintextaccounting/sm) (Quit: sm)
10:12:28 × driib quits (~driib@vmi931078.contaboserver.net) (Quit: The Lounge - https://thelounge.chat)
10:13:08 driib joins (~driib@vmi931078.contaboserver.net)
10:20:59 nate2 joins (~nate@c-98-45-169-16.hsd1.ca.comcast.net)
10:25:47 × nate2 quits (~nate@c-98-45-169-16.hsd1.ca.comcast.net) (Ping timeout: 246 seconds)
10:31:05 × privacy quits (~privacy@47.219.84.6) (Quit: Leaving)
10:32:44 califax_ joins (~califax@user/califx)
10:32:57 × stiell_ quits (~stiell@gateway/tor-sasl/stiell) (Ping timeout: 252 seconds)
10:32:58 × califax quits (~califax@user/califx) (Ping timeout: 252 seconds)
10:33:41 × sord937 quits (~sord937@gateway/tor-sasl/sord937) (Ping timeout: 252 seconds)
10:33:41 × cafkafk quits (~cafkafk@fsf/member/cafkafk) (Ping timeout: 252 seconds)
10:34:04 califax_ is now known as califax
10:35:44 cafkafk joins (~cafkafk@fsf/member/cafkafk)
10:36:05 sord937 joins (~sord937@gateway/tor-sasl/sord937)
10:36:12 × merijn quits (~merijn@088-129-128-083.dynamic.caiway.nl) (Ping timeout: 240 seconds)
10:39:37 stiell_ joins (~stiell@gateway/tor-sasl/stiell)
10:46:39 × CiaoSen quits (~Jura@2a05:5800:29e:d200:664b:f0ff:fe37:9ef) (Ping timeout: 240 seconds)
10:46:43 pyooque joins (~puke@user/puke)
10:46:43 puke is now known as Guest7199
10:46:43 × Guest7199 quits (~puke@user/puke) (Killed (lead.libera.chat (Nickname regained by services)))
10:46:43 pyooque is now known as puke
10:48:37 × Inst quits (~Inst@120.244.192.250) (Ping timeout: 244 seconds)
10:49:07 sm joins (~sm@plaintextaccounting/sm)
10:50:06 × Nixkernal quits (~Nixkernal@119.4.193.178.dynamic.wline.res.cust.swisscom.ch) (Quit: No Ping reply in 180 seconds.)
10:51:32 Nixkernal joins (~Nixkernal@119.4.193.178.dynamic.wline.res.cust.swisscom.ch)
10:51:38 × akegalj_ quits (~akegalj@93-142-166-66.adsl.net.t-com.hr) (Quit: leaving)
10:53:17 × vglfr quits (~vglfr@cli-188-239-201-89.bbn.slav.dn.ua) (Remote host closed the connection)
10:54:15 vglfr joins (~vglfr@cli-188-239-201-89.bbn.slav.dn.ua)
10:55:13 × vglfr quits (~vglfr@cli-188-239-201-89.bbn.slav.dn.ua) (Remote host closed the connection)
10:56:10 vglfr joins (~vglfr@cli-188-239-201-89.bbn.slav.dn.ua)
10:58:48 × xmachina quits (xmachina@gateway/vpn/protonvpn/xmachina) (Ping timeout: 255 seconds)
11:05:25 <danse-nr3__> hi all, how is life going in haskell land?
11:06:04 billchenchina joins (~billchenc@103.152.35.21)
11:09:51 × Pickchea quits (~private@user/pickchea) (Quit: Leaving)
11:10:07 Pickchea joins (~private@user/pickchea)
11:10:53 <arahael> danse-nr3__: Is it really a life without a grip on the Real World?
11:12:06 <danse-nr3__> to the contrary, it has a nicely abstracted grip on it
11:12:48 xmachina joins (~xmachina@modemcable048.127-56-74.mc.videotron.ca)
11:14:04 × Pickchea quits (~private@user/pickchea) (Client Quit)
11:15:42 <arahael> I dunno, when I go on a date, I prefer dinner to be a real thing. ;)
11:16:57 <danse-nr3__> yeah but what can i say, our "civilized" world prompts us to use fork and spoon
11:17:22 <arahael> Damned civilisation!
11:17:27 <danse-nr3__> true that
11:21:11 × CAT_S quits (apic@brezn3.muc.ccc.de) (Read error: Connection reset by peer)
11:25:31 × Batzy_ quits (~quassel@user/batzy) (Ping timeout: 264 seconds)
11:26:50 Batzy joins (~quassel@user/batzy)
11:34:31 × puke quits (~puke@user/puke) (Ping timeout: 264 seconds)
11:35:51 × danse-nr3__ quits (~francesco@151.47.77.179) (Ping timeout: 240 seconds)
11:37:20 CAT_S joins (~apic@brezn3.muc.ccc.de)
11:42:11 azimut joins (~azimut@gateway/tor-sasl/azimut)
11:49:22 × jmdaemon quits (~jmdaemon@user/jmdaemon) (Ping timeout: 260 seconds)
11:51:12 × sm quits (~sm@plaintextaccounting/sm) (Quit: sm)
11:52:26 sm joins (~sm@plaintextaccounting/sm)
11:53:56 merijn joins (~merijn@088-129-128-083.dynamic.caiway.nl)
11:54:06 × sm quits (~sm@plaintextaccounting/sm) (Client Quit)
12:04:36 × skippy quits (sid26890@user/slice) (Quit: Connection closed for inactivity)
12:08:19 xff0x joins (~xff0x@2405:6580:b080:900:5520:f57a:a6e0:cbf2)
12:11:01 × RSCASTILHO quits (~RSCASTILH@187.40.124.54) ()
12:13:38 random-jellyfish joins (~random-je@user/random-jellyfish)
12:16:13 notzmv joins (~zmv@user/notzmv)
12:18:06 [itchyjunk] joins (~itchyjunk@user/itchyjunk/x-7353470)
12:27:23 Inst joins (~Inst@120.244.192.250)
12:27:51 × merijn quits (~merijn@088-129-128-083.dynamic.caiway.nl) (Ping timeout: 240 seconds)
12:31:46 × random-jellyfish quits (~random-je@user/random-jellyfish) (Quit: Client closed)
12:35:30 danse-nr3 joins (~francesco@151.47.77.179)
12:37:07 privacy joins (~privacy@47.219.84.6)
12:41:38 hyiltiz2 joins (~hyiltiz@2620:149:13d1:100::138)
12:41:44 × hyiltiz quits (~hyiltiz@2603-8080-1f00-082f-15d9-d49d-e7d8-6241.res6.spectrum.com) (Read error: Connection reset by peer)
12:44:41 × mfg quits (~user@128.176.164.115) (Ping timeout: 258 seconds)
12:46:33 waleee joins (~waleee@2001:9b0:21c:4000:5bf9:6515:c030:57b7)
12:49:32 xmachina1 joins (xmachina@gateway/vpn/protonvpn/xmachina)
12:51:04 × xmachina quits (~xmachina@modemcable048.127-56-74.mc.videotron.ca) (Ping timeout: 244 seconds)
12:54:14 xmachina1 is now known as Co2
12:57:25 × Co2 quits (xmachina@gateway/vpn/protonvpn/xmachina) (Quit: WeeChat 4.0.4)
12:57:34 × waleee quits (~waleee@2001:9b0:21c:4000:5bf9:6515:c030:57b7) (Ping timeout: 245 seconds)
13:01:38 × danse-nr3 quits (~francesco@151.47.77.179) (Read error: Connection reset by peer)
13:01:40 danse-nr3_ joins (~francesco@151.47.41.11)
13:02:23 <danse-nr3_> i have been told by a colleague that haskell's typeclasses are meant to be used as an abstraction only when the instances are expected to satisfy some laws.
13:02:26 <danse-nr3_> Had never read about this in learning material, so although several classes follow this pattern, i was wondering whether that is a recognized good practice
13:02:27 × Alex_test quits (~al_test@178.34.160.78) (Quit: ;-)
13:02:50 × AlexZenon quits (~alzenon@178.34.160.78) (Quit: ;-)
13:03:09 <dminuoso> Some say yes, plenty of libraries say no.
13:03:13 × AlexNoo quits (~AlexNoo@178.34.160.78) (Quit: Leaving)
13:03:16 <dminuoso> It's the wild west.
13:03:46 <dminuoso> The one thing I never hear about, is *why* typeclasses should be lawful.
13:04:07 <dminuoso> It feels like some religious belief.
13:07:21 <exarkun> There's two pieces right? "There are laws that apply to the class" and "an instance follows the laws ('is lawful')"
13:08:08 <exarkun> You can't have an unlawful Data.Default because there are no laws to break. But you can have an unlawful Functor because there are Functor laws.
13:08:28 <exarkun> It seems like there's pretty clear reasons to have lawful instances if there are laws at all
13:08:50 <dminuoso> exarkun: They are referring to a belief, that typeclasses are a smell if they dont have mathematical laws attached to them.
13:08:53 <danse-nr3_> i was referring to defining a class without laws associated to it
13:09:10 <lortabac> for me the idea is 1) predictability 2) ability to write code that is generic over all instances of the class
13:09:11 <exarkun> dminuoso: Sure, just making sure
13:09:38 <lortabac> laws are a good way to achieve those goals, but not the only one
13:10:40 <dminuoso> I guess if you document expected semantics (in the sense of interfaces/protocols), that would be fine too.
13:12:05 powderhorn joins (~powderhor@207-153-12-54.static.fttp.usinternet.com)
13:12:29 <[exa]> danse-nr3_: extra laws can create extra assumptions that you can use in the program. For many people the assumption about the typeclass methods having types checked is sufficient. Do they count as laws?
13:13:16 <exarkun> I have the impression that "laws" are usually exactly the things that the language cannot check.
13:13:17 <danse-nr3_> no, i think they do not count. I agree laws are great, but i thought classes were useful independently
13:13:41 <[exa]> danse-nr3_: ofc they are, you can't do sensible overloading without them :]
13:14:01 <danse-nr3_> that is what i thought, but apparently there is no agreement about this
13:14:20 <[exa]> anyway the definition of "laws" as "theorems that are hard to prove automatically by the type/other system" is pretty much OK for me
13:14:44 × Nixkernal quits (~Nixkernal@119.4.193.178.dynamic.wline.res.cust.swisscom.ch) (Quit: https://quassel-irc.org - Chat comfortably. Anywhere.)
13:15:04 Nixkernal joins (~Nixkernal@119.4.193.178.dynamic.wline.res.cust.swisscom.ch)
13:15:06 <exarkun> danse-nr3_: There is certainly agreement! One group of people agree that you should have laws, another group of people agree that you don't need to ;)
13:15:18 <danse-nr3_> ^.^;
13:15:40 <[exa]> notably one of the groups doesn't know how undecidable is checking even of the very simple laws
13:15:44 ddellacosta joins (~ddellacos@ool-44c738de.dyn.optonline.net)
13:16:28 <danse-nr3_> provability is not a concern here. I would love to add laws to all my classes, just i find that classes are useful for many cases where i cannot think of any law (yet?)
13:16:31 <haskellbridge> <m​auke> Does Bounded have laws?
13:16:55 AlexNoo joins (~AlexNoo@178.34.160.78)
13:17:40 <exarkun> does a class have laws if they aren't written in its haddocks?
13:17:48 AlexZenon joins (~alzenon@178.34.160.78)
13:17:55 <[exa]> traditional laws™
13:18:16 <[exa]> "sure this * is commutative"
13:21:01 <danse-nr3_> Bounded and Enum are an interesting case. There are laws for when _both_ classes go together. I guess that if one had to wait for laws before creating them, the classes had never existed and therefore not even the overlap laws
13:22:34 Alex_test joins (~al_test@178.34.160.78)
13:22:38 ystael joins (~ystael@user/ystael)
13:24:25 <tomsmeding> what are the laws for Hashable? https://hackage.haskell.org/package/hashable-1.4.3.0/docs/Data-Hashable.html#t:Hashable
13:24:32 <tomsmeding> there are expected semantics
13:24:56 <tomsmeding> but there are basically no straight laws that can be expected to always hold
13:25:02 <tomsmeding> yet it is clearly a well-defined and useful class
13:26:09 sabino joins (~sabino@user/sabino)
13:26:30 <tomsmeding> type classes are a method of abstraction, and their point is that functions can use certain functionality without caring precisely which implementation they're using. For that to work, there has to be some kind of abstract functionality that the type class provides
13:27:12 <tomsmeding> and sometimes there are also algebraic laws that hold, which enable further reasoning about the type class methods, but those need not be there for the type class to be useful for their intended purpose: abstraction
13:27:41 <danse-nr3_> i guess me and you are in one of the two agreement groups
13:27:50 × vglfr quits (~vglfr@cli-188-239-201-89.bbn.slav.dn.ua) (Remote host closed the connection)
13:28:15 <tomsmeding> sometimes people write type classes with almost no abstraction, just to be able to use the same function name in multiple fairly unrelated contexts (really ad hoc overloading). This is also possible with type classes, but not really a nice use of them
13:28:58 vglfr joins (~vglfr@cli-188-239-201-89.bbn.slav.dn.ua)
13:29:03 <tomsmeding> danse-nr3_: I guess it depends on whether you would count the expected semantics of e.g. Hashable as a "law"
13:30:44 × vglfr quits (~vglfr@cli-188-239-201-89.bbn.slav.dn.ua) (Remote host closed the connection)
13:30:58 <tomsmeding> but this "not nice" use of type classes would correspond, in an OOP language, with a function with a bunch of overloads that have little to do with each other. OOP people would call that "not nice" too
13:31:04 <tomsmeding> this is not specific to type classes or FP
13:31:10 vglfr joins (~vglfr@cli-188-239-201-89.bbn.slav.dn.ua)
13:31:22 <danse-nr3_> i meant that we are on the same group, considering classes just as an abstraction mean. And to be honest i would also use them with almost no abstraction. Sometimes one writes code (declaring a variable, for instance) just for consistence and convenience, and then some patterns get more explicit
13:31:24 × Feuermagier quits (~Feuermagi@user/feuermagier) (Ping timeout: 240 seconds)
13:31:35 <tomsmeding> sure
13:32:39 × vglfr quits (~vglfr@cli-188-239-201-89.bbn.slav.dn.ua) (Remote host closed the connection)
13:33:31 <tomsmeding> I would maybe even go so far as to say the following: type classes that are fully specified by a set of algebraic laws could be called _algebraic type classes_
13:33:41 <tomsmeding> examples: Monoid, Monad, Eq, etc.
13:33:46 <tomsmeding> MonadIO
13:34:07 <tomsmeding> they're a subset of the useful type classes that correspond, in a way, to some mathematical concept
13:34:11 tremon joins (~tremon@83.80.159.219)
13:34:19 <tomsmeding> not all abstraction corresponds to a mathematical concept, and yet we want to use such abstractions too
13:34:49 <danse-nr3_> well i think they do, but those are trivial concepts that do not involve laws
13:35:09 <tomsmeding> but they are not fully specified by the mathematical concept
13:35:24 <tomsmeding> everything about Eq is specified by being being an equivalence relation
13:35:40 <tomsmeding> there might be some trivial properties about Hashable, but there is more to it than just that
13:36:41 <tomsmeding> what are the laws of ToField? https://hackage.haskell.org/package/sqlite-simple-0.4.18.2/docs/Database-SQLite-Simple-ToField.html
13:37:16 <danse-nr3_> i agree that having a specific concept like "algebraic type classes" or something similar would make sense
13:37:18 <tomsmeding> one might say that there are some laws in combination with FromField, that they have to be inverses of each other in some sense. So there are laws you can formulate. But surely that's not all there is too them!
13:37:37 <tomsmeding> they also have to map naturally into the SQL data type domain, and that's an essential component of the abstraction
13:38:00 <tomsmeding> s/too them/to them/
13:38:17 <Rembane> That sounds painful and like a nice research project.
13:38:25 <tomsmeding> what does?
13:38:35 xmachina joins (xmachina@gateway/vpn/protonvpn/xmachina)
13:38:36 <Rembane> Adding and proving laws to FromField and ToField.
13:38:59 <tomsmeding> hah
13:39:03 <tomsmeding> yeah
13:39:26 <tomsmeding> but my point is that not all of the semantics abstracted by those classes will be contained in those laws
13:40:00 <Rembane> I agree.
13:40:04 <tomsmeding> good luck formalising that String ought to map to SQLText and Text also, but ByteString ought not to
13:41:22 vglfr joins (~vglfr@188.239.201.89)
13:41:37 × texasmynsted quits (~username@99.96.221.112) (Quit: WeeChat 3.0)
13:42:01 × powderhorn quits (~powderhor@207-153-12-54.static.fttp.usinternet.com) (Quit: Client closed)
13:42:12 powderhorn joins (~powderhor@207-153-12-54.static.fttp.usinternet.com)
13:43:23 × xmachina quits (xmachina@gateway/vpn/protonvpn/xmachina) (Client Quit)
13:45:07 merijn joins (~merijn@088-129-128-083.dynamic.caiway.nl)
13:49:51 × acidjnk_new quits (~acidjnk@p200300d6e7072f380063779f7ab954b0.dip0.t-ipconnect.de) (Ping timeout: 258 seconds)
13:53:15 xmachina joins (xmachina@gateway/vpn/protonvpn/xmachina)
13:53:16 xmachina is now known as Co2
13:53:43 Co2 is now known as xmachina
13:54:19 wroathe joins (~wroathe@207-153-38-140.fttp.usinternet.com)
13:54:19 × wroathe quits (~wroathe@207-153-38-140.fttp.usinternet.com) (Changing host)
13:54:19 wroathe joins (~wroathe@user/wroathe)
13:56:14 stef204 joins (~stef204@user/stef204)
13:57:49 tromp joins (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
14:03:48 × wroathe quits (~wroathe@user/wroathe) (Ping timeout: 240 seconds)
14:08:50 RSCASTILHO joins (~RSCASTILH@187.40.124.54)
14:11:02 Guest65 joins (~Guest65@dynamic-077-009-004-123.77.9.pool.telefonica.de)
14:11:22 × Guest65 quits (~Guest65@dynamic-077-009-004-123.77.9.pool.telefonica.de) (Client Quit)
14:12:05 Guest65 joins (~Guest65@dynamic-077-009-004-123.77.9.pool.telefonica.de)
14:18:15 × cfricke quits (~cfricke@user/cfricke) (Quit: WeeChat 4.0.4)
14:19:25 × merijn quits (~merijn@088-129-128-083.dynamic.caiway.nl) (Ping timeout: 244 seconds)
14:21:00 × notzmv quits (~zmv@user/notzmv) (Ping timeout: 240 seconds)
14:22:43 nate2 joins (~nate@c-98-45-169-16.hsd1.ca.comcast.net)
14:25:56 acidjnk_new joins (~acidjnk@p200300d6e7072f380063779f7ab954b0.dip0.t-ipconnect.de)
14:27:36 mfg joins (~user@2a02:908:d13:e3e0:6a54:5aff:fe66:a805)
14:27:55 × nate2 quits (~nate@c-98-45-169-16.hsd1.ca.comcast.net) (Ping timeout: 264 seconds)
14:41:02 ft joins (~ft@p3e9bc680.dip0.t-ipconnect.de)
14:41:23 × powderhorn quits (~powderhor@207-153-12-54.static.fttp.usinternet.com) (Ping timeout: 245 seconds)
14:42:28 dhil joins (~dhil@78.45.150.83.ewm.ftth.as8758.net)
14:42:51 × misterfish quits (~misterfis@87.215.131.102) (Ping timeout: 252 seconds)
14:43:17 hugo- joins (~hugo@verdigris.lysator.liu.se)
14:55:55 tzh joins (~tzh@c-71-193-181-0.hsd1.or.comcast.net)
14:56:07 × stef204 quits (~stef204@user/stef204) (Quit: WeeChat 4.0.4)
14:57:12 Achylles joins (~Achylles_@45.182.57.64)
14:58:13 × Achylles quits (~Achylles_@45.182.57.64) (Read error: Connection reset by peer)
15:02:41 × Guest65 quits (~Guest65@dynamic-077-009-004-123.77.9.pool.telefonica.de) (Quit: Client closed)
15:06:11 Sgeo joins (~Sgeo@user/sgeo)
15:07:02 × lortabac quits (~lortabac@2a01:e0a:541:b8f0:882f:270a:9fdd:8778) (Quit: WeeChat 2.8)
15:19:58 × tromp quits (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
15:23:58 × michalz quits (~michalz@185.246.207.197) (Remote host closed the connection)
15:25:52 econo_ joins (uid147250@id-147250.tinside.irccloud.com)
15:29:43 × mfg quits (~user@2a02:908:d13:e3e0:6a54:5aff:fe66:a805) (Ping timeout: 264 seconds)
15:31:37 × mc47 quits (~mc47@xmonad/TheMC47) (Remote host closed the connection)
15:32:53 merijn joins (~merijn@088-129-128-083.dynamic.caiway.nl)
15:34:45 tromp joins (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
15:36:39 × acidjnk_new quits (~acidjnk@p200300d6e7072f380063779f7ab954b0.dip0.t-ipconnect.de) (Ping timeout: 240 seconds)
15:36:48 bontaq joins (~user@ool-45707d2c.dyn.optonline.net)
15:37:42 × smoothdev quits (~smoothdev@91-169-231-236.subs.proxad.net) (Read error: Connection reset by peer)
15:41:03 × eggplantade quits (~Eggplanta@2600:1700:38c5:d800:182a:8598:da7e:1049) (Remote host closed the connection)
15:41:18 eggplantade joins (~Eggplanta@2600:1700:38c5:d800:182a:8598:da7e:1049)
15:42:58 × dcoutts_ quits (~duncan@2a02:8012:ae9a:0:217c:5666:d075:6292) (Ping timeout: 252 seconds)
15:51:45 × xmachina quits (xmachina@gateway/vpn/protonvpn/xmachina) (Ping timeout: 258 seconds)
15:52:38 × hugo- quits (~hugo@verdigris.lysator.liu.se) (Ping timeout: 260 seconds)
15:52:53 <fendor> Can I have Codensity for a graded/parameterised monad in Haskell?
16:00:15 × danse-nr3_ quits (~francesco@151.47.41.11) (Ping timeout: 240 seconds)
16:01:42 hugo- joins (~hugo@verdigris.lysator.liu.se)
16:03:16 <lyxia> fendor: sure
16:03:40 × eggplantade quits (~Eggplanta@2600:1700:38c5:d800:182a:8598:da7e:1049) (Remote host closed the connection)
16:04:33 <lyxia> newtype Codensity m g a = Codensity (forall h r. (a -> m h r) -> m (g <> h) r)
16:05:34 × arahael quits (~arahael@119-18-1-27.771201.syd.nbn.aussiebb.net) (Ping timeout: 258 seconds)
16:05:40 xmachina joins (~xmachina@modemcable048.127-56-74.mc.videotron.ca)
16:06:50 <fendor> Where `<>` is some appropriate monoid... That makes sense, and for a parameterised monad? I had `newtype ICodensity m p q a = ICodensity (forall c . (a -> m p q c) -> m p q c)`
16:07:02 <fendor> but that looks like it is incorrect
16:07:03 × merijn quits (~merijn@088-129-128-083.dynamic.caiway.nl) (Ping timeout: 240 seconds)
16:07:19 <fendor> the inner p and q should be i and j,
16:08:14 × cptaffe` quits (~cptaffe@user/cptaffe) (Quit: ZNC 1.8.2 - https://znc.in)
16:08:36 cptaffe joins (~cptaffe@user/cptaffe)
16:08:38 edr joins (~edr@user/edr)
16:09:58 <ncf> ICodensity m j k a = ICodensity (forall c. (a -> m i j c) -> m i k c) ?
16:10:06 <ncf> might need to swap them depending on how you're composing
16:10:37 <fendor> and it should be `forall i.` I assume?
16:10:52 <ncf> yeah
16:11:59 <fendor> I am not sure I see that this is correct... Why is j and k in the post condition only?
16:12:34 <fendor> s/that/why/
16:14:25 <ncf> think of yoneda: (j -> k) is isomorphic to (forall i. (i -> j) -> i -> k)
16:15:23 <ncf> or just partially apply your bind operator to some value of type m j k a and see what type you get
16:16:53 <fendor> ah, ok, that makes sense
16:21:55 <fendor> thanks!
16:23:39 cptaffe` joins (~cptaffe@user/cptaffe)
16:23:48 azimut_ joins (~azimut@gateway/tor-sasl/azimut)
16:24:13 × cptaffe quits (~cptaffe@user/cptaffe) (Ping timeout: 252 seconds)
16:24:35 × azimut quits (~azimut@gateway/tor-sasl/azimut) (Ping timeout: 252 seconds)
16:27:48 × tromp quits (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
16:29:46 _ht joins (~Thunderbi@28-52-174-82.ftth.glasoperator.nl)
16:30:51 × dhil quits (~dhil@78.45.150.83.ewm.ftth.as8758.net) (Ping timeout: 258 seconds)
16:32:34 danse-nr3_ joins (~francesco@151.47.41.11)
16:39:35 <fendor> ncf, btw, when I enter `m j k a >>=` it becomes `(a -> m j k b) -> m i k b`. Which probably is what you meant by swapping?
16:40:35 <ncf> yeah
16:40:55 <fendor> thank you for your help!
16:41:13 × orcus quits (~orcus@mail.brprice.uk) (Quit: ZNC 1.8.2 - https://znc.in)
16:41:13 × dispater quits (~dispater@mail.brprice.uk) (Quit: ZNC 1.8.2 - https://znc.in)
16:41:46 × chele quits (~chele@user/chele) (Remote host closed the connection)
16:41:59 notzmv joins (~zmv@user/notzmv)
16:42:58 dispater joins (~dispater@mail.brprice.uk)
16:42:58 eggplantade joins (~Eggplanta@2600:1700:38c5:d800:182a:8598:da7e:1049)
16:43:28 orcus joins (~orcus@mail.brprice.uk)
16:47:11 × fendor quits (~fendor@2a02:8388:1640:be00:aab:1226:f274:5021) (Remote host closed the connection)
16:51:28 × eggplantade quits (~Eggplanta@2600:1700:38c5:d800:182a:8598:da7e:1049) (Remote host closed the connection)
16:51:43 eggplantade joins (~Eggplanta@104-55-37-220.lightspeed.sntcca.sbcglobal.net)
16:58:55 × sord937 quits (~sord937@gateway/tor-sasl/sord937) (Quit: sord937)
17:00:58 × danse-nr3_ quits (~francesco@151.47.41.11) (Read error: Connection reset by peer)
17:01:52 danse-nr3_ joins (~francesco@na-19-67-153.service.infuturo.it)
17:08:33 monochrom joins (~trebla@216.138.220.146)
17:17:34 acidjnk_new joins (~acidjnk@p200300d6e7072f38e0c62ed7d1d3bf45.dip0.t-ipconnect.de)
17:17:48 idgaen joins (~idgaen@2a01:e0a:498:fd50:fcc6:bb5d:489a:ce8c)
17:20:06 × cptaffe` quits (~cptaffe@user/cptaffe) (Quit: ZNC 1.8.2 - https://znc.in)
17:20:24 cptaffe joins (~cptaffe@user/cptaffe)
17:23:26 smoothdev joins (~smoothdev@91-169-231-236.subs.proxad.net)
17:24:00 merijn joins (~merijn@088-129-128-083.dynamic.caiway.nl)
17:26:32 gatekempt joins (~gatekempt@user/gatekempt)
17:28:44 × merijn quits (~merijn@088-129-128-083.dynamic.caiway.nl) (Ping timeout: 248 seconds)
17:36:49 sm joins (~sm@plaintextaccounting/sm)
17:40:39 dhil joins (~dhil@78.45.150.83.ewm.ftth.as8758.net)
17:42:41 × azimut_ quits (~azimut@gateway/tor-sasl/azimut) (Ping timeout: 252 seconds)
17:44:05 × sm quits (~sm@plaintextaccounting/sm) (Quit: sm)
17:45:08 tromp joins (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
17:45:43 × eggplantade quits (~Eggplanta@104-55-37-220.lightspeed.sntcca.sbcglobal.net) (Remote host closed the connection)
17:47:11 qqq joins (~qqq@92.43.167.61)
17:48:49 × RSCASTILHO quits (~RSCASTILH@187.40.124.54) ()
17:51:30 azimut joins (~azimut@gateway/tor-sasl/azimut)
17:54:05 × billchenchina quits (~billchenc@103.152.35.21) (Remote host closed the connection)
17:56:37 × azimut quits (~azimut@gateway/tor-sasl/azimut) (Ping timeout: 252 seconds)
18:00:57 azimut joins (~azimut@gateway/tor-sasl/azimut)
18:02:20 <exarkun> Anyone have experience with or opinions about https://ramirez7.github.io/monad-fault/Control-Monad-Trans-Fault.html or similar libraries? Can it be said either that "fault injection" a good or bad idea in Haskell?
18:05:51 × phma quits (~phma@host-67-44-208-41.hnremote.net) (Read error: Connection reset by peer)
18:06:50 phma joins (~phma@2001:5b0:212a:dfd8:7461:70e8:4780:de84)
18:08:30 eggplantade joins (~Eggplanta@2600:1700:38c5:d800:182a:8598:da7e:1049)
18:18:23 × TimWolla quits (~timwolla@2a01:4f8:150:6153:beef::6667) (Quit: Bye)
18:23:18 TimWolla joins (~timwolla@2a01:4f8:150:6153:beef::6667)
18:24:27 nate2 joins (~nate@c-98-45-169-16.hsd1.ca.comcast.net)
18:26:55 × eggplantade quits (~Eggplanta@2600:1700:38c5:d800:182a:8598:da7e:1049) (Remote host closed the connection)
18:29:14 × nate2 quits (~nate@c-98-45-169-16.hsd1.ca.comcast.net) (Ping timeout: 245 seconds)
18:30:44 Tesfe2321 joins (~School@2001:1970:5199:fa00::a4bf)
18:31:41 eggplantade joins (~Eggplanta@2600:1700:38c5:d800:182a:8598:da7e:1049)
18:32:37 zincy joins (~tom@2a00:23c8:970c:4801:5b6a:e81b:79dc:f684)
18:33:22 <zincy> let centering_matrix: OMatrix<f64, Dyn, Dyn> = OMatrix::<f64, Dyn, Dyn>::from_vec(n, m.ncols(), col_means);
18:33:30 <zincy> Oh wrong channel sorry
18:35:18 Tuplanolla joins (~Tuplanoll@91-159-68-236.elisa-laajakaista.fi)
18:36:53 × eggplantade quits (~Eggplanta@2600:1700:38c5:d800:182a:8598:da7e:1049) (Remote host closed the connection)
18:37:52 eggplantade joins (~Eggplanta@2600:1700:38c5:d800:182a:8598:da7e:1049)
18:38:14 spatchkaa joins (~spatchkaa@S010600fc8da47b63.gv.shawcable.net)
18:41:13 misterfish joins (~misterfis@84-53-85-146.bbserv.nl)
18:41:19 sm joins (~sm@plaintextaccounting/sm)
18:41:48 × eggplantade quits (~Eggplanta@2600:1700:38c5:d800:182a:8598:da7e:1049) (Remote host closed the connection)
18:43:50 × sm quits (~sm@plaintextaccounting/sm) (Client Quit)
18:47:26 × tromp quits (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
18:47:29 wootehfoot joins (~wootehfoo@user/wootehfoot)
18:48:49 tromp joins (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
18:49:27 <exarkun> no opinions on fault injection huh
18:57:48 × ByronJohnson quits (~bairyn@50-250-232-19-static.hfc.comcastbusiness.net) (Ping timeout: 240 seconds)
19:03:22 × machinedgod quits (~machinedg@d198-53-218-113.abhsia.telus.net) (Ping timeout: 260 seconds)
19:03:45 ByronJohnson joins (~bairyn@50-250-232-19-static.hfc.comcastbusiness.net)
19:04:23 <monochrom> I don't know fault injection. I don't suppose it would hurt.
19:09:08 × EvanR quits (~EvanR@user/evanr) (Remote host closed the connection)
19:10:45 <mauke> I inject my faults the old-fashioned way, using a keyboard
19:11:12 bardman joins (~bardman@4.17.84.154)
19:11:29 <danse-nr3_> i do not have many opinions on transformers, normally my efforts are geared towards moving most logic to pure functions
19:12:54 EvanR joins (~EvanR@user/evanr)
19:14:42 × bardman quits (~bardman@4.17.84.154) (Client Quit)
19:14:45 <exarkun> I do like pure functions.
19:16:22 merijn joins (~merijn@088-129-128-083.dynamic.caiway.nl)
19:17:24 stefan-__ joins (uid620054@id-620054.lymington.irccloud.com)
19:17:48 <davean> Pure functions is where most logic should be
19:21:35 eggplantade joins (~Eggplanta@2600:1700:38c5:d800:182a:8598:da7e:1049)
19:22:25 <mauke> in haskell, all functions are pure
19:22:46 × cptaffe quits (~cptaffe@user/cptaffe) (Remote host closed the connection)
19:22:48 <mauke> s/all/most/
19:23:19 <exarkun> did you count them
19:23:50 <EvanR> in haskell the purity of the function reflects the purity of the person who wrote it's heart
19:24:06 <davean> mauke: I don't consider FFI pure really.
19:24:17 <mauke> I discounted unsafePerformIO and trace
19:25:00 <exarkun> if you enumerate all possible functions, what is the ratio of safe to unsafe
19:25:04 <exarkun> I mean pure to impure
19:25:26 <EvanR> don't try to enumerate all functions
19:25:39 <exarkun> There's more than one way to take a pure function and make it impure, so the ratio of impure to pure must be greater than 1
19:25:39 <tomsmeding> > let inf = read "Infinity" :: Double in inf / inf
19:25:40 <EvanR> that's like enumerating all reals
19:25:41 <lambdabot> NaN
19:25:53 <exarkun> EvanR: It's _like_ it, but there's far fewer functions than reals.
19:26:03 <EvanR> no because how many types are there
19:26:05 <danse-nr3_> by "pure" i meant "without side effects", meaning they do not need monads. But yeah, technically i would consider also monadic functions as pure
19:26:11 <EvanR> for instance, reals are a type
19:26:29 <mauke> (a ->) is a monad, so don't even get me started
19:26:29 <exarkun> EvanR: Reals aren't a type in Haskell!
19:26:48 <tomsmeding> @hackage exact-real
19:26:48 <lambdabot> https://hackage.haskell.org/package/exact-real
19:27:17 <exarkun> tomsmeding: Clever, but.
19:27:19 <monochrom> If you enumerate all possible functions, firstly what's your definition for "function"? :)
19:28:05 <monochrom> Secondly why should I count functions that nobody writes?
19:28:05 <EvanR> my ultrafinitism dar is going off too, watch your back
19:28:37 <EvanR> there's only so many haskell functions you can write before someone stops paying your bills
19:28:44 <mauke> all the lonely functions, where do they all come from
19:29:40 <monochrom> Analogously, the density of rational numbers among real numbers (or even merely cyclotomic numbers) is 0, yet we use rational numbers so much more often than the rest.
19:30:28 euleritian joins (~euleritia@ip4d16fc12.dynamic.kabel-deutschland.de)
19:30:30 <monochrom> The point is "ratio of all possible X" is very likely irrelevant.
19:31:35 <monochrom> ObHaskell: https://hackage.haskell.org/package/cyclotomic :)
19:31:57 × danse-nr3_ quits (~francesco@na-19-67-153.service.infuturo.it) (Ping timeout: 260 seconds)
19:32:33 <tomsmeding> > mutiplication
19:33:59 × tromp quits (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
19:34:35 tromp joins (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
19:36:23 × spatchkaa quits (~spatchkaa@S010600fc8da47b63.gv.shawcable.net) (Ping timeout: 245 seconds)
19:37:25 <mauke> mutable implication
19:38:36 × __monty__ quits (~toonn@user/toonn) (Quit: leaving)
19:38:54 <monochrom> Oh heh
19:39:14 <monochrom> Is it OK to say you mean Kleisli arrows? :)
19:40:13 × Tesfe2321 quits (~School@2001:1970:5199:fa00::a4bf) (Ping timeout: 258 seconds)
19:40:27 <mauke> huh. I just realized Kleisli /= Kleene
19:40:56 <monochrom> Kleene also had interesting stuff. :)
19:41:19 <mauke> I guess my brain uses hashing to locate memories
19:41:56 <darkling> I've often felt that, too. The more you put in, the harder it is to recall the right thing, because there's more collisions.
19:42:07 <monochrom> I think we all do. I have my share of mixing up things.
19:42:19 <darkling> It almost certainly doesn't work that way, but it feels like a practical model.
19:42:43 <EvanR> if IRC users have the same length nick with same beginning and ending letter, I have no idea which is which
19:43:22 <tomsmeding> it gets worse if weechat gives them the same colour
19:43:51 <darkling> Indeed. (Although it's HexChat here)
19:44:03 × myme quits (~myme@2a01:799:d60:e400:2874:313d:614e:da9) (Ping timeout: 258 seconds)
19:44:20 <tomsmeding> I added the client because I'm not sure how many others also do colours like that :p
19:44:54 myme joins (~myme@2a01:799:d60:e400:2729:4165:2cf3:cd0e)
19:46:41 RedFlamingos joins (~RedFlamin@user/RedFlamingos)
19:47:25 × ft quits (~ft@p3e9bc680.dip0.t-ipconnect.de) (Remote host closed the connection)
19:50:43 × merijn quits (~merijn@088-129-128-083.dynamic.caiway.nl) (Ping timeout: 264 seconds)
19:51:10 × idgaen quits (~idgaen@2a01:e0a:498:fd50:fcc6:bb5d:489a:ce8c) (Quit: WeeChat 4.0.2)
19:51:38 ft joins (~ft@p3e9bc680.dip0.t-ipconnect.de)
19:54:29 × Natch quits (~natch@c-9e07225c.038-60-73746f7.bbcust.telenor.se) (Remote host closed the connection)
20:00:43 Pickchea joins (~private@user/pickchea)
20:02:37 hgolden joins (~hgolden@2603-8000-9d00-3ed1-a11a-09f7-e752-5c28.res6.spectrum.com)
20:04:39 × jackneill__ quits (~Jackneill@20014C4E1E062E0011575DEE5212F0F8.dsl.pool.telekom.hu) (Ping timeout: 240 seconds)
20:18:19 Natch joins (~natch@c-9e07225c.038-60-73746f7.bbcust.telenor.se)
20:18:59 monochrom is now known as monochrm
20:20:43 × misterfish quits (~misterfis@84-53-85-146.bbserv.nl) (Ping timeout: 264 seconds)
20:21:06 × Inst quits (~Inst@120.244.192.250) (Ping timeout: 252 seconds)
20:28:36 × _ht quits (~Thunderbi@28-52-174-82.ftth.glasoperator.nl) (Quit: _ht)
20:45:33 × ubert quits (~Thunderbi@178.165.190.116.wireless.dyn.drei.com) (Remote host closed the connection)
20:59:49 <int-e> phma: https://paste.debian.net/1292852/ gets within 50% of Rust for me. The main change is to use mutable arrays to reduce allocations; I'm also using `vector` because the indexing there doesn't suffer from the overhead brought in by `Ix`. Using `unsafeRead` and `unsafeWrite` and `unsafeIndex` would give another 10% speedup... not dramatic. I dropped the -N RTS flags default because it made the...
20:59:55 <int-e> ...code slower for me. Finally note that the compiler flags in the `.cabal` file only apply to the package itself, so make sure that the dependencies are actually compiled with optimizations enabled.
21:01:34 × kimiamania4 quits (~65804703@user/kimiamania) (Quit: PegeLinux)
21:02:00 kimiamania4 joins (~65804703@user/kimiamania)
21:02:47 Guest|7 joins (~Guest|7@37.140.50.226)
21:03:02 × Guest|7 quits (~Guest|7@37.140.50.226) (Client Quit)
21:04:35 Tesfe2321 joins (~School@2001:1970:5199:fa00::a4bf)
21:05:12 <int-e> (The funniest (and maybe embarrassing) part of this are two NOINLINE pragmas that made the code 2x faster.)
21:07:16 <EvanR> NOINLINE made the code faster
21:07:18 <EvanR> wut
21:07:45 merijn joins (~merijn@088-129-128-083.dynamic.caiway.nl)
21:07:48 <davean> NOINLINE can often make haskell faster, or slower, it depends.
21:08:00 <davean> Haskell has a few problems with over inlining and a few problems when you don't inline
21:08:10 <davean> one needs to consider inlining fairly carefully for performant code
21:08:30 <davean> one example is that inlining can blow out the trace, and Haskell is already decode heavy for the CPU
21:08:52 × coot quits (~coot@89-69-206-216.dynamic.chello.pl) (Quit: coot)
21:09:32 <davean> int-e: Haven't looked specificly, but did you try -N with the single threaded GC?
21:09:45 <int-e> Unfortunate inlining decisions can cause GHC to evaluate an expensive expression multiple tiems... I suspect that was the case here.
21:09:59 <davean> int-e: yep!
21:10:04 <davean> There are a number of issues
21:10:10 <EvanR> so we want to be lazier
21:10:17 <davean> EvanR: Yes, very often
21:10:31 <davean> Haskell's performance often comes from its laziness correctly applied
21:10:37 <davean> its the biggest hammer we have to make code faster
21:10:50 <int-e> davean: I didn't, there's little parallelism to begin with. AIUI -N is an insane default anyway when there's hyperthreading.
21:10:53 <EvanR> do less work, get done faster
21:10:56 <davean> Inlining is mostly important in Haskell because it can simplify the code paths and remove indirection
21:11:12 <davean> EvanR: its not even doing less work
21:11:21 <davean> laziness is about control flow.
21:11:46 coot joins (~coot@89-69-206-216.dynamic.chello.pl)
21:11:51 <davean> and it can also rearrange access patterns, etc
21:14:22 × monochrm quits (~trebla@216.138.220.146) (Remote host closed the connection)
21:14:43 × dhil quits (~dhil@78.45.150.83.ewm.ftth.as8758.net) (Ping timeout: 264 seconds)
21:15:39 monochrom joins (trebla@216.138.220.146)
21:16:07 danza joins (~francesco@rm-19-3-110.service.infuturo.it)
21:16:31 × takuan quits (~takuan@178-116-218-225.access.telenet.be) (Remote host closed the connection)
21:17:55 × solution quits (~solution@178-164-206-58.pool.digikabel.hu) (Ping timeout: 244 seconds)
21:18:19 Feuermagier joins (~Feuermagi@user/feuermagier)
21:19:49 solution joins (~solution@77-234-80-135.pool.digikabel.hu)
21:21:51 × tromp quits (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
21:24:03 × jargon quits (~jargon@184.101.67.95) (Remote host closed the connection)
21:25:15 × acidjnk_new quits (~acidjnk@p200300d6e7072f38e0c62ed7d1d3bf45.dip0.t-ipconnect.de) (Ping timeout: 258 seconds)
21:26:38 jargon joins (~jargon@184.101.67.95)
21:28:31 × gatekempt quits (~gatekempt@user/gatekempt) (Quit: My MacBook has gone to sleep. ZZZzzz…)
21:34:15 × danza quits (~francesco@rm-19-3-110.service.infuturo.it) (Ping timeout: 240 seconds)
21:35:23 ulysses4ever joins (~artem@2601:408:c408:405:e59c:f774:75db:69ea)
21:35:33 × chiselfuse quits (~chiselfus@user/chiselfuse) (Quit: leaving)
21:35:46 random-jellyfish joins (~random-je@user/random-jellyfish)
21:35:54 ulysses4ever is now known as artem
21:36:37 × smoothdev quits (~smoothdev@91-169-231-236.subs.proxad.net) (Quit: smoothdev)
21:36:43 chiselfuse joins (~chiselfus@user/chiselfuse)
21:41:51 × merijn quits (~merijn@088-129-128-083.dynamic.caiway.nl) (Ping timeout: 240 seconds)
21:44:58 son0p joins (~ff@181.136.122.143)
21:53:41 × artem quits (~artem@2601:408:c408:405:e59c:f774:75db:69ea) (Read error: Connection reset by peer)
21:56:08 × coot quits (~coot@89-69-206-216.dynamic.chello.pl) (Quit: coot)
22:00:17 ulysses4ever joins (~artem@73.145.240.11)
22:02:09 dsrt^ joins (~cd@c-66-56-7-24.hsd1.ga.comcast.net)
22:03:51 smoothdev joins (~smoothdev@91-169-231-236.subs.proxad.net)
22:03:55 troydm joins (~troydm@user/troydm)
22:05:58 × troydm1 quits (~troydm@host-176-37-53-238.b025.la.net.ua) (Ping timeout: 244 seconds)
22:07:20 bardman joins (~bardman@45-18-203-174.lightspeed.lsvlky.sbcglobal.net)
22:07:37 bardman parts (~bardman@45-18-203-174.lightspeed.lsvlky.sbcglobal.net) ()
22:20:22 × Pickchea quits (~private@user/pickchea) (Quit: Leaving)
22:22:47 × Tuplanolla quits (~Tuplanoll@91-159-68-236.elisa-laajakaista.fi) (Quit: Leaving.)
22:26:13 nate2 joins (~nate@c-98-45-169-16.hsd1.ca.comcast.net)
22:26:28 × ulysses4ever quits (~artem@73.145.240.11) (Read error: Connection reset by peer)
22:26:33 artem joins (~artem@73.145.240.11)
22:28:45 machinedgod joins (~machinedg@d198-53-218-113.abhsia.telus.net)
22:30:35 × artem quits (~artem@73.145.240.11) (Ping timeout: 240 seconds)
22:31:31 × nate2 quits (~nate@c-98-45-169-16.hsd1.ca.comcast.net) (Ping timeout: 264 seconds)
22:34:49 danza joins (~francesco@rm-19-3-110.service.infuturo.it)
22:35:14 cptaffe joins (~cptaffe@user/cptaffe)
22:50:29 × fweht quits (uid404746@id-404746.lymington.irccloud.com) (Quit: Connection closed for inactivity)
22:55:33 ulysses4ever joins (~artem@96.79.69.121)
22:58:32 merijn joins (~merijn@088-129-128-083.dynamic.caiway.nl)
23:00:10 × gmg quits (~user@user/gehmehgeh) (Quit: Leaving)
23:02:14 × danza quits (~francesco@rm-19-3-110.service.infuturo.it) (Ping timeout: 258 seconds)
23:02:40 waleee joins (~waleee@2001:9b0:21c:4000:5bf9:6515:c030:57b7)
23:02:51 × hugo- quits (~hugo@verdigris.lysator.liu.se) (Ping timeout: 255 seconds)
23:03:23 × merijn quits (~merijn@088-129-128-083.dynamic.caiway.nl) (Ping timeout: 255 seconds)
23:04:21 × wootehfoot quits (~wootehfoo@user/wootehfoot) (Ping timeout: 244 seconds)
23:12:07 × terrorjack quits (~terrorjac@2a01:4f8:c17:87f8::) (Quit: The Lounge - https://thelounge.chat)
23:13:12 terrorjack joins (~terrorjac@2a01:4f8:c17:87f8::)
23:13:30 × terrorjack quits (~terrorjac@2a01:4f8:c17:87f8::) (Client Quit)
23:15:23 terrorjack joins (~terrorjac@2a01:4f8:c17:87f8::)
23:15:57 hugo- joins (~hugo@verdigris.lysator.liu.se)
23:23:22 L29Ah parts (~L29Ah@wikipedia/L29Ah) ()
23:24:05 × waleee quits (~waleee@2001:9b0:21c:4000:5bf9:6515:c030:57b7) (Ping timeout: 255 seconds)
23:43:00 eggplant_ joins (~Eggplanta@2600:1700:38c5:d800:cfc:f4df:a815:fcce)
23:45:51 × eggplantade quits (~Eggplanta@2600:1700:38c5:d800:182a:8598:da7e:1049) (Ping timeout: 240 seconds)
23:46:04 × monochrom quits (trebla@216.138.220.146) (Quit: ZNC 1.8.2+deb3build2 - https://znc.in)
23:48:38 wroathe joins (~wroathe@user/wroathe)
23:50:11 mvk joins (~mvk@2607:fea8:5c9a:a600::848d)
23:53:07 monochrom joins (trebla@216.138.220.146)
23:55:33 bitdex joins (~bitdex@gateway/tor-sasl/bitdex)
23:56:07 × bitdex quits (~bitdex@gateway/tor-sasl/bitdex) (Remote host closed the connection)
23:57:09 bitdex joins (~bitdex@gateway/tor-sasl/bitdex)

All times are in UTC on 2023-09-22.