Logs on 2021-11-04 (liberachat/#haskell)
| 00:01:39 | → | Guest41 joins (~Guest41@eth-west-pareq2-46-193-4-100.wb.wifirst.net) |
| 00:02:43 | <shapr> | geekosaur: https://github.com/shapr/tmuxmarta/blob/master/src/Lib.hs#L65 |
| 00:02:59 | <shapr> | make that TWO examples! |
| 00:03:10 | <shapr> | boxscape_: do you remember where/when that was suggested? |
| 00:03:33 | → | [_] joins (~itchyjunk@user/itchyjunk/x-7353470) |
| 00:03:39 | <boxscape_> | unfortunately not really :-/ I remember reading it maybe one or two years ago and I think spj was involved in the discussion, but that's it |
| 00:04:38 | × | cosimone` quits (~user@93-34-133-207.ip49.fastwebnet.it) (Ping timeout: 260 seconds) |
| 00:06:38 | × | [itchyjunk] quits (~itchyjunk@user/itchyjunk/x-7353470) (Ping timeout: 268 seconds) |
| 00:07:00 | → | zebrag joins (~chris@user/zebrag) |
| 00:08:10 | × | kilolympus quits (~kilolympu@185.65.135.177) (Ping timeout: 252 seconds) |
| 00:10:30 | × | max22- quits (~maxime@2a01cb0883359800dcf2cfbbabba90b8.ipv6.abo.wanadoo.fr) (Remote host closed the connection) |
| 00:10:58 | → | doyougnu joins (~doyougnu@c-73-25-202-122.hsd1.or.comcast.net) |
| 00:12:06 | × | catman quits (~catman@user/catman) (Ping timeout: 260 seconds) |
| 00:22:03 | × | Lord_of_Life quits (~Lord@user/lord-of-life/x-2819915) (Ping timeout: 268 seconds) |
| 00:22:25 | → | Lord_of_Life joins (~Lord@user/lord-of-life/x-2819915) |
| 00:23:11 | × | forell quits (~forell@user/forell) (Ping timeout: 264 seconds) |
| 00:23:16 | × | myShoggoth quits (~myShoggot@97-120-85-195.ptld.qwest.net) (Ping timeout: 268 seconds) |
| 00:24:15 | × | Vajb quits (~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) (Read error: Connection reset by peer) |
| 00:27:40 | → | forell joins (~forell@user/forell) |
| 00:28:20 | × | machinedgod quits (~machinedg@135-23-192-217.cpe.pppoe.ca) (Remote host closed the connection) |
| 00:29:24 | → | machinedgod joins (~machinedg@135-23-192-217.cpe.pppoe.ca) |
| 00:30:18 | → | Vajb joins (~Vajb@2001:999:66:281c:27a0:1549:39e5:8b1a) |
| 00:31:15 | × | machinedgod quits (~machinedg@135-23-192-217.cpe.pppoe.ca) (Remote host closed the connection) |
| 00:32:27 | → | machinedgod joins (~machinedg@135-23-192-217.cpe.pppoe.ca) |
| 00:33:22 | → | Khelben joins (~Khelben@2001:818:e316:e700:85c9:6d4e:a6d0:2b03) |
| 00:34:26 | × | wroathe quits (~wroathe@user/wroathe) (Ping timeout: 260 seconds) |
| 00:39:12 | → | yauhsien joins (~yauhsien@118-167-41-229.dynamic-ip.hinet.net) |
| 00:43:01 | × | Gurkenglas quits (~Gurkengla@dslb-002-203-144-204.002.203.pools.vodafone-ip.de) (Ping timeout: 268 seconds) |
| 00:44:14 | × | yauhsien quits (~yauhsien@118-167-41-229.dynamic-ip.hinet.net) (Ping timeout: 268 seconds) |
| 00:47:01 | × | pop3 quits (~pop3@user/pop3) (Remote host closed the connection) |
| 00:47:11 | × | Inst quits (~Inst@2601:6c4:4080:3f80:cd36:4dbb:1af8:be8) (Read error: Connection reset by peer) |
| 00:47:34 | → | pop3 joins (~pop3@user/pop3) |
| 00:48:39 | → | Inst joins (~Inst@c-98-208-218-119.hsd1.fl.comcast.net) |
| 00:49:25 | × | haritz quits (~hrtz@user/haritz) (Quit: ZNC 1.7.2+deb3 - https://znc.in) |
| 00:50:57 | → | wroathe joins (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) |
| 00:50:57 | × | wroathe quits (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Changing host) |
| 00:50:57 | → | wroathe joins (~wroathe@user/wroathe) |
| 00:54:11 | <hippoid> | Bifunctor https://hackage.haskell.org/package/base-4.16.0.0/docs/src/Data.Bifunctor.html#Bifunctor has a default implementation for first, second, and bimap. first uses bimap, and bimap uses first, and I don't know how to think about this |
| 00:54:41 | <hippoid> | My naive thought is that this results in a kind of infinite loop, but that can't be right |
| 00:55:01 | <geekosaur> | there will also be a MINIMAL pragma |
| 00:55:33 | <geekosaur> | the idea is, if you implement either one you get the other for free. the MINIMAL pragma ensures that at least one of them must be defined |
| 00:55:48 | × | cigsender quits (~cigsender@74.124.58.162) (Quit: Lost terminal) |
| 00:55:52 | <hippoid> | geekosaur: ahh, interesting |
| 00:55:53 | <geekosaur> | implement in an instance, that is |
| 00:55:58 | × | wroathe quits (~wroathe@user/wroathe) (Ping timeout: 268 seconds) |
| 00:55:58 | × | CannabisIndica quits (~herb@user/mesaboogie) (Ping timeout: 260 seconds) |
| 00:56:13 | <geekosaur> | the ones provided in the class declaration are only used if an instance doesn't define that method |
| 00:56:45 | <hippoid> | so any instance must provide at least bimap, or first and second? |
| 00:56:57 | <geekosaur> | yes |
| 00:57:14 | <hippoid> | thanks, i dont think i would have ever figured that out! |
| 00:59:37 | → | dsamperi joins (~dsamperi@2603-7000-3b42-5400-ad06-78d6-67f9-46d9.res6.spectrum.com) |
| 01:01:51 | × | juhp quits (~juhp@128.106.188.220) (Quit: juhp) |
| 01:01:58 | → | haritz joins (~hrtz@2a02:8010:65b5:0:6009:6384:e3cb:2220) |
| 01:01:58 | × | haritz quits (~hrtz@2a02:8010:65b5:0:6009:6384:e3cb:2220) (Changing host) |
| 01:01:58 | → | haritz joins (~hrtz@user/haritz) |
| 01:02:05 | → | juhp joins (~juhp@128.106.188.220) |
| 01:02:55 | × | pop3 quits (~pop3@user/pop3) (Remote host closed the connection) |
| 01:03:23 | → | pop3 joins (~pop3@user/pop3) |
| 01:04:55 | × | lbseale_ quits (~lbseale@user/ep1ctetus) (Read error: Connection reset by peer) |
| 01:06:06 | × | juhp quits (~juhp@128.106.188.220) (Client Quit) |
| 01:06:21 | → | juhp joins (~juhp@128.106.188.220) |
| 01:06:26 | <boxscape_> | hippoid: simpler example: Eq has (==) = not (/=) as well as (/=) = not (==) |
| 01:06:30 | × | stiell quits (~stiell@gateway/tor-sasl/stiell) (Ping timeout: 276 seconds) |
| 01:07:02 | → | danso joins (~danso@23-233-111-52.cpe.pppoe.ca) |
| 01:07:13 | <geekosaur> | and a MINIMAL pragma specifying that at least one of those must be defined by an instance |
| 01:07:16 | → | stiell joins (~stiell@gateway/tor-sasl/stiell) |
| 01:07:31 | × | Guest41 quits (~Guest41@eth-west-pareq2-46-193-4-100.wb.wifirst.net) (Ping timeout: 256 seconds) |
| 01:08:08 | <mjrosenb> | Data.Set.mapMonotonic, fst is monotonic as long as (x,a) and (x,b) aren't in the set, right? |
| 01:12:10 | × | hippoid quits (~idris@184.105.6.88) (Quit: leaving) |
| 01:12:11 | → | lavaman joins (~lavaman@98.38.249.169) |
| 01:12:34 | → | hippoid joins (~idris@184.105.6.88) |
| 01:12:40 | <boxscape_> | mjrosenb that sounds right to me |
| 01:14:32 | → | azimut_ joins (~azimut@gateway/tor-sasl/azimut) |
| 01:14:53 | × | nehsou^ quits (~nehsou@wsip-98-188-242-6.mc.at.cox.net) (Remote host closed the connection) |
| 01:14:57 | × | azimut quits (~azimut@gateway/tor-sasl/azimut) (Ping timeout: 276 seconds) |
| 01:16:55 | × | lavaman quits (~lavaman@98.38.249.169) (Ping timeout: 268 seconds) |
| 01:17:13 | × | alzgh quits (~alzgh@user/alzgh) (Remote host closed the connection) |
| 01:21:07 | → | merijn joins (~merijn@83-160-49-249.ip.xs4all.nl) |
| 01:24:03 | × | Khelben quits (~Khelben@2001:818:e316:e700:85c9:6d4e:a6d0:2b03) (Remote host closed the connection) |
| 01:24:47 | → | nrl^ joins (~nrl@wsip-98-188-242-6.mc.at.cox.net) |
| 01:25:26 | × | Inst quits (~Inst@c-98-208-218-119.hsd1.fl.comcast.net) (Quit: Leaving) |
| 01:26:43 | → | Inst joins (~Inst@c-98-208-218-119.hsd1.fl.comcast.net) |
| 01:27:19 | × | epolanski quits (uid312403@id-312403.helmsley.irccloud.com) (Quit: Connection closed for inactivity) |
| 01:32:58 | × | ByronJohnson quits (~bairyn@50-250-232-19-static.hfc.comcastbusiness.net) (Ping timeout: 268 seconds) |
| 01:37:13 | × | Tuplanolla quits (~Tuplanoll@91-159-69-50.elisa-laajakaista.fi) (Quit: Leaving.) |
| 01:38:44 | × | dsamperi quits (~dsamperi@2603-7000-3b42-5400-ad06-78d6-67f9-46d9.res6.spectrum.com) (Quit: Konversation terminated!) |
| 01:41:17 | × | doyougnu quits (~doyougnu@c-73-25-202-122.hsd1.or.comcast.net) (Remote host closed the connection) |
| 01:43:55 | × | bitmapper quits (uid464869@id-464869.lymington.irccloud.com) (Quit: Connection closed for inactivity) |
| 01:55:14 | × | merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 260 seconds) |
| 01:56:53 | × | mmhat quits (~mmh@55d4baf7.access.ecotel.net) (Quit: WeeChat 3.3) |
| 02:00:55 | → | CannabisIndica joins (~herb@user/mesaboogie) |
| 02:05:28 | × | CannabisIndica quits (~herb@user/mesaboogie) (Client Quit) |
| 02:08:51 | → | CannabisIndica joins (~herb@user/mesaboogie) |
| 02:10:15 | × | pop3 quits (~pop3@user/pop3) (Remote host closed the connection) |
| 02:11:27 | → | pop3 joins (~pop3@user/pop3) |
| 02:12:41 | × | Cajun quits (~Cajun@user/cajun) (Quit: Client closed) |
| 02:13:13 | × | biberu quits (~biberu@user/biberu) (Read error: Connection reset by peer) |
| 02:13:22 | → | lavaman joins (~lavaman@98.38.249.169) |
| 02:13:33 | → | biberu joins (~biberu@user/biberu) |
| 02:16:19 | × | eggplantade quits (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Remote host closed the connection) |
| 02:16:31 | → | myShoggoth joins (~myShoggot@97-120-85-195.ptld.qwest.net) |
| 02:19:49 | → | slaydr joins (~slaydr@45.131.194.34) |
| 02:20:01 | → | yauhsien joins (~yauhsien@118-167-41-229.dynamic-ip.hinet.net) |
| 02:20:35 | → | eggplantade joins (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) |
| 02:26:01 | × | yauhsien quits (~yauhsien@118-167-41-229.dynamic-ip.hinet.net) (Remote host closed the connection) |
| 02:27:00 | → | yauhsien joins (~yauhsien@118-167-41-229.dynamic-ip.hinet.net) |
| 02:28:06 | → | kupi joins (uid212005@id-212005.hampstead.irccloud.com) |
| 02:31:53 | → | fvr joins (uid503686@id-503686.uxbridge.irccloud.com) |
| 02:32:10 | × | yauhsien quits (~yauhsien@118-167-41-229.dynamic-ip.hinet.net) (Ping timeout: 268 seconds) |
| 02:32:20 | → | hololeap_ joins (~hololeap@user/hololeap) |
| 02:33:36 | × | hololeap quits (~hololeap@user/hololeap) (Ping timeout: 276 seconds) |
| 02:33:50 | × | kronicmage quits (user28253@neotame.csclub.uwaterloo.ca) (Quit: WeeChat 3.0.1) |
| 02:34:01 | → | kronicmage joins (user72429@neotame.csclub.uwaterloo.ca) |
| 02:35:43 | × | eggplantade quits (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Remote host closed the connection) |
| 02:35:43 | × | MQ-17J quits (~MQ-17J@d192-24-122-179.try.wideopenwest.com) (Read error: Connection reset by peer) |
| 02:36:39 | → | MQ-17J joins (~MQ-17J@8.6.144.203) |
| 02:43:46 | → | ByronJohnson joins (~bairyn@50-250-232-19-static.hfc.comcastbusiness.net) |
| 02:48:12 | × | xff0x quits (~xff0x@port-92-193-245-245.dynamic.as20676.net) (Ping timeout: 268 seconds) |
| 02:49:29 | → | xff0x joins (~xff0x@2001:1a81:5236:1e00:a124:ca01:b87f:741d) |
| 02:55:46 | → | juri_ joins (~juri@178.63.35.222) |
| 02:59:18 | <dsal> | What's that gross hack for exposing a constructor without allowing pattern matching on it? i.e., I want to be able to make things, but not take them apart. |
| 02:59:54 | × | neurocyte0132889 quits (~neurocyte@user/neurocyte) (Ping timeout: 268 seconds) |
| 03:01:21 | <dsal> | I guess I'm thinking of the one where you expose the record accessor functions without the constructor. Right now, I've just `something = Something`. I guess that'll do. |
| 03:03:44 | → | bilegeek joins (~bilegeek@2600:1008:b00f:bd9f:b35d:f157:9cec:ab62) |
| 03:04:54 | → | eggplantade joins (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) |
| 03:12:51 | × | rekahsoft quits (~rekahsoft@cpe0008a20f982f-cm64777d666260.cpe.net.cable.rogers.com) (Ping timeout: 268 seconds) |
| 03:17:46 | × | alx741 quits (~alx741@186.178.109.189) (Quit: alx741) |
| 03:20:02 | <sm> | https://www.reddit.com/r/haskell/comments/qm9lra/stack_dependency_hell/hj8lbdh/ - GHC doesn't allow linking with multiple versions of a package because it does whole-program compilation, which is where much of the speed comes from - am I right ? |
| 03:20:51 | <sm> | and if so, does rust not do whole-program compilation (doesn't need to ?) |
| 03:21:39 | <monochrom> | No, actually GHC allows it as much as possible. (There are still very understandable limits.) cabal-install is the one that plays it very safe and insists on uniqueness. |
| 03:21:58 | <boxscape_> | sm: that seems hard to believe considering there's a project to make GHC become a whole-project compiler https://github.com/grin-compiler/ghc-whole-program-compiler-project |
| 03:22:09 | <boxscape_> | s/whole-project/whole-program |
| 03:22:13 | <monochrom> | And stack, stack doesn't even want you to use hackage. |
| 03:22:26 | <sm> | ohh.. better edit my answer |
| 03:22:43 | × | euandreh quits (~euandreh@2804:14c:33:9fe5:3a97:eaba:c01a:d700) (Ping timeout: 268 seconds) |
| 03:23:36 | → | euandreh joins (~euandreh@2804:14c:33:9fe5:25ae:baa7:4680:70ca) |
| 03:23:50 | sm | was wrong on the internet for a sec |
| 03:24:07 | <sm> | stack has no problem using hackage |
| 03:24:30 | sm | saves monochrom from being wrong on the internet |
| 03:24:50 | <monochrom> | I said "want" not "problem". |
| 03:26:40 | <monochrom> | The intention of a program's authors can be mostly gleaned from defaults, the design of the config files, how easy it is to do certain things and how hard to do certain other "no problem in theory" things. |
| 03:26:45 | <sm> | and cabal doesn't allow linking with multiple versions of a package because... ? it is something optimisation related isn't it ? |
| 03:27:35 | <monochrom> | Even the language Haskell itself, you can feel it doesn't want you to use IO for everything, even though "there is no problem". My saying "doesn't want" is justifiable, very right, not wrong at all. |
| 03:27:36 | <sclv> | its because its extremely hard to express |
| 03:28:04 | <monochrom> | It plays it very safe. That's all. |
| 03:28:05 | → | bhrgunatha joins (~bhrgunath@2001-b011-8005-cec6-1c67-2ef9-44d3-785b.dynamic-ip6.hinet.net) |
| 03:28:24 | × | bhrgunatha quits (~bhrgunath@2001-b011-8005-cec6-1c67-2ef9-44d3-785b.dynamic-ip6.hinet.net) (Remote host closed the connection) |
| 03:29:01 | → | shriekingnoise_ joins (~shrieking@186.137.144.80) |
| 03:29:02 | <remexre> | what's the technique called where you treat ([a] -> [a]) as a "chunk" of a linked list for concatenating using composition? |
| 03:29:11 | × | shapr quits (~user@pool-100-36-247-68.washdc.fios.verizon.net) (Ping timeout: 264 seconds) |
| 03:29:23 | sm | installs things from hackage with stack all the time, per docs (https://docs.haskellstack.org/en/stable/build_command/#target-syntax), but YMMV :) |
| 03:29:38 | <dsal> | remexre: Like a DList? |
| 03:29:52 | <remexre> | ah, yep, that's it! |
| 03:30:08 | × | shriekingnoise quits (~shrieking@186.137.144.80) (Ping timeout: 268 seconds) |
| 03:30:09 | <monochrom> | I even know a blog that says Haskell beginners should stay in IO all the time. |
| 03:30:31 | <monochrom> | Again, I'm talking about "want" not "legal". |
| 03:32:11 | <monochrom> | I know this because I write programs that are biased, too. |
| 03:32:30 | <dolio> | Someone should come up with a different name for DList. |
| 03:32:48 | <dolio> | Like Cayley list or something. |
| 03:33:30 | <monochrom> | My https://github.com/treblacy/hasdoc chooses to make it easier to look up by package name, harder to look up by module name (you have to add a non-default -m switch). |
| 03:34:28 | <monochrom> | One can make the case of "but I add -m all the time". That still doesn't contradict the author's bias that the author thinks that package name is more common. |
| 03:36:30 | × | machinedgod quits (~machinedg@135-23-192-217.cpe.pppoe.ca) (Ping timeout: 260 seconds) |
| 03:38:47 | × | MQ-17J quits (~MQ-17J@8.6.144.203) (Read error: Connection reset by peer) |
| 03:40:40 | → | jollygood2 joins (~bc8165b6@217.29.117.252) |
| 03:42:17 | × | FinnElija quits (~finn_elij@user/finn-elija/x-0085643) (Killed (NickServ (Forcing logout FinnElija -> finn_elija))) |
| 03:42:17 | → | finn_elija joins (~finn_elij@user/finn-elija/x-0085643) |
| 03:42:17 | finn_elija | is now known as FinnElija |
| 03:42:48 | <jollygood2> | monochrom, what does stackage want you to use, then? I thought it is 100% dependent on libraries on hackage. or maybe I misunderstand what you mean |
| 03:43:09 | <dolio> | Stack wants you to use stackage. |
| 03:44:03 | <jollygood2> | stackage is a curated collection of hackage libraries |
| 03:44:04 | <monochrom> | One of those times when "white horse is not horse" makes sense. |
| 03:44:05 | → | MQ-17J joins (~MQ-17J@8.6.144.203) |
| 03:44:54 | <monochrom> | hackage is not curated. |
| 03:45:32 | × | fizzsegfaultbuzz quits (~segfaultf@135-180-0-138.static.sonic.net) (Ping timeout: 268 seconds) |
| 03:47:06 | × | boxscape_ quits (~boxscape_@i59F67A7D.versanet.de) (Quit: Connection closed) |
| 03:47:28 | <monochrom> | There is also a forgetful functor from Hask to Set. This still does not contradict "Hask is not Set" or even "Haskell semantists don't want you to think of sets". |
| 03:49:59 | × | [_] quits (~itchyjunk@user/itchyjunk/x-7353470) (Remote host closed the connection) |
| 03:51:11 | <dolio> | Well, that may or may not be true, depending on what you're doing. |
| 03:51:22 | <monochrom> | heh |
| 03:51:31 | <dolio> | Hask might be too awesome to be contained in sets. |
| 03:51:41 | → | merijn joins (~merijn@83-160-49-249.ip.xs4all.nl) |
| 03:52:21 | <monochrom> | I'm sure my students think of "the Int type is a set" all the time. And my course doesn't go deep enough, so I let them, it works fine in the context of my pretty introductory course. |
| 03:54:54 | <monochrom> | Well, I guess Int is not a very illustrative example, it's almost a set. When you get to [Int]->[Int] it begins to break more. |
| 03:55:30 | <dolio> | The big problems are stuff like `data T = C ((T -> Bool) -> Bool)` |
| 03:55:41 | <monochrom> | Yeah. |
| 04:00:42 | → | yauhsien joins (~yauhsien@118-167-41-229.dynamic-ip.hinet.net) |
| 04:05:53 | × | yauhsien quits (~yauhsien@118-167-41-229.dynamic-ip.hinet.net) (Ping timeout: 268 seconds) |
| 04:09:36 | <sm> | jollygood2: stack wants your build/install commands to be repeatable, so it requires you to to either use packages in the specified stackage snapshot, or if you use hackage packages not in the snapshot, to explicitly name them and their versions |
| 04:10:07 | <sm> | (in an extra-deps list in package.yaml or on the command line) |
| 04:25:08 | → | mbuf joins (~Shakthi@122.174.233.21) |
| 04:26:15 | × | merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 268 seconds) |
| 04:29:20 | × | waleee quits (~waleee@h-98-128-228-119.NA.cust.bahnhof.se) (Ping timeout: 268 seconds) |
| 04:41:41 | × | fvr quits (uid503686@id-503686.uxbridge.irccloud.com) (Quit: Connection closed for inactivity) |
| 04:47:15 | × | ahlk quits (~user@2600:1700:31c0:3a10::43) (Read error: Connection reset by peer) |
| 04:47:47 | × | kupi quits (uid212005@id-212005.hampstead.irccloud.com) (Quit: Connection closed for inactivity) |
| 04:53:59 | × | Vajb quits (~Vajb@2001:999:66:281c:27a0:1549:39e5:8b1a) (Read error: Connection reset by peer) |
| 04:54:17 | → | Vajb joins (~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) |
| 05:06:21 | → | shidima joins (~shidima@84-104-108-90.cable.dynamic.v4.ziggo.nl) |
| 05:09:48 | × | nattiestnate quits (~nate@2001:448a:20a0:4134:25e:715f:d637:5263) (Quit: WeeChat 3.3) |
| 05:10:37 | → | nattiestnate joins (~nate@2001:448a:20a0:4134:25e:715f:d637:5263) |
| 05:22:03 | × | nattiestnate quits (~nate@2001:448a:20a0:4134:25e:715f:d637:5263) (Quit: WeeChat 3.3) |
| 05:24:50 | × | slowButPresent quits (~slowButPr@user/slowbutpresent) (Quit: leaving) |
| 05:31:26 | → | wei2912 joins (~wei2912@138.75.71.147) |
| 05:36:33 | × | betelgeuse quits (~betelgeus@94-225-47-8.access.telenet.be) (Ping timeout: 268 seconds) |
| 05:37:17 | → | betelgeuse joins (~betelgeus@94-225-47-8.access.telenet.be) |
| 05:39:37 | → | mei joins (~mei@user/mei) |
| 05:39:59 | × | emf_ quits (~emf@2620:10d:c090:400::5:5f62) (Ping timeout: 264 seconds) |
| 05:41:51 | → | Jing joins (~textual@2604:a840:3::10f2) |
| 05:45:52 | × | mei quits (~mei@user/mei) (Read error: Connection reset by peer) |
| 05:53:14 | × | shailangsa quits (~shailangs@host217-39-45-200.range217-39.btcentralplus.com) (Ping timeout: 260 seconds) |
| 05:56:53 | × | myShoggoth quits (~myShoggot@97-120-85-195.ptld.qwest.net) (Ping timeout: 268 seconds) |
| 05:57:20 | → | alzgh joins (~alzgh@user/alzgh) |
| 05:58:08 | × | Vajb quits (~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) (Ping timeout: 268 seconds) |
| 06:00:03 | → | Vajb joins (~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) |
| 06:01:02 | <energizer> | what is the implementation of fmap for List? |
| 06:01:51 | <energizer> | (or does the question not make sense) |
| 06:02:50 | <Axman6> | @ :t fmap @[] |
| 06:02:56 | <Axman6> | % :t fmap @[] |
| 06:02:56 | <yahb> | Axman6: (a -> b) -> [a] -> [b] |
| 06:03:05 | <Axman6> | does that type look familliar to you? |
| 06:04:13 | <Axman6> | That definitewly sounds like a homework question to me, so sorry for not giving you the answer outright |
| 06:04:44 | → | bitmapper joins (uid464869@id-464869.lymington.irccloud.com) |
| 06:05:00 | <energizer> | not homework, i'm trying to understand a blog post that uses `deriving Functor` |
| 06:06:15 | <Axman6> | well, fmap :: (a -> b) -> f a -> f b, we can replace f with [] if we think it _can_ be a functor and see if we can write that function. doing that, we get fmap :: (a -> b) -> [a] -> [b] |
| 06:06:46 | <Axman6> | what behaviour do you expect fmap to have when used on a list? what would fmap show [1,2,3] return? |
| 06:07:58 | <energizer> | [show 1, show 2, show 3] |
| 06:08:16 | × | Vajb quits (~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) (Read error: Connection reset by peer) |
| 06:08:46 | <Axman6> | which would be ["1","2","3"] yeah? |
| 06:08:56 | <Axman6> | > fmap show [1,2,3] -- It is! |
| 06:08:58 | <lambdabot> | ["1","2","3"] |
| 06:09:55 | <Axman6> | so, what do you expect fmap show [] to return? |
| 06:10:08 | <energizer> | [] |
| 06:10:15 | <Axman6> | or, even better, that do you expect fmap f [] = ? |
| 06:10:18 | <Axman6> | great |
| 06:10:37 | <Axman6> | so, fmap f [] = [], we're half way there, since lists only have two constructors |
| 06:10:58 | <energizer> | fmap f x:xs = f x : fmap f xs |
| 06:10:59 | <Axman6> | what about the other constructor, (:)? fmap f (x : xs) = ??? |
| 06:11:16 | <Axman6> | close enough, needs brackets around (x:xs), but that's it |
| 06:11:56 | <energizer> | alright cool |
| 06:12:16 | → | Vajb joins (~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) |
| 06:12:59 | <Axman6> | to be sure, you should also check the Functor laws hold: fmap id xs = xs, and fmap f (fmap g xs) = fmap (f . g) xs |
| 06:15:49 | × | Vajb quits (~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) (Read error: Connection reset by peer) |
| 06:16:02 | → | Vajb joins (~Vajb@85-76-35-250-nat.elisa-mobile.fi) |
| 06:17:35 | × | zebrag quits (~chris@user/zebrag) (Remote host closed the connection) |
| 06:19:01 | → | yauhsien joins (~yauhsien@118-167-41-229.dynamic-ip.hinet.net) |
| 06:22:04 | → | merijn joins (~merijn@83-160-49-249.ip.xs4all.nl) |
| 06:24:02 | × | yauhsien quits (~yauhsien@118-167-41-229.dynamic-ip.hinet.net) (Ping timeout: 268 seconds) |
| 06:29:21 | × | Vajb quits (~Vajb@85-76-35-250-nat.elisa-mobile.fi) (Read error: Connection reset by peer) |
| 06:29:36 | → | Vajb joins (~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) |
| 06:30:01 | × | bilegeek quits (~bilegeek@2600:1008:b00f:bd9f:b35d:f157:9cec:ab62) (Quit: Leaving) |
| 06:32:20 | <awpr> | https://hackage.haskell.org/package/base-4.16.0.0/docs/Data-Type-Ord.html#t:-60- interesting definition, that |
| 06:33:32 | → | shailangsa joins (~shailangs@host86-185-98-19.range86-185.btcentralplus.com) |
| 06:33:56 | → | pretty_dumm_guy joins (trottel@gateway/vpn/protonvpn/prettydummguy/x-88029655) |
| 06:35:52 | → | Gurkenglas joins (~Gurkengla@dslb-002-203-144-204.002.203.pools.vodafone-ip.de) |
| 06:37:16 | → | jonathanx joins (~jonathan@dyn-8-sc.cdg.chalmers.se) |
| 06:42:58 | → | cosimone joins (~user@2001:b07:ae5:db26:a7aa:8027:6b4e:2fb3) |
| 06:43:11 | → | fvr joins (uid503686@id-503686.uxbridge.irccloud.com) |
| 06:50:10 | × | shidima quits (~shidima@84-104-108-90.cable.dynamic.v4.ziggo.nl) (Ping timeout: 260 seconds) |
| 06:53:03 | × | tzh quits (~tzh@c-24-21-73-154.hsd1.wa.comcast.net) (Remote host closed the connection) |
| 06:56:32 | × | merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 256 seconds) |
| 07:02:36 | <Axman6> | that... doesn't look right |
| 07:03:21 | × | cosimone quits (~user@2001:b07:ae5:db26:a7aa:8027:6b4e:2fb3) (Quit: ERC (IRC client for Emacs 27.1)) |
| 07:03:41 | <awpr> | nbd for me, I can just leave it behind while turning https://hackage.haskell.org/package/numeric-kinds-0.1.0.0/docs/Kinds-Num.html into a compatibility shim |
| 07:03:48 | <awpr> | and seems to be already fixed in git |
| 07:04:03 | → | cosimone joins (~user@93-44-187-173.ip98.fastwebnet.it) |
| 07:04:37 | → | takuan joins (~takuan@178-116-218-225.access.telenet.be) |
| 07:05:35 | → | dhouthoo joins (~dhouthoo@178-117-36-167.access.telenet.be) |
| 07:11:02 | × | eggplantade quits (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Remote host closed the connection) |
| 07:12:45 | → | michalz joins (~michalz@185.246.204.109) |
| 07:14:48 | × | morphism quits (~ret@86.57.6.225) (Quit: WeeChat 3.3) |
| 07:16:32 | × | econo quits (uid147250@user/econo) (Quit: Connection closed for inactivity) |
| 07:24:10 | → | whatsupdoc joins (uid509081@id-509081.hampstead.irccloud.com) |
| 07:24:17 | <whatsupdoc> | <hint>:1:3: parse error on input ‘=’ |
| 07:28:24 | → | acidjnk_new joins (~acidjnk@p200300d0c726702918431f3aede9e057.dip0.t-ipconnect.de) |
| 07:36:16 | <Inst> | oh yeah, awpr, this is the "blowhard" i was talking about |
| 07:39:30 | → | fendor joins (~fendor@178.115.63.67.wireless.dyn.drei.com) |
| 07:47:13 | → | max22- joins (~maxime@lfbn-ren-1-762-224.w81-53.abo.wanadoo.fr) |
| 08:00:11 | → | trcc joins (~trcc@users-1190.st.net.au.dk) |
| 08:00:37 | → | merijn joins (~merijn@83-160-49-249.ip.xs4all.nl) |
| 08:03:21 | → | trcc_ joins (~trcc@users-1190.st.net.au.dk) |
| 08:04:32 | × | trcc quits (~trcc@users-1190.st.net.au.dk) (Ping timeout: 260 seconds) |
| 08:05:18 | → | dschrempf joins (~dominik@070-207.dynamic.dsl.fonira.net) |
| 08:05:24 | → | hendursa1 joins (~weechat@user/hendursaga) |
| 08:05:25 | → | gehmehgeh joins (~user@user/gehmehgeh) |
| 08:07:41 | × | niko quits (~niko@libera/staff/niko) (Remote host closed the connection) |
| 08:07:42 | × | hendursaga quits (~weechat@user/hendursaga) (Ping timeout: 276 seconds) |
| 08:10:05 | → | shidima joins (~shidima@83.232.63.181) |
| 08:11:38 | → | eggplantade joins (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) |
| 08:16:26 | × | eggplantade quits (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 256 seconds) |
| 08:17:27 | × | geekosaur quits (~geekosaur@xmonad/geekosaur) (Remote host closed the connection) |
| 08:17:51 | → | geekosaur joins (~geekosaur@xmonad/geekosaur) |
| 08:20:23 | → | chele joins (~chele@user/chele) |
| 08:23:22 | → | nschoe joins (~quassel@178.251.84.79) |
| 08:25:12 | → | lortabac joins (~lortabac@2a01:e0a:541:b8f0:ac85:493a:6db9:7a0f) |
| 08:27:10 | → | o joins (~niko@libera/staff/niko) |
| 08:32:16 | → | johnny_sitar joins (~artur@078088015209.bialystok.vectranet.pl) |
| 08:35:03 | × | timCF quits (~timCF@200-149-20-81.sta.estpak.ee) (Quit: leaving) |
| 08:36:45 | × | Sgeo quits (~Sgeo@user/sgeo) (Read error: Connection reset by peer) |
| 08:38:54 | × | Inst quits (~Inst@c-98-208-218-119.hsd1.fl.comcast.net) (Ping timeout: 260 seconds) |
| 08:43:48 | × | lavaman quits (~lavaman@98.38.249.169) (Remote host closed the connection) |
| 08:44:03 | → | lavaman joins (~lavaman@98.38.249.169) |
| 08:44:10 | × | lavaman quits (~lavaman@98.38.249.169) (Remote host closed the connection) |
| 08:44:24 | × | jollygood2 quits (~bc8165b6@217.29.117.252) (Quit: http://www.okay.uz/ (Session timeout)) |
| 08:46:26 | → | Inst joins (~Inst@2601:6c4:4080:3f80:cd36:4dbb:1af8:be8) |
| 08:53:20 | × | gdown quits (~gavin@h69-11-248-109.kndrid.broadband.dynamic.tds.net) (Remote host closed the connection) |
| 08:54:59 | → | __monty__ joins (~toonn@user/toonn) |
| 09:02:36 | × | fendor quits (~fendor@178.115.63.67.wireless.dyn.drei.com) (Remote host closed the connection) |
| 09:03:19 | × | cads quits (~cads@ip-64-72-99-234.lasvegas.net) (Quit: Leaving) |
| 09:06:39 | → | fendor joins (~fendor@178.115.63.67.wireless.dyn.drei.com) |
| 09:07:18 | → | wonko joins (~wjc@user/wonko) |
| 09:11:51 | → | kadir joins (~kadir@95.7.9.203) |
| 09:19:45 | → | mc47 joins (~mc47@xmonad/TheMC47) |
| 09:20:56 | <mc47> | geekosaur: the #xmonad-unlogged message is also displayed here |
| 09:23:05 | × | bitmapper quits (uid464869@id-464869.lymington.irccloud.com) (Quit: Connection closed for inactivity) |
| 09:23:17 | × | azeem quits (~azeem@2a00:801:3cb:bcc0:53ee:32be:de18:8352) (Read error: Connection reset by peer) |
| 09:24:11 | → | azeem joins (~azeem@emp-89-199.eduroam.uu.se) |
| 09:25:09 | <mc47> | And not displayed in #xmonad |
| 09:25:44 | × | mc47 quits (~mc47@xmonad/TheMC47) (Remote host closed the connection) |
| 09:26:14 | → | kuribas joins (~user@ptr-25vy0i85hqqtidw9mko.18120a2.ip6.access.telenet.be) |
| 09:30:15 | × | shriekingnoise_ quits (~shrieking@186.137.144.80) (Quit: Quit) |
| 09:31:50 | → | fendor_ joins (~fendor@178.115.63.67.wireless.dyn.drei.com) |
| 09:32:07 | × | fendor quits (~fendor@178.115.63.67.wireless.dyn.drei.com) (Ping timeout: 268 seconds) |
| 09:35:17 | × | Arsen quits (~arsen@managarm/dev/Arsen) (Quit: Quit.) |
| 09:35:40 | → | Arsen joins (~arsen@managarm/dev/Arsen) |
| 09:36:19 | → | cfricke joins (~cfricke@user/cfricke) |
| 09:36:25 | × | xff0x quits (~xff0x@2001:1a81:5236:1e00:a124:ca01:b87f:741d) (Remote host closed the connection) |
| 09:36:41 | → | xff0x joins (~xff0x@2001:1a81:5236:1e00:ed13:7d8f:8a23:addd) |
| 09:36:59 | → | yauhsien joins (~yauhsien@118-167-41-229.dynamic-ip.hinet.net) |
| 09:39:34 | × | yauhsien quits (~yauhsien@118-167-41-229.dynamic-ip.hinet.net) (Remote host closed the connection) |
| 09:39:34 | → | aleator joins (~aleator@176-93-61-167.bb.dnainternet.fi) |
| 09:39:51 | × | ubert quits (~Thunderbi@p548c9652.dip0.t-ipconnect.de) (Quit: ubert) |
| 09:41:20 | <aleator> | Hi! I'm seeking help with haskell.nix. I get "anonymous function at ... called without required argument '<one of my dependencies>' at .. make-package-set.nix:87:27" Would anyone happen to know what this could be about? |
| 09:42:43 | <dminuoso> | aleator: As with nix, it's hard to say in general |
| 09:43:02 | <dminuoso> | Your best luck is using --show-trace, look at the source/line/column of various points in the stack trace |
| 09:43:05 | <dminuoso> | and determine what's going on |
| 09:43:24 | <dminuoso> | Could be anything ranging from "mismatching arguments", forgot an argument, an argument too much, you stuff the wrong thing in the wrong place |
| 09:45:15 | <aleator> | dminuoso: Yeah. I had hoped this to be something familiar to someone. All the related bits seem to be generated by haskell.nix infrastructure. And everything works until I add a that specific dependency, after which it doesn't. |
| 09:45:37 | <aleator> | Builds with stack though. |
| 09:46:31 | <dminuoso> | aleator: Can you show the diff from the smallest portion that introduces that error? |
| 09:48:24 | <aleator> | dminuoso: With some work, yeah. I'll need to do bit of work to get there though. |
| 09:50:05 | × | Arsen quits (~arsen@managarm/dev/Arsen) (Quit: Quit.) |
| 09:50:20 | → | Arsen joins (~arsen@managarm/dev/Arsen) |
| 09:51:38 | × | Arsen quits (~arsen@managarm/dev/Arsen) (Client Quit) |
| 09:51:53 | → | Arsen joins (~arsen@managarm/dev/Arsen) |
| 09:53:38 | × | tcard_ quits (~tcard@p2878075-ipngn18701hodogaya.kanagawa.ocn.ne.jp) (Quit: Leaving) |
| 09:56:39 | × | Arsen quits (~arsen@managarm/dev/Arsen) (Client Quit) |
| 09:57:53 | → | tcard joins (~tcard@p2878075-ipngn18701hodogaya.kanagawa.ocn.ne.jp) |
| 09:58:35 | × | xff0x quits (~xff0x@2001:1a81:5236:1e00:ed13:7d8f:8a23:addd) (Ping timeout: 264 seconds) |
| 09:58:53 | → | xff0x joins (~xff0x@2001:1a81:5236:1e00:8d66:5d08:1338:5e80) |
| 09:59:06 | × | Unhammer quits (~Unhammer@user/unhammer) (Ping timeout: 260 seconds) |
| 10:03:54 | × | cfricke quits (~cfricke@user/cfricke) (Quit: WeeChat 3.3) |
| 10:04:59 | → | Arsen joins (arsen@managarm/dev/Arsen) |
| 10:05:01 | → | shidima_ joins (~shidima@46.44.183.25) |
| 10:07:51 | × | shidima quits (~shidima@83.232.63.181) (Read error: Connection reset by peer) |
| 10:08:20 | → | zer0bitz joins (~zer0bitz@dsl-hkibng31-54fae3-116.dhcp.inet.fi) |
| 10:08:55 | → | ubert joins (~Thunderbi@2a02:8109:9880:303c:ca5b:76ff:fe29:f233) |
| 10:10:26 | → | yauhsien joins (~yauhsien@118-167-41-229.dynamic-ip.hinet.net) |
| 10:12:36 | → | Unhammer joins (~Unhammer@user/unhammer) |
| 10:13:41 | → | eggplantade joins (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) |
| 10:15:26 | × | yauhsien quits (~yauhsien@118-167-41-229.dynamic-ip.hinet.net) (Ping timeout: 256 seconds) |
| 10:18:16 | × | eggplantade quits (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 256 seconds) |
| 10:39:32 | × | Neuromancer quits (~Neuromanc@user/neuromancer) (Remote host closed the connection) |
| 10:39:48 | × | dschrempf quits (~dominik@070-207.dynamic.dsl.fonira.net) (Ping timeout: 256 seconds) |
| 10:41:43 | × | ubert quits (~Thunderbi@2a02:8109:9880:303c:ca5b:76ff:fe29:f233) (Remote host closed the connection) |
| 10:41:44 | × | gentauro quits (~gentauro@user/gentauro) (Read error: Connection reset by peer) |
| 10:43:45 | → | abrantesasf joins (abrantesas@gateway/vpn/protonvpn/abrantesasf) |
| 10:45:39 | → | ubert joins (~Thunderbi@2a02:8109:9880:303c:ca5b:76ff:fe29:f233) |
| 10:46:59 | → | Feuermagier joins (~Feuermagi@user/feuermagier) |
| 10:47:22 | → | gentauro joins (~gentauro@user/gentauro) |
| 10:48:39 | → | Everything joins (~Everythin@37.115.210.35) |
| 10:48:51 | → | fusion86 joins (~fusion@2a02-a44c-e6e5-1-768d-77d5-1db4-35ae.fixed6.kpn.net) |
| 10:50:55 | → | Cajun joins (~Cajun@user/cajun) |
| 10:51:20 | → | mmhat joins (~mmh@55d4a8dc.access.ecotel.net) |
| 10:51:41 | × | fvr quits (uid503686@id-503686.uxbridge.irccloud.com) (Quit: Connection closed for inactivity) |
| 10:54:38 | → | yauhsien joins (~yauhsien@118-167-41-229.dynamic-ip.hinet.net) |
| 10:54:49 | <geekosaur> | mc47, that's odd, I set it in #xmonad and glguy set the message here because I don't have perms |
| 10:57:41 | <geekosaur> | hrm, may be your client. hexchat decided to display the notices in my chanserv tab, and otherwise displays them somewhat randomly |
| 10:57:56 | <geekosaur> | (notices are poorly handled by hexchat, I've noticed) |
| 10:58:58 | → | Lycurgus joins (~juan@98.4.112.204) |
| 10:59:39 | → | boxscape_ joins (~boxscape_@vpn-44-229.hq.eso.org) |
| 11:00:53 | → | alx741 joins (~alx741@186.178.109.189) |
| 11:05:17 | hololeap_ | is now known as hololeap |
| 11:08:38 | × | lortabac quits (~lortabac@2a01:e0a:541:b8f0:ac85:493a:6db9:7a0f) (Ping timeout: 260 seconds) |
| 11:10:50 | × | hololeap quits (~hololeap@user/hololeap) (Remote host closed the connection) |
| 11:12:48 | → | AlexNoo_ joins (~AlexNoo@94.233.241.187) |
| 11:13:25 | × | gentauro quits (~gentauro@user/gentauro) (Read error: Connection reset by peer) |
| 11:15:43 | × | AlexZenon quits (~alzenon@94.233.241.118) (Ping timeout: 268 seconds) |
| 11:16:20 | → | lavaman joins (~lavaman@98.38.249.169) |
| 11:16:35 | × | AlexNoo quits (~AlexNoo@94.233.241.118) (Ping timeout: 264 seconds) |
| 11:16:57 | × | Alex_test quits (~al_test@94.233.241.118) (Ping timeout: 268 seconds) |
| 11:17:35 | × | hippoid quits (~idris@184.105.6.88) (Quit: Lost terminal) |
| 11:19:02 | → | gentauro joins (~gentauro@user/gentauro) |
| 11:19:24 | → | AlexZenon joins (~alzenon@94.233.241.187) |
| 11:20:59 | → | Alex_test joins (~al_test@94.233.241.187) |
| 11:21:00 | × | gentauro quits (~gentauro@user/gentauro) (Read error: Connection reset by peer) |
| 11:21:10 | × | lavaman quits (~lavaman@98.38.249.169) (Ping timeout: 256 seconds) |
| 11:21:13 | × | Lycurgus quits (~juan@98.4.112.204) (Quit: Exeunt) |
| 11:24:02 | → | gentauro joins (~gentauro@user/gentauro) |
| 11:29:19 | × | abrantesasf quits (abrantesas@gateway/vpn/protonvpn/abrantesasf) (Remote host closed the connection) |
| 11:35:07 | → | dschrempf joins (~dominik@070-207.dynamic.dsl.fonira.net) |
| 11:37:36 | × | gentauro quits (~gentauro@user/gentauro) (Read error: Connection reset by peer) |
| 11:40:22 | × | dschrempf quits (~dominik@070-207.dynamic.dsl.fonira.net) (Ping timeout: 268 seconds) |
| 11:40:54 | × | forell quits (~forell@user/forell) (Ping timeout: 260 seconds) |
| 11:42:50 | → | dschrempf joins (~dominik@070-207.dynamic.dsl.fonira.net) |
| 11:42:59 | → | forell joins (~forell@user/forell) |
| 11:43:30 | → | gentauro joins (~gentauro@user/gentauro) |
| 11:46:33 | × | merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 268 seconds) |
| 11:47:01 | → | raehik joins (~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) |
| 11:47:17 | → | merijn joins (~merijn@83-160-49-249.ip.xs4all.nl) |
| 11:50:51 | × | jle` quits (~jle`@2603-8001-3b02-84d4-0000-0000-0000-025d.res6.spectrum.com) (Ping timeout: 268 seconds) |
| 11:50:51 | × | gentauro quits (~gentauro@user/gentauro) (Read error: Connection reset by peer) |
| 11:51:26 | → | jle` joins (~jle`@2603-8001-3b02-84d4-0000-0000-0000-025d.res6.spectrum.com) |
| 11:56:48 | → | vysn joins (~vysn@user/vysn) |
| 11:56:52 | → | gentauro joins (~gentauro@user/gentauro) |
| 11:57:22 | → | lortabac joins (~lortabac@2a01:e0a:541:b8f0:d501:c9ea:33ea:39c7) |
| 11:58:00 | × | merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 256 seconds) |
| 11:58:11 | → | merijn joins (~merijn@83-160-49-249.ip.xs4all.nl) |
| 12:01:57 | × | Jing quits (~textual@2604:a840:3::10f2) (Remote host closed the connection) |
| 12:02:01 | × | yauhsien quits (~yauhsien@118-167-41-229.dynamic-ip.hinet.net) (Remote host closed the connection) |
| 12:02:26 | → | Jing joins (~textual@2604:a840:3::10f2) |
| 12:04:25 | → | yauhsien joins (~yauhsien@118-167-41-229.dynamic-ip.hinet.net) |
| 12:05:24 | × | whatsupdoc quits (uid509081@id-509081.hampstead.irccloud.com) (Quit: Connection closed for inactivity) |
| 12:06:17 | × | dschrempf quits (~dominik@070-207.dynamic.dsl.fonira.net) (Ping timeout: 268 seconds) |
| 12:06:34 | × | gentauro quits (~gentauro@user/gentauro) (Read error: Connection reset by peer) |
| 12:07:38 | × | Gurkenglas quits (~Gurkengla@dslb-002-203-144-204.002.203.pools.vodafone-ip.de) (Ping timeout: 256 seconds) |
| 12:08:46 | × | merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 256 seconds) |
| 12:08:50 | × | koz quits (~koz@2404:4408:430f:a900:ca69:658c:ba89:aa9f) (Ping timeout: 260 seconds) |
| 12:09:41 | → | merijn joins (~merijn@83-160-49-249.ip.xs4all.nl) |
| 12:11:14 | × | nschoe quits (~quassel@178.251.84.79) (Ping timeout: 260 seconds) |
| 12:11:38 | × | Jing quits (~textual@2604:a840:3::10f2) (Remote host closed the connection) |
| 12:11:53 | → | burnsidesLlama joins (~burnsides@dhcp168-032.wadham.ox.ac.uk) |
| 12:12:12 | → | Jing joins (~textual@125.105.142.242) |
| 12:12:16 | → | gentauro joins (~gentauro@user/gentauro) |
| 12:12:52 | → | koz joins (~koz@121.99.240.58) |
| 12:15:00 | × | merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 256 seconds) |
| 12:15:26 | → | merijn joins (~merijn@83-160-49-249.ip.xs4all.nl) |
| 12:20:40 | × | merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 256 seconds) |
| 12:21:13 | → | merijn joins (~merijn@83-160-49-249.ip.xs4all.nl) |
| 12:21:13 | × | gentauro quits (~gentauro@user/gentauro) (Read error: Connection reset by peer) |
| 12:21:42 | × | fusion86 quits (~fusion@2a02-a44c-e6e5-1-768d-77d5-1db4-35ae.fixed6.kpn.net) (Ping timeout: 268 seconds) |
| 12:22:02 | × | yauhsien quits (~yauhsien@118-167-41-229.dynamic-ip.hinet.net) (Remote host closed the connection) |
| 12:22:38 | → | yauhsien joins (~yauhsien@118-167-41-229.dynamic-ip.hinet.net) |
| 12:25:01 | → | machinedgod joins (~machinedg@135-23-192-217.cpe.pppoe.ca) |
| 12:26:00 | × | MQ-17J quits (~MQ-17J@8.6.144.203) (Ping timeout: 268 seconds) |
| 12:26:37 | × | merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 268 seconds) |
| 12:26:39 | → | gentauro joins (~gentauro@user/gentauro) |
| 12:27:00 | → | merijn joins (~merijn@83-160-49-249.ip.xs4all.nl) |
| 12:27:28 | × | bitdex quits (~bitdex@gateway/tor-sasl/bitdex) (Quit: = "") |
| 12:27:45 | → | cfricke joins (~cfricke@user/cfricke) |
| 12:28:26 | × | gentauro quits (~gentauro@user/gentauro) (Read error: Connection reset by peer) |
| 12:29:53 | → | MQ-17J joins (~MQ-17J@8.6.144.203) |
| 12:33:24 | × | yauhsien quits (~yauhsien@118-167-41-229.dynamic-ip.hinet.net) (Remote host closed the connection) |
| 12:33:55 | → | gentauro joins (~gentauro@user/gentauro) |
| 12:33:58 | → | yauhsien joins (~yauhsien@118-167-41-229.dynamic-ip.hinet.net) |
| 12:35:27 | × | yauhsien quits (~yauhsien@118-167-41-229.dynamic-ip.hinet.net) (Remote host closed the connection) |
| 12:36:23 | → | yauhsien joins (~yauhsien@118-167-41-229.dynamic-ip.hinet.net) |
| 12:36:54 | × | MQ-17J quits (~MQ-17J@8.6.144.203) (Ping timeout: 260 seconds) |
| 12:37:44 | × | merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 268 seconds) |
| 12:38:32 | → | merijn joins (~merijn@83-160-49-249.ip.xs4all.nl) |
| 12:38:49 | → | shriekingnoise joins (~shrieking@186.137.144.80) |
| 12:38:50 | <fendor_> | a rather abstruse question, can I dispatch somehow on a type? E.g. when it is a list, then do this, otherwise this? Can I use Dynamic for that somehow? |
| 12:39:50 | <lortabac> | fendor_: that's what type classes are for |
| 12:40:25 | <lortabac> | unless you mean dispatching at runtime |
| 12:40:57 | <fendor_> | hm, I think typeclasses work just enough in this case |
| 12:40:57 | <Hecate> | (which is also what typeclasses are for :P) |
| 12:41:21 | <Hecate> | fendor_: Display does this https://hackage.haskell.org/package/text-display-0.0.1.0/docs/Data-Text-Display.html#v:displayList |
| 12:41:38 | × | yauhsien quits (~yauhsien@118-167-41-229.dynamic-ip.hinet.net) (Ping timeout: 256 seconds) |
| 12:41:52 | → | mc47 joins (~mc47@xmonad/TheMC47) |
| 12:42:56 | <maerwald> | generics, but that's just typeclasses as well |
| 12:43:54 | × | merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 260 seconds) |
| 12:44:06 | → | merijn joins (~merijn@83-160-49-249.ip.xs4all.nl) |
| 12:44:28 | → | [itchyjunk] joins (~itchyjunk@user/itchyjunk/x-7353470) |
| 12:45:30 | <merijn> | fendor_: You can dispatch on TypeRep, sure |
| 12:45:45 | × | jonathanclarke quits (~jonathanc@202.51.76.91) (Ping timeout: 268 seconds) |
| 12:46:22 | <fendor_> | I think I didn't see the forest because of all the trees, typeclasses sound find in this situation |
| 12:48:57 | → | slowButPresent joins (~slowButPr@user/slowbutpresent) |
| 12:50:10 | <boxscape_> | but typerep is also just a (magical) class |
| 12:50:22 | <boxscape_> | err |
| 12:50:24 | <boxscape_> | Typeable |
| 12:54:12 | <fendor_> | and magic is heresy |
| 12:55:15 | × | _xor quits (~xor@72.49.199.147) (Read error: Connection reset by peer) |
| 12:55:23 | <merijn> | I mean, typeable isn't really magic |
| 12:56:31 | <boxscape_> | "magical" as in "the compiler gives it special treatment" |
| 12:57:19 | <merijn> | I don't agree with that assessment, Typeable isn't given special treatment at all |
| 12:57:39 | <merijn> | The only special bit is that Typeable (nowadays) disallows user implemenetations, only compiler derived ones |
| 12:57:51 | <merijn> | But that's not due to being magic, that's to prevent users from fucking up |
| 12:58:01 | <boxscape_> | I suppose it depends on how we define magic |
| 12:58:06 | <merijn> | Typeable the class behaves just like any other typeclass |
| 12:58:34 | <merijn> | The only special bit is "*must* be derived" and that's only fairly recently |
| 12:58:45 | <tomjaguarpaw> | Two derived Foldable instances of "representationally equivalent" types will be "representationally equivalent". Two derived Typeable instances won't. |
| 12:59:00 | <tomjaguarpaw> | So the class is not magic, but the deriving is. |
| 12:59:33 | × | FinnElija quits (~finn_elij@user/finn-elija/x-0085643) (Ping timeout: 276 seconds) |
| 13:00:22 | → | _xor joins (~xor@72.49.199.147) |
| 13:01:17 | → | FinnElija joins (~finn_elij@user/finn-elija/x-0085643) |
| 13:01:59 | <tomjaguarpaw> | Having said that, Show is possibly a counterexample to my argument. |
| 13:03:40 | → | Gurkenglas joins (~Gurkengla@dslb-002-203-144-204.002.203.pools.vodafone-ip.de) |
| 13:08:13 | → | yin joins (~z@user/zero) |
| 13:09:33 | <zwro[m]> | `let y = f x in seq y (y,x)` is the same as `let !y = f x in (y,x)` right? |
| 13:09:43 | × | max22- quits (~maxime@lfbn-ren-1-762-224.w81-53.abo.wanadoo.fr) (Ping timeout: 260 seconds) |
| 13:10:53 | <yin> | ghci |
| 13:11:02 | × | Gurkenglas quits (~Gurkengla@dslb-002-203-144-204.002.203.pools.vodafone-ip.de) (Ping timeout: 268 seconds) |
| 13:11:11 | <boxscape_> | zwro[m]: sounds right |
| 13:12:25 | → | kilolympus joins (~kilolympu@185.65.135.177) |
| 13:14:18 | <tomsmeding> | yes, that's what bang patterns do |
| 13:14:28 | <tomsmeding> | (in the case of let bindings) |
| 13:15:27 | → | trcc joins (~trcc@eduroam09.au.dk) |
| 13:15:42 | × | trcc quits (~trcc@eduroam09.au.dk) (Read error: Connection reset by peer) |
| 13:16:03 | → | eggplantade joins (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) |
| 13:17:20 | → | fusion86 joins (~fusion@2a02-a44c-e6e5-1-77df-2fce-b355-5feb.fixed6.kpn.net) |
| 13:19:03 | × | trcc_ quits (~trcc@users-1190.st.net.au.dk) (Ping timeout: 268 seconds) |
| 13:19:27 | → | werner98 joins (~werner@2601:2c2:400:4440:ecf2:897:10c1:3ea6) |
| 13:20:36 | <yin> | @def bindl f x = let y = f x in (y,x) |
| 13:20:37 | <lambdabot> | .L.hs:153:1: error: [-Woverlapping-patterns, -Werror=overlapping-patterns] |
| 13:20:38 | <lambdabot> | Pattern match is redundant |
| 13:20:38 | <lambdabot> | In an equation for ‘bindl’: bindl f x = ... |
| 13:20:46 | × | eggplantade quits (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 260 seconds) |
| 13:21:01 | <yin> | :3 |
| 13:21:31 | × | shriekingnoise quits (~shrieking@186.137.144.80) (Ping timeout: 268 seconds) |
| 13:21:31 | × | xff0x quits (~xff0x@2001:1a81:5236:1e00:8d66:5d08:1338:5e80) (Ping timeout: 268 seconds) |
| 13:21:49 | → | shriekingnoise joins (~shrieking@186.137.144.80) |
| 13:22:04 | → | xff0x joins (~xff0x@2001:1a81:5236:1e00:2c63:dc9c:df4d:2374) |
| 13:23:39 | → | cigsender joins (~cigsender@74.124.58.162) |
| 13:23:53 | <yin> | @undef |
| 13:23:53 | <lambdabot> | Undefined. |
| 13:24:24 | → | trcc joins (~trcc@eduroam09.au.dk) |
| 13:24:25 | <yin> | @undefine |
| 13:24:25 | <lambdabot> | Undefined. |
| 13:24:26 | × | boxscape_ quits (~boxscape_@vpn-44-229.hq.eso.org) (Quit: Connection closed) |
| 13:24:55 | <yin> | @def bindl f x = let y = f x in (y,x) |
| 13:24:56 | <lambdabot> | Defined. |
| 13:25:12 | <werner98> | take 5 [1..10] |
| 13:25:13 | × | shidima_ quits (~shidima@46.44.183.25) (Ping timeout: 268 seconds) |
| 13:25:18 | <yin> | @def binds f x = let !y = f x in (y,x) |
| 13:25:19 | <lambdabot> | Defined. |
| 13:25:36 | <werner98> | >take 5 [1..10] |
| 13:25:51 | <yin> | > snd $ bindl (const umdefined) 7 |
| 13:25:52 | <lambdabot> | error: |
| 13:25:52 | <lambdabot> | • Variable not in scope: umdefined |
| 13:25:52 | <lambdabot> | • Perhaps you meant ‘undefined’ (imported from Prelude) |
| 13:26:00 | <yin> | > snd $ bindl (const undefined) 7 |
| 13:26:02 | <lambdabot> | 7 |
| 13:26:25 | AlexNoo_ | is now known as AlexNoo |
| 13:26:34 | <yin> | > snd $ binds (const undefined) 7 |
| 13:26:36 | <lambdabot> | *Exception: Prelude.undefined |
| 13:26:54 | × | albet70 quits (~xxx@2400:8902::f03c:92ff:fe60:98d8) (Remote host closed the connection) |
| 13:27:04 | × | aleator quits (~aleator@176-93-61-167.bb.dnainternet.fi) (Ping timeout: 268 seconds) |
| 13:27:27 | <werner98> | typedfern_ map |
| 13:28:04 | <yin> | there you go |
| 13:28:11 | <maerwald> | I feel like I'm following someone elses ghci session |
| 13:28:35 | <yin> | sorry about that |
| 13:28:53 | <werner98> | @help |
| 13:28:53 | <lambdabot> | help <command>. Ask for help for <command>. Try 'list' for all commands |
| 13:29:12 | <maerwald> | you can try command by PMing lambdabot and then share the thing that actually works here |
| 13:29:23 | <yin> | what was supposed to be 3 simple lines turned into this mess |
| 13:29:34 | × | burnsidesLlama quits (~burnsides@dhcp168-032.wadham.ox.ac.uk) (Remote host closed the connection) |
| 13:30:11 | <yin> | that's what i did but i forgot to @undefine and all hell broke loose |
| 13:31:18 | × | __monty__ quits (~toonn@user/toonn) (Quit: leaving) |
| 13:32:44 | ← | thblt parts (~thblt@user/thblt) (ERC (IRC client for Emacs 28.0.50)) |
| 13:33:00 | → | Guest68 joins (~Guest68@202.164.137.68) |
| 13:33:01 | → | albet70 joins (~xxx@2400:8902::f03c:92ff:fe60:98d8) |
| 13:33:04 | ← | yin parts (~z@user/zero) () |
| 13:33:26 | → | boxscape_ joins (~boxscape_@134.171.73.76) |
| 13:34:04 | × | fusion86 quits (~fusion@2a02-a44c-e6e5-1-77df-2fce-b355-5feb.fixed6.kpn.net) (Quit: Leaving) |
| 13:34:07 | → | dschrempf joins (~dominik@070-207.dynamic.dsl.fonira.net) |
| 13:37:24 | × | sayola quits (~vekto@dslb-002-201-085-156.002.201.pools.vodafone-ip.de) (Quit: Leaving.) |
| 13:39:24 | × | dschrempf quits (~dominik@070-207.dynamic.dsl.fonira.net) (Ping timeout: 268 seconds) |
| 13:42:03 | → | yauhsien joins (~yauhsien@118-167-41-229.dynamic-ip.hinet.net) |
| 13:45:10 | × | werner98 quits (~werner@2601:2c2:400:4440:ecf2:897:10c1:3ea6) (Ping timeout: 256 seconds) |
| 13:47:24 | × | yauhsien quits (~yauhsien@118-167-41-229.dynamic-ip.hinet.net) (Ping timeout: 268 seconds) |
| 13:50:52 | → | Guest41 joins (~Guest41@eth-west-pareq2-46-193-4-100.wb.wifirst.net) |
| 13:56:13 | → | wroathe joins (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) |
| 13:56:14 | × | wroathe quits (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Changing host) |
| 13:56:14 | → | wroathe joins (~wroathe@user/wroathe) |
| 13:56:32 | → | shapr joins (~user@pool-100-36-247-68.washdc.fios.verizon.net) |
| 13:59:45 | × | alzgh quits (~alzgh@user/alzgh) (Remote host closed the connection) |
| 14:00:04 | → | alzgh joins (~alzgh@user/alzgh) |
| 14:01:11 | → | lavaman joins (~lavaman@98.38.249.169) |
| 14:01:47 | × | takuan quits (~takuan@178-116-218-225.access.telenet.be) (Remote host closed the connection) |
| 14:04:01 | → | Profpatsch joins (~Profpatsc@static.88-198-193-255.clients.your-server.de) |
| 14:04:41 | × | gg quits (~gg@2a01:e0a:819:1510:9c2f:617b:a3fa:cf0d) (Ping timeout: 268 seconds) |
| 14:06:19 | → | burnsidesLlama joins (~burnsides@dhcp168-032.wadham.ox.ac.uk) |
| 14:07:08 | → | abrantesasf joins (abrantesas@gateway/vpn/protonvpn/abrantesasf) |
| 14:09:14 | × | michalz quits (~michalz@185.246.204.109) (Ping timeout: 260 seconds) |
| 14:11:59 | × | Inst quits (~Inst@2601:6c4:4080:3f80:cd36:4dbb:1af8:be8) (Remote host closed the connection) |
| 14:12:18 | → | Inst joins (~Inst@2601:6c4:4080:3f80:cd36:4dbb:1af8:be8) |
| 14:12:57 | × | Everything quits (~Everythin@37.115.210.35) (Quit: leaving) |
| 14:14:32 | → | gg joins (~gg@88.160.100.84) |
| 14:15:38 | × | Cajun quits (~Cajun@user/cajun) (Quit: Client closed) |
| 14:18:01 | × | trcc quits (~trcc@eduroam09.au.dk) (Remote host closed the connection) |
| 14:20:34 | × | fendor_ quits (~fendor@178.115.63.67.wireless.dyn.drei.com) (Remote host closed the connection) |
| 14:23:23 | → | trcc joins (~trcc@eduroam09.au.dk) |
| 14:24:37 | → | michalz joins (~michalz@185.246.204.58) |
| 14:25:31 | × | trcc quits (~trcc@eduroam09.au.dk) (Remote host closed the connection) |
| 14:26:11 | × | alzgh quits (~alzgh@user/alzgh) (Remote host closed the connection) |
| 14:26:32 | → | alzgh joins (~alzgh@user/alzgh) |
| 14:26:35 | → | waleee joins (~waleee@h-98-128-228-119.NA.cust.bahnhof.se) |
| 14:27:29 | × | wroathe quits (~wroathe@user/wroathe) (Ping timeout: 268 seconds) |
| 14:28:12 | → | Lycurgus joins (~juan@98.4.112.204) |
| 14:29:52 | → | Achylles joins (~Achylles_@2804:431:d725:bb1e:5dd8:3b02:6cc3:2744) |
| 14:31:47 | × | nrl^ quits (~nrl@wsip-98-188-242-6.mc.at.cox.net) (Remote host closed the connection) |
| 14:33:40 | × | johnny_sitar quits (~artur@078088015209.bialystok.vectranet.pl) (Read error: Connection reset by peer) |
| 14:37:52 | × | alzgh quits (~alzgh@user/alzgh) (Ping timeout: 256 seconds) |
| 14:39:39 | × | burnsidesLlama quits (~burnsides@dhcp168-032.wadham.ox.ac.uk) (Remote host closed the connection) |
| 14:42:49 | → | justsomeguy joins (~justsomeg@user/justsomeguy) |
| 14:44:11 | → | wroathe joins (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) |
| 14:44:11 | × | wroathe quits (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Changing host) |
| 14:44:11 | → | wroathe joins (~wroathe@user/wroathe) |
| 14:49:05 | × | wroathe quits (~wroathe@user/wroathe) (Ping timeout: 268 seconds) |
| 14:51:38 | → | johnny_sitar joins (~artur@078088015209.bialystok.vectranet.pl) |
| 14:51:43 | → | werner58 joins (~werner@2601:2c2:400:4440:dc41:dccb:7773:558f) |
| 14:51:52 | × | werner58 quits (~werner@2601:2c2:400:4440:dc41:dccb:7773:558f) (Client Quit) |
| 14:52:44 | → | werner100 joins (~werner100@2601:2c2:400:4440:dc41:dccb:7773:558f) |
| 14:53:22 | × | Achylles quits (~Achylles_@2804:431:d725:bb1e:5dd8:3b02:6cc3:2744) (Remote host closed the connection) |
| 14:55:05 | → | trcc joins (~trcc@eduroam09.au.dk) |
| 14:55:07 | × | trcc quits (~trcc@eduroam09.au.dk) (Remote host closed the connection) |
| 14:55:08 | × | Guest68 quits (~Guest68@202.164.137.68) (Quit: Client closed) |
| 14:55:39 | → | trcc joins (~trcc@users-1190.st.net.au.dk) |
| 14:56:24 | → | k` joins (~user@152.1.137.158) |
| 14:57:38 | → | dsamperi joins (~dsamperi@2603-7000-3b42-5400-0c2e-16c3-2bfb-81aa.res6.spectrum.com) |
| 14:58:13 | <k`> | What are your thoughts on indexing functions that index from the left given a nonnegative argument and the right given a negative one, vs functions that only index in one direction and throw an error when given a negative argument? |
| 14:59:32 | <geekosaur> | they only make sense for structures that support such indexing. for lists, for example, you can't really index from the right |
| 15:00:05 | <geekosaur> | and then there's Data.Array where negative indexes are directly supported via Data.Ix, so you can't repurpose them to index from the right |
| 15:00:16 | → | caef^ joins (~caef@wsip-98-188-242-6.mc.at.cox.net) |
| 15:00:38 | <boxscape_> | Data.Vector could if it wanted to, I imagine |
| 15:00:59 | <k`> | geekosaur: In principle I agree, but I have seen real Haskell packages that intentionally access lists the 'wrong' way because they want to avoid depending on more complicated packages and they only use small lists. |
| 15:01:37 | → | max22- joins (~maxime@2a01cb088335980044786ab87c2c3d64.ipv6.abo.wanadoo.fr) |
| 15:02:03 | <boxscape_> | I think if you have O(1) access and use Int as index, it's probably a decent idea |
| 15:02:15 | <k`> | And I'm talking about strictly using zero-based Int indices, which won't necessarily match the 'official' indices of a structure (for example a Map from `String` to function). |
| 15:03:04 | <k`> | OK. To me it seems slightly more error-prone, but on the other hand the smaller API surface seems like a win. |
| 15:03:24 | <boxscape_> | what kind of error is it prone to? |
| 15:03:54 | × | lavaman quits (~lavaman@98.38.249.169) (Ping timeout: 260 seconds) |
| 15:04:04 | <geekosaur> | smaller but more complicated, seems to me, unless you go all the way and use modulus arithmetic for indexing |
| 15:04:27 | × | pavonia quits (~user@user/siracusa) (Quit: Bye!) |
| 15:04:34 | <geekosaur> | hm, no, I guess that doesn't quite fit either |
| 15:04:40 | <k`> | If you unintentionally give a function that requires a positive index a negative one, it can throw an error. But if negative indexes have a special meaning, you instead get a seemingly valid value. |
| 15:05:11 | <geekosaur> | no, it does. I'm confusing myself |
| 15:05:49 | × | pop3 quits (~pop3@user/pop3) (Remote host closed the connection) |
| 15:05:50 | geekosaur | should just go off and do laundry, that can be done while insufficiently caffeinated :) |
| 15:06:45 | → | pop3 joins (~pop3@user/pop3) |
| 15:07:23 | × | cfricke quits (~cfricke@user/cfricke) (Quit: WeeChat 3.3) |
| 15:07:36 | → | myShoggoth joins (~myShoggot@97-120-85-195.ptld.qwest.net) |
| 15:08:10 | <k`> | I'm phrasing this all hypothetically, but you could in fact define it all in terms of `Foldable`. |
| 15:09:22 | <k`> | > let foldrState' s0 f z0 mx = foldr f' (\_-> z0) mx s0 where f' x k s = let (s', z') = f s x (s' `seq` k s') in z' |
| 15:09:24 | <lambdabot> | <no location info>: error: |
| 15:09:24 | <lambdabot> | not an expression: ‘let foldrState' s0 f z0 mx = foldr f' (\_-> z0) mx s... |
| 15:09:30 | → | ec joins (~ec@gateway/tor-sasl/ec) |
| 15:10:35 | <k`> | > foldrState' s0 f z0 mx = foldr f' (const z0) mx s0 where f' x k s = let (s', z') = f s x (s' `seq` k s') in z' |
| 15:10:36 | <lambdabot> | <hint>:1:24: error: parse error on input ‘=’ |
| 15:10:52 | <k`> | Eh, I don't know how to use Lambdabot. |
| 15:11:22 | <geekosaur> | use @let for definitions |
| 15:11:31 | <geekosaur> | "> " only accepts expressions |
| 15:11:43 | <k`> | Oh, thanks. |
| 15:12:49 | × | Guest41 quits (~Guest41@eth-west-pareq2-46-193-4-100.wb.wifirst.net) (Quit: Client closed) |
| 15:13:40 | <k`> | @let foldrState' s0 f z0 mx = foldr f' (const z0) mx s0 where f' x k s = let (s', z') = f s x (s' `seq` k s') in z' |
| 15:13:41 | <lambdabot> | Defined. |
| 15:15:10 | <k`> | @let foldlState' s0 f z0 mx = foldl f' (const z0) mx s0 where f' k x s = let (s', z') = f s (s' `seq` k s') x in z' |
| 15:15:11 | <lambdabot> | Defined. |
| 15:16:14 | → | burnsidesLlama joins (~burnsides@dhcp168-032.wadham.ox.ac.uk) |
| 15:18:26 | <k`> | @let nthR i = foldrState' 0 (\ i' x mx -> (i' + 1, if i' == i then Just x else mx)) |
| 15:18:27 | <lambdabot> | Defined. |
| 15:18:44 | <k`> | > nthR 5 [1..] |
| 15:18:45 | <lambdabot> | error: |
| 15:18:45 | <lambdabot> | • Couldn't match expected type ‘Maybe a2’ with actual type ‘[a0]’ |
| 15:18:45 | <lambdabot> | • In the second argument of ‘nthR’, namely ‘[1 .. ]’ |
| 15:18:56 | → | trcc_ joins (~trcc@eduroam09.au.dk) |
| 15:19:25 | <k`> | Forgot my accumulator. |
| 15:20:11 | <k`> | @let nthR i = foldrState' 0 (\ i' x mx -> (i' + 1, if i' == i then Just x else mx)) Nothing |
| 15:20:12 | <lambdabot> | .L.hs:162:5: error: |
| 15:20:12 | <lambdabot> | • Couldn't match type ‘Maybe a1’ with ‘t a1 -> Maybe a1’ |
| 15:20:12 | <lambdabot> | Expected type: Maybe a1 -> t a1 -> Maybe a1 |
| 15:20:34 | <k`> | Sorry, sorry. |
| 15:20:56 | <geekosaur> | you might do this in pm with lambdabot and show the result once it's working |
| 15:21:07 | <k`> | Oh man, totally forgot I could pm. |
| 15:21:22 | <geekosaur> | also you'll run into that these definitons actually go into a file so it'll give you conflicting types in the end, I suspect |
| 15:21:35 | <geekosaur> | so you'll have to @undefine first and start over :( |
| 15:21:39 | × | burnsidesLlama quits (~burnsides@dhcp168-032.wadham.ox.ac.uk) (Remote host closed the connection) |
| 15:21:46 | → | burnside_ joins (~burnsides@dhcp168-032.wadham.ox.ac.uk) |
| 15:22:02 | × | trcc quits (~trcc@users-1190.st.net.au.dk) (Ping timeout: 260 seconds) |
| 15:22:14 | <geekosaur> | yahb is an actual ghci so you might find it easier to experiment in. uses % as prefix, also accepts pm |
| 15:22:37 | <k`> | geekosaur: Thanks! |
| 15:23:25 | <k`> | /msg yahb let foldrState' s0 f z0 mx = foldr f' (\_-> z0) mx s0 where f' x k s = let (s', z') = f s x (s' `seq` k s') in z' |
| 15:23:25 | <k`> | |
| 15:23:37 | × | trcc_ quits (~trcc@eduroam09.au.dk) (Ping timeout: 268 seconds) |
| 15:23:52 | <boxscape_> | k` remember to prepend the % |
| 15:24:09 | <k`> | boxscape_: :) |
| 15:27:24 | × | werner100 quits (~werner100@2601:2c2:400:4440:dc41:dccb:7773:558f) (Quit: Ping timeout (120 seconds)) |
| 15:27:38 | × | acidjnk_new quits (~acidjnk@p200300d0c726702918431f3aede9e057.dip0.t-ipconnect.de) (Ping timeout: 260 seconds) |
| 15:28:25 | × | haskl quits (~haskl@user/haskl) (Read error: Connection reset by peer) |
| 15:31:49 | → | slack1256 joins (~slack1256@191.126.227.206) |
| 15:33:20 | → | eggplantade joins (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) |
| 15:36:23 | × | burnside_ quits (~burnsides@dhcp168-032.wadham.ox.ac.uk) (Remote host closed the connection) |
| 15:36:57 | → | burnsidesLlama joins (~burnsides@dhcp168-032.wadham.ox.ac.uk) |
| 15:37:22 | × | canxiu quits (uid524910@id-524910.helmsley.irccloud.com) (Quit: Connection closed for inactivity) |
| 15:40:31 | <k`> | > nth 3 [1..] |
| 15:40:32 | <lambdabot> | Just 4 |
| 15:40:44 | <k`> | > nth (-1) [1..7] |
| 15:40:45 | <lambdabot> | Just 7 |
| 15:41:14 | × | burnsidesLlama quits (~burnsides@dhcp168-032.wadham.ox.ac.uk) (Ping timeout: 260 seconds) |
| 15:41:45 | <geekosaur> | come to think of it, that's another reason against negative indexing: negative literals :( |
| 15:41:46 | → | Sgeo joins (~Sgeo@user/sgeo) |
| 15:42:02 | <k`> | @type nth |
| 15:42:03 | <lambdabot> | (Ord t1, Num t1, Foldable t2) => t1 -> t2 a -> Maybe a |
| 15:42:03 | × | ec quits (~ec@gateway/tor-sasl/ec) (Ping timeout: 276 seconds) |
| 15:42:07 | <geekosaur> | we now have something like 4 different extensions to try to fix negative literals, all of which suck in one way or another |
| 15:43:38 | <k`> | Here's my pet wish for some day: `- 1` is `subtract 1` ; `-1` is `negate 1` ; in general infix operators must be surrounded by whitespace (or parentheses). |
| 15:43:58 | × | pop3 quits (~pop3@user/pop3) (Remote host closed the connection) |
| 15:44:04 | <geekosaur> | I think that's one of the extensions |
| 15:44:16 | <k`> | Oh, cool. How obscure is it? |
| 15:44:17 | <geekosaur> | but it means some othyer idioms don't work because now they need spaces |
| 15:44:30 | × | cigsender quits (~cigsender@74.124.58.162) (Ping timeout: 260 seconds) |
| 15:45:02 | → | pop3 joins (~pop3@user/pop3) |
| 15:45:03 | <k`> | What idioms have ever required infix operators be unspaced? |
| 15:45:41 | <geekosaur> | sections |
| 15:45:43 | <geekosaur> | https://downloads.haskell.org/ghc/latest/docs/html/users_guide/exts/lexical_negation.html |
| 15:45:50 | <geekosaur> | doesn't require it but is convenient |
| 15:45:57 | <merijn> | Allowing infix operators without spaces was a mistake |
| 15:46:00 | <geekosaur> | now you can't say (+1) it has to be (+ 1) |
| 15:46:11 | <merijn> | geekosaur: Acceptable sacrifice |
| 15:46:26 | <k`> | geekosaur: For me that's 100% always an improvement. |
| 15:46:27 | <merijn> | Fuck the entire mess we're in now |
| 15:46:32 | <monochrom> | I like writing like "m=n-1" |
| 15:46:32 | <geekosaur> | but it breaks a shitload of code |
| 15:46:44 | <merijn> | geekosaur: Sure, we can't fix it now |
| 15:46:46 | <k`> | Honestly, for me `+1` looks like positive 1. |
| 15:47:09 | <monochrom> | I mean I like having that option. I don't do it all the time, but once in a while I would like to do it when it doesn't hurt. |
| 15:47:15 | <merijn> | geekosaur: But Haskell would be a better and less edge-casy language if we'd banned it from the start |
| 15:47:16 | <k`> | Yeah, that's why I said 'pet wish for some day' rather than 'shrill immediate demand'. |
| 15:47:54 | <k`> | I would shrilly and immediately demand spaces if that were a nonbreaking change... |
| 15:48:01 | <merijn> | monochrom: Sure, but do you like it more than you would like getting rid off: negate, ambiguity of -, and the ability to use . for record syntax without 15 billion ambiguous interpretation |
| 15:48:14 | <geekosaur> | hm, actually if I'm reading the manual right they removed some of the earlier attempts at negative literals when they added this one. good |
| 15:48:17 | <merijn> | monochrom: eh, I guess I meant subtract, not negate |
| 15:48:18 | <monochrom> | But seriously the real mess is the obsession with plain text files. |
| 15:48:26 | <merijn> | monochrom: Also true, but harder to fix |
| 15:48:27 | <geekosaur> | we were kinda piling up bad attempts there |
| 15:48:59 | → | ec joins (~ec@gateway/tor-sasl/ec) |
| 15:49:31 | <monochrom> | Allow me to ramble a bit more. The following is not your fault. Just my pet peeve. |
| 15:49:48 | <monochrom> | Programmer obsession with plain text files runs really deep. |
| 15:49:54 | <merijn> | monochrom: Requiring spaces around infix operators means that '-x', '(-x)', and '(- x)' each have a single unambiguous meaning and parse. It also removes the ambiguity whether "Foo.x" is a qualified name of composition of a constructor and a function |
| 15:50:20 | → | haskl joins (~haskl@user/haskl) |
| 15:50:27 | <monochrom> | Once I went to a conference and there was an exhibition section for researchers to show posters and demos, as usual. |
| 15:50:37 | <merijn> | monochrom: It's also means that "record.x" can be given its own unambiguous interpretation as record indexing (since qualified names have a capital as first character) |
| 15:50:59 | <merijn> | (and composition would be forced to be "record . x") |
| 15:51:06 | <merijn> | Imagine the utopia we could've had! |
| 15:51:20 | <monochrom> | One booth talked about modeling a certain thing by graphs (the graph theory kind). |
| 15:51:22 | <k`> | Hear hear |
| 15:51:34 | <yushyin> | that's how i write it anyway |
| 15:51:35 | <merijn> | Instead we're stucking with subtract, 15 billion record syntax extensions, NegativeLiterals and 10 types of ambiguous parses |
| 15:51:43 | <geekosaur> | oh wow, someone got that right |
| 15:52:02 | × | Lycurgus quits (~juan@98.4.112.204) (Ping timeout: 256 seconds) |
| 15:52:21 | <monochrom> | The researcher went on to show displaying or inputting (I forgot which) a graph by a textual language he invented. |
| 15:52:41 | <merijn> | monochrom: Because UI code is hard :p |
| 15:53:07 | <monochrom> | Yeah there was a parser freak right there. |
| 15:53:33 | <monochrom> | Inventing the nth syntax for adjacency lists. |
| 15:54:14 | × | myShoggoth quits (~myShoggot@97-120-85-195.ptld.qwest.net) (Ping timeout: 260 seconds) |
| 15:54:26 | × | favonia quits (~favonia@user/favonia) (Ping timeout: 268 seconds) |
| 15:55:19 | geekosaur | wonders if this researcher otherwise only knew matlab |
| 15:56:25 | <monochrom> | This was a software engineering conference. I think even though he would know matlab from common CS education he would not think much of it. |
| 15:57:11 | × | [itchyjunk] quits (~itchyjunk@user/itchyjunk/x-7353470) (Read error: Connection reset by peer) |
| 15:57:57 | k` | got through college using only Matlab (except in computer architecture) |
| 15:58:09 | × | merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 268 seconds) |
| 15:58:38 | <boxscape_> | I was about to say that it wouldn't be unambiguous since in `data Rec = A { a :: Bool } | B`, writing `B.a` should be an attempt at field selection rather than a qualified name, but no, that's already interpreted as a qualified name now |
| 15:58:39 | ← | kadir parts (~kadir@95.7.9.203) (WeeChat 3.3) |
| 15:59:02 | <boxscape_> | (you can do `let b = B in b.a` though) |
| 15:59:58 | <boxscape_> | does that mean b is not referentially transparent |
| 16:00:20 | <monochrom> | (B).a |
| 16:00:29 | <boxscape_> | ah, you're right, okay |
| 16:00:47 | <monochrom> | For the same reason "let x=2+2 in 3*x" does not equal 3*2+2 |
| 16:00:48 | <k`> | Am I the only one who basically gave up on using record syntax, period, except with lenses? |
| 16:00:54 | <boxscape_> | hm, fair |
| 16:01:07 | <monochrom> | Once again the mess is obsession with plain text files. |
| 16:01:11 | <boxscape_> | yeah |
| 16:01:45 | <boxscape_> | k` I think I'll be using -XOverloadedRecordDot if and only if I don't have lens as a dependency for something else |
| 16:01:55 | → | lbseale joins (~lbseale@user/ep1ctetus) |
| 16:02:02 | <monochrom> | I still use record syntax, and without lenses. In fact, I go as far as to use RecordWildCards once in a while. |
| 16:02:14 | <dsamperi> | What does :p at end of line mean? |
| 16:02:28 | × | justsomeguy quits (~justsomeg@user/justsomeguy) (Quit: WeeChat 3.2) |
| 16:02:32 | <monochrom> | It's an emoticon. |
| 16:02:47 | <monochrom> | Like :) but with an extra tongue. |
| 16:02:55 | × | hendursa1 quits (~weechat@user/hendursaga) (Quit: hendursa1) |
| 16:02:56 | × | boxscape_ quits (~boxscape_@134.171.73.76) (Quit: see you) |
| 16:03:20 | <yushyin> | k`: the combination of NoFieldSelectors, NamedFieldPuns and RecordWildCards can be quite useful for simple stuff |
| 16:03:24 | <k`> | It's consing the preceeding expression to `p` . |
| 16:03:28 | → | hendursaga joins (~weechat@user/hendursaga) |
| 16:04:30 | <dsamperi> | :; |
| 16:05:42 | <k`> | yushyin: Guess I'm just extension-shy and record-shy... |
| 16:07:00 | <k`> | yushyin: Haven't looked at the uses of `NoFieldSelectors` . That's pretty neat. Thanks. |
| 16:08:15 | <yushyin> | afair with GHC2021 you would only need to -XNoFieldSelectors |
| 16:11:18 | × | ec quits (~ec@gateway/tor-sasl/ec) (Ping timeout: 276 seconds) |
| 16:13:18 | → | fendor joins (~fendor@178.115.33.172.wireless.dyn.drei.com) |
| 16:17:54 | → | shidima_ joins (~shidima@84-104-108-90.cable.dynamic.v4.ziggo.nl) |
| 16:17:57 | shidima_ | is now known as shidima |
| 16:18:28 | → | Guest41 joins (~Guest41@eth-west-pareq2-46-193-4-100.wb.wifirst.net) |
| 16:18:32 | → | nschoe joins (~quassel@178.251.84.79) |
| 16:25:38 | → | merijn joins (~merijn@83-160-49-249.ip.xs4all.nl) |
| 16:28:01 | → | ec joins (~ec@gateway/tor-sasl/ec) |
| 16:28:12 | <dsal> | Does ghc do anything fancy to turn $ into . or similar? I'm looking at code with a lot of $ and it seems expensive. |
| 16:30:34 | × | merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 256 seconds) |
| 16:31:03 | <geekosaur> | I don't think so. but $ is cheap since it's just function application with a weird precedence |
| 16:31:40 | <Profpatsch> | dsal: You can safely assume GHC is smart enough to optimize those away |
| 16:31:49 | <c_wraith> | unless you're using it partially applied, ($) doesn't even exist in compiled code |
| 16:31:52 | → | favonia joins (~favonia@user/favonia) |
| 16:32:08 | <dsal> | Yeah, I assume it's not something worth worrying about. |
| 16:32:31 | <dsal> | Just seeing $ everywhere looks less elegant. Like new money. Programmers trying to bling out their code. |
| 16:32:48 | <Profpatsch> | dsal: you can also use & |
| 16:32:57 | <Profpatsch> | for better community effect of your code |
| 16:33:25 | → | fizzsegfaultbuzz joins (~segfaultf@135-180-0-138.static.sonic.net) |
| 16:33:30 | <Profpatsch> | you want your code to say “-yes, and” to your manager after all |
| 16:36:42 | → | myShoggoth joins (~myShoggot@97-120-85-195.ptld.qwest.net) |
| 16:36:59 | → | thelounge2191 joins (7aa71341@67.205.143.82) |
| 16:37:17 | <dsal> | haha |
| 16:37:37 | × | poljar quits (~poljar@78-3-31-140.adsl.net.t-com.hr) (Quit: WeeChat 3.2) |
| 16:37:38 | <kuribas> | In dependend haskell, will you be able to use a value level function on types? |
| 16:37:55 | <geekosaur> | nobody knows yet |
| 16:38:07 | <geekosaur> | dependent haskell is a *long* way off |
| 16:38:23 | <dsal> | Dependent haskell solves all of everyone's problems. |
| 16:38:52 | <geekosaur> | and mostly unspecced as yet |
| 16:39:12 | <Profpatsch> | will it still be Haskell tho |
| 16:39:42 | <kuribas> | Profpatsch: I suppose it will be backwards compatible. |
| 16:39:56 | <kuribas> | Profpatsch: so, yes. |
| 16:40:02 | → | sonny joins (~sonny@bras-base-london1483w-grc-30-74-12-157-200.dsl.bell.ca) |
| 16:40:06 | <kuribas> | as far as you consider any extension "Haskell" |
| 16:40:25 | <kuribas> | You might say that GADTs, Datakinds, type families, etc... aren't "Haskell". |
| 16:41:12 | × | ec quits (~ec@gateway/tor-sasl/ec) (Ping timeout: 276 seconds) |
| 16:41:20 | <kuribas> | ah " To put it another way, any term whatsoever will be acceptable as an argument to f :: foreach a -> blah; and any term whatsoever would be acceptable in a type or kind signature. (NB: Richard and Stephanie definitely want this. Simon is not yet convinced that the pain will be worth the gain.)" |
| 16:42:25 | → | boxscape_ joins (~boxscape_@i577BCB60.versanet.de) |
| 16:42:39 | geekosaur | is glad someone is thinking about the pain part, at least |
| 16:43:15 | <kuribas> | geekosaur: who's pain, the compiler writer, or developers? |
| 16:43:26 | <geekosaur> | "yes" |
| 16:43:36 | × | boxscape_ quits (~boxscape_@i577BCB60.versanet.de) (Client Quit) |
| 16:43:47 | × | mc47 quits (~mc47@xmonad/TheMC47) (Ping timeout: 268 seconds) |
| 16:43:52 | → | boxscape_ joins (~boxscape_@i577BCB60.versanet.de) |
| 16:45:23 | <c_wraith> | I don't really care about full dependent types. I just want to be able to promote and demote values without using reflection or singletons |
| 16:45:28 | <kuribas> | but will it be worse than "singletons"? |
| 16:45:52 | <Profpatsch> | If I have a ConduitT a b m r and want to transform it into a ConduitT (c, a) (c, b) m r how would I do that? |
| 16:46:13 | <Profpatsch> | I’m not strong enough |
| 16:46:59 | <c_wraith> | that seems like... it's ambiguous |
| 16:47:21 | <boxscape_> | kuribas it would be somewhat surprising if fully dependent types were worse than singletons considering the idea is to make everything better that singletons has to bend over backwards to achieve |
| 16:47:49 | <Profpatsch> | c_wraith: yeah, if more than one stream element is produced, it should just copy the c |
| 16:47:52 | → | ec joins (~ec@gateway/tor-sasl/ec) |
| 16:47:59 | <Profpatsch> | As in then multiple elements get the same c |
| 16:48:05 | <c_wraith> | Profpatsch: what if it never got a c at all? |
| 16:48:20 | <Profpatsch> | c_wraith: Hm |
| 16:48:22 | <Profpatsch> | Good point |
| 16:48:32 | <Profpatsch> | I have a ConduitT () c m r |
| 16:48:45 | <Profpatsch> | And I Zipped it with a ConduitT () a mr |
| 16:49:02 | <Profpatsch> | Hm maybe what I want to do is zip later |
| 16:49:13 | × | Vajb quits (~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) (Read error: Connection reset by peer) |
| 16:49:39 | × | thelounge2191 quits (7aa71341@67.205.143.82) (Quit: The Lounge - https://thelounge.chat) |
| 16:49:43 | <kuribas> | dsal: maybe we should just migrate to idris? |
| 16:49:44 | × | boxscape_ quits (~boxscape_@i577BCB60.versanet.de) (Quit: Connection closed) |
| 16:49:58 | <kuribas> | it's haskell-like with dependent types. |
| 16:50:04 | <kuribas> | Which is what we want right? |
| 16:51:20 | <dolio> | If that's what you want, it's not a bad idea. |
| 16:54:33 | <Profpatsch> | c_wraith: lol I just had to move brackets around my pipeline a bit |
| 16:54:35 | × | shailangsa quits (~shailangs@host86-185-98-19.range86-185.btcentralplus.com) (Remote host closed the connection) |
| 16:54:57 | <dsal> | kuribas: does it have linear types? |
| 16:55:04 | <dolio> | I think it'd be cool if the people who wanted to do all kinds of type level stuff went and used idris instead, because it would mean idris has more people working with it, and the type level stuff would be better. |
| 16:55:28 | <c_wraith> | Profpatsch: hah. way better than forcing some ambiguous type conversion! |
| 16:55:31 | <dolio> | Idris 2 has linear types. |
| 16:55:43 | <kuribas> | dolio: I agree wholehartedly :) |
| 16:56:03 | <kuribas> | idris looks pretty nice, but has barely any libraries. |
| 16:56:04 | <Profpatsch> | c_wraith: I’m trying to get an intuition for streams, so I guess it wasn’t super obvious to me :) |
| 16:56:13 | <Profpatsch> | But the types don’t lie! |
| 16:56:18 | <Profpatsch> | (except when they do) |
| 16:56:33 | <dsal> | Can you write software in idris? I should try it out someday. |
| 16:56:40 | <kuribas> | Profpatsch: they don't lie. They may not mean what you think though... |
| 16:56:48 | <kuribas> | dsal: sure you can. |
| 16:56:51 | <Profpatsch> | kuribas: oh I just had that today |
| 16:56:52 | → | tzh joins (~tzh@c-24-21-73-154.hsd1.wa.comcast.net) |
| 16:57:04 | → | Skyfire joins (~pyon@user/pyon) |
| 16:57:06 | <Profpatsch> | The type matched up perfectly, but the function didn’t do what I thought it would |
| 16:57:23 | <kuribas> | dsal: you'll need write pretty any library yourself, or write bindings to scheme/C/java |
| 16:57:24 | <Profpatsch> | Which in this case I’d say is a fault of the types not having enough information |
| 16:57:38 | → | Vajb joins (~Vajb@2001:999:66:281c:27a0:1549:39e5:8b1a) |
| 16:58:45 | × | ubert quits (~Thunderbi@2a02:8109:9880:303c:ca5b:76ff:fe29:f233) (Remote host closed the connection) |
| 16:58:54 | <kuribas> | Profpatsch: putting more stuff on type level means your program becomes safer, but also harder to write. |
| 16:59:28 | <kuribas> | dsal: I'd even say idris is made for writing software, not for proving stuff. |
| 16:59:52 | <dsal> | Oh cool. I've never touched it. I've only played around in agda which didn't seem like it'd be useful for writing software. |
| 17:00:12 | → | MQ-17J joins (~MQ-17J@d192-24-122-179.try.wideopenwest.com) |
| 17:00:16 | <dolio> | You can write software in Agda, but Idris is going to be way better on that front. |
| 17:02:35 | → | emf joins (~emf@2620:10d:c090:400::5:ba1c) |
| 17:02:45 | <kuribas> | stuff like anonymous records or providing a specification in types is way easier in idris. |
| 17:03:06 | <Cale> | As much as I love dependent types and being able to prove theorems in the type system, I do worry about the sorts of corners people will paint themselves into with them. I've seen cases where people managed to create bureaucratic nightmares that guarantee very little using the dependent-type-ish features already in Haskell. |
| 17:03:36 | → | hightower2 joins (~hightower@213.147.110.20) |
| 17:04:56 | <dolio> | Well, part of the problem is that because it has 'verly little,' things that are pretty trivial in real dependently typed languages become very tedious in GHC. |
| 17:05:32 | × | lortabac quits (~lortabac@2a01:e0a:541:b8f0:d501:c9ea:33ea:39c7) (Quit: WeeChat 2.8) |
| 17:05:39 | <kuribas> | unlifting a DataKind into a value. |
| 17:05:40 | <Cale> | That's not only it though -- in some ways, things get worse in proper dependently typed languages, because you're often breaking the functional abstraction |
| 17:06:39 | <kuribas> | Cale: do you have an example? |
| 17:06:43 | <Cale> | Like, it matters the precise ways that functions are defined, not just what their results are, because it affects what you're able to evaluate at the type level. |
| 17:07:40 | <Cale> | A very simple example is like how when you define addition on naturals, it matters which argument you're pattern matching on, and 0 + n might evaluate to n on its own, but n + 0 = n will require a proof |
| 17:08:21 | <Cale> | In a more complicated setting, having lots of types around that involve the functions in your program can make it really hard to refactor or change the implementations of those functions. |
| 17:09:10 | <Cale> | You can end up in situations where in order to get everything to type check, everything has to be *just so*. |
| 17:09:21 | <kuribas> | Cale: but couldn't you separate functions used on type level, and those on value level? |
| 17:09:27 | <dsal> | I can see how it's easy to go from "I just need a little proof here" to "I should do this everywhere!" to "WHAT HAVE I DONE?" |
| 17:09:46 | <Cale> | dsal: Yeah, it's very hard to know exactly when you've crossed the invisible line |
| 17:10:36 | <Cale> | You might be saving yourself a bunch of effort debugging runtime failures, but then if you spend more time than that trying to get your program to compile, or unable to refactor something that needs a performance improvement... |
| 17:10:56 | ← | Jing parts (~textual@125.105.142.242) (Textual IRC Client: www.textualapp.com) |
| 17:11:15 | <Cale> | I do think there are plenty of cases where the line is farther over than what Haskell presently allows |
| 17:11:42 | <Cale> | But there's also lots of dumb things you can try to guarantee at compile time and end up wasting lots of effort preventing bugs that were never going to happen. |
| 17:11:48 | <maerwald> | "but... I need this feature for my PhD thesis" |
| 17:11:52 | <maerwald> | :D |
| 17:12:09 | <kuribas> | runtime errors are fine, if they don't happen obscurely. |
| 17:12:13 | <dsal> | The same tools that prevent bugs can prevent necessary features. |
| 17:13:03 | <kuribas> | It's about knowing where it's useful to track something in the type system. |
| 17:13:17 | → | zebrag joins (~chris@user/zebrag) |
| 17:13:36 | <kuribas> | I found tracking the type of SQL columns and return types in types is incredibly useful. |
| 17:13:46 | <kuribas> | And doesn't make it much harder to write. |
| 17:14:12 | → | burnsidesLlama joins (~burnsides@dhcp168-032.wadham.ox.ac.uk) |
| 17:14:12 | × | Vajb quits (~Vajb@2001:999:66:281c:27a0:1549:39e5:8b1a) (Read error: Connection reset by peer) |
| 17:14:39 | <kuribas> | But trying to proof that the SQL is correct in general is very hard. |
| 17:15:02 | <kuribas> | And likely requires you to only use a subset of SQL. |
| 17:15:08 | <dolio> | Well, the rules for correct SQL are extremely arbitrary. |
| 17:15:11 | → | Vajb joins (~Vajb@hag-jnsbng11-58c3a8-176.dhcp.inet.fi) |
| 17:15:54 | × | johnny_sitar quits (~artur@078088015209.bialystok.vectranet.pl) (Ping timeout: 256 seconds) |
| 17:16:33 | <geekosaur> | one way to view dependent types is that compile time becomes the new run time |
| 17:17:07 | <dsal> | That's how I use TH sometimes. |
| 17:17:54 | → | merijn joins (~merijn@83-160-49-249.ip.xs4all.nl) |
| 17:18:05 | <kuribas> | dolio: well, a lot of libraries make their own system on top of SQL, but that's an extra complexity the programmer has to learn, and also limits the usecases, possibilities for optimization, etc... |
| 17:18:18 | <kuribas> | dolio: while everyone knows SQL. |
| 17:18:52 | <dolio> | I guess. I mean, I wrote something like that. The problem with SQL is that it's very hard to generate from a library, because of the arbitrary rules. |
| 17:19:14 | <kuribas> | dolio: yeah, I am just generating strings. |
| 17:19:31 | <kuribas> | dolio: I mean, it's not much more than a fancy string builder. |
| 17:19:34 | <dolio> | Like, certain trivial cases that an optimizer could probably find and omit are instead syntax errors, because syntax is the only thing the standards committee has control over. |
| 17:20:10 | × | burnsidesLlama quits (~burnsides@dhcp168-032.wadham.ox.ac.uk) (Ping timeout: 268 seconds) |
| 17:20:22 | × | Midjak quits (~Midjak@82-65-111-221.subs.proxad.net) (Quit: Leaving) |
| 17:22:58 | × | MQ-17J quits (~MQ-17J@d192-24-122-179.try.wideopenwest.com) (Ping timeout: 260 seconds) |
| 17:24:45 | × | ec quits (~ec@gateway/tor-sasl/ec) (Ping timeout: 276 seconds) |
| 17:24:45 | × | azeem quits (~azeem@emp-89-199.eduroam.uu.se) (Read error: Connection reset by peer) |
| 17:24:50 | × | hightower2 quits (~hightower@213.147.110.20) (Ping timeout: 260 seconds) |
| 17:25:02 | → | azeem joins (~azeem@emp-89-199.eduroam.uu.se) |
| 17:25:18 | → | MQ-17J joins (~MQ-17J@d192-24-122-179.try.wideopenwest.com) |
| 17:25:29 | <dsal> | I had this issue when people were wanting to use persistent and then esqueleto and then like, I'll try to to learn that language, but I can already see things I know how to do in SQL that are either open bugs or just not on the radar. |
| 17:25:39 | × | MQ-17J quits (~MQ-17J@d192-24-122-179.try.wideopenwest.com) (Client Quit) |
| 17:26:00 | <dsal> | That one didn't go very far because there are too many things I can do easily in sql that I couldn't figure out how to do at all in fancy libs. |
| 17:26:09 | × | ezzieyguywuf quits (~Unknown@user/ezzieyguywuf) (Quit: "Rebooting new kernel") |
| 17:26:54 | <kuribas> | dsal: yeah, in my library, some things are easy to add, and other's require backwards incompatible change. |
| 17:27:03 | <dolio> | Yeah, getting all the things you can do in SQL wrapped into a library is also a challenge. |
| 17:27:13 | → | Hanicef joins (~gustaf@81-229-9-108-no92.tbcn.telia.com) |
| 17:27:33 | → | ezzieyguywuf joins (~Unknown@user/ezzieyguywuf) |
| 17:27:35 | <kuribas> | dsal: or I could make a new combinator, but then the library will be littered with combinators. |
| 17:27:59 | × | eggplantade quits (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Remote host closed the connection) |
| 17:28:08 | <kuribas> | for example, recently I found out MySQL supports tuples in a `in` statement. |
| 17:28:52 | × | max22- quits (~maxime@2a01cb088335980044786ab87c2c3d64.ipv6.abo.wanadoo.fr) (Remote host closed the connection) |
| 17:29:30 | × | azeem quits (~azeem@emp-89-199.eduroam.uu.se) (Ping timeout: 256 seconds) |
| 17:29:42 | → | max22- joins (~maxime@lfbn-ren-1-762-224.w81-53.abo.wanadoo.fr) |
| 17:30:09 | <kuribas> | WHERE (firstname, lastname) IN (`Bart`, `Simpson`), (`Barney`, `Gumbles`) |
| 17:30:38 | <dsal> | The impedance is unfortunate, but `postgresql-simple` isn't too bad. I'm using stuff like enums (bugs for support in persistent) and PostGIS and just trying to figure out how to make a normal 4-byte key and `insert into ... returning` kinds of things. I can't remember all the things that I had trouble with on day 1. |
| 17:31:45 | × | wei2912 quits (~wei2912@138.75.71.147) (Quit: Lost terminal) |
| 17:31:53 | → | johnny_sitar joins (~artur@078088015209.bialystok.vectranet.pl) |
| 17:32:29 | → | azeem joins (~azeem@2a00:801:238:f0f3:c4db:a6a8:71e6:c28) |
| 17:32:33 | <kuribas> | dsal: it also doesn't allow you to compose queries, matching parameters with the data can be error prone, etc... |
| 17:33:25 | <dsal> | Yeah. That gap is unfortunate. Best I can do is provide transactionally composable functions that take known types that we have `FromRow` and `ToRow` tested for. |
| 17:34:12 | <dsal> | This is similar to the "where do you draw the line" thing above. It's a bit loose, but easy to understand and flexible. Proper use makes it a bit harder to get wrong. |
| 17:34:21 | × | favonia quits (~favonia@user/favonia) (Ping timeout: 268 seconds) |
| 17:34:36 | → | shailangsa joins (~shailangs@host86-185-98-19.range86-185.btcentralplus.com) |
| 17:34:40 | × | mmhat quits (~mmh@55d4a8dc.access.ecotel.net) (Quit: WeeChat 3.3) |
| 17:35:25 | → | yinghua joins (~yinghua@2800:2121:1400:900:c56e:96f4:75cd:50ac) |
| 17:38:21 | <kuribas> | I have to luxury to be able to change the library when I need to add some syntax. |
| 17:41:26 | → | ec joins (~ec@gateway/tor-sasl/ec) |
| 17:41:31 | → | favonia joins (~favonia@user/favonia) |
| 17:42:20 | <kuribas> | But I should take sometime to implement the whole MySQL BNF syntax, document the library, and announce it. |
| 17:44:55 | → | dschrempf joins (~dominik@070-207.dynamic.dsl.fonira.net) |
| 17:47:16 | × | mbuf quits (~Shakthi@122.174.233.21) (Quit: Leaving) |
| 17:47:47 | <dsal> | I'd be pretty happy if MySQL just went missing one day and nobody had to think about it again. :) |
| 17:50:35 | <dolio> | Incidentally, there are techniques for getting `n + 0` to work just as well as `0 + n` and such. They're just not commonly implemented. Agda has preliminary work toward that, though. |
| 17:50:43 | → | whatsupdoc joins (uid509081@id-509081.hampstead.irccloud.com) |
| 17:51:02 | × | merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 256 seconds) |
| 17:51:40 | <dolio> | Right now you just have to tell it which additional equations it should use, I think. But it's possible for some amount of that to happen automatically by giving redundant cases in definitions and stuff. |
| 17:51:44 | <Cale> | There's the really easy one which is just to handicap n + 0 ;) |
| 17:53:22 | → | hightower2 joins (~hightower@213.147.110.20) |
| 17:53:56 | <Cale> | I think I might've heard that's what Zombie was about? |
| 17:54:45 | <Cale> | Get rid of the automatic use of beta-equivalence, but perhaps make it easier to use the equalities you've proven |
| 17:54:58 | <dolio> | I don't know. Zombie is more about being able to have a general recursive fragment of the language that doesn't cause problems when you're proving stuff, I think. |
| 17:55:10 | <dminuoso> | Cale: Regarding your dependent types earlier. To quote someone from -ot from yesterday: |
| 17:55:30 | <dminuoso> | "when I write idris, I just write my bugs at the type level instead" |
| 17:55:48 | → | Bleant joins (~Bleant@2804:7f7:d68c:6ec3:ba71:4b18:997c:9fc1) |
| 17:56:48 | <Bleant> | Good afternoon! (if it's afternoon where you live :D). I'm new to this channel, would it be appropriate to ask questions regarding a particular problem I am having? |
| 17:56:48 | × | chele quits (~chele@user/chele) (Remote host closed the connection) |
| 17:56:51 | <kuribas> | dminuoso: where I think idris (and dependent types) are useful, is not to proof the program correct, but to specify a specification at type level, and to prove the implementation compliant. |
| 17:57:04 | <geekosaur> | Bleant, sure! |
| 17:57:07 | <Cale> | Bleant: yeah, as long as it's Haskell-related :) |
| 17:57:18 | × | slaydr quits (~slaydr@45.131.194.34) (Quit: leaving) |
| 17:59:32 | × | nschoe quits (~quassel@178.251.84.79) (Ping timeout: 256 seconds) |
| 18:00:04 | <Bleant> | Thanks! I've implemented (though I've yet to confirm the correctness of the merge step) mergesort in Haskell using the ST Monad with unboxed arrays. I want to deepseq the resulting UArrays for benchmarking purposes, as merely printing would slow down the program, but I get an error stating that no instance for NFData has been declared for UArray. Since its constructors are hidden, I'm not sure what I could do. What could I do? |
| 18:00:06 | × | hightower2 quits (~hightower@213.147.110.20) (Ping timeout: 256 seconds) |
| 18:00:10 | → | eggplantade joins (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) |
| 18:00:36 | <Cale> | You can just seq in that case |
| 18:00:54 | <Cale> | UArrays don't have the facility for lazy evaluation, that's the unboxed part |
| 18:01:03 | <Cale> | So if any part of a UArray is evaluated, the whole thing is |
| 18:03:17 | × | yinghua quits (~yinghua@2800:2121:1400:900:c56e:96f4:75cd:50ac) (Read error: Connection reset by peer) |
| 18:03:35 | → | yinghua joins (~yinghua@2800:2121:1400:900:9d55:2c9d:5a16:a12) |
| 18:04:08 | → | vicfred joins (~vicfred@user/vicfred) |
| 18:05:35 | <Bleant> | Thank you! I will try and report back :) |
| 18:05:46 | × | slack1256 quits (~slack1256@191.126.227.206) (Ping timeout: 256 seconds) |
| 18:06:03 | → | slack1256 joins (~slack1256@191.125.227.82) |
| 18:06:39 | <monochrom> | Even the normal Array doesn't need deepseqing for sorting. |
| 18:07:18 | <Cale> | True, since you have to look at all the elements anyway, there's no worry that they might be unevaluated |
| 18:07:31 | → | aleator joins (~aleator@188-67-216-232.bb.dnainternet.fi) |
| 18:08:00 | <monochrom> | If you say "I set the 3rd element to fib 5000", that would need deepseqing, yes. |
| 18:08:16 | <monochrom> | But in sorting, you're just saying, "I set the 3rd element to a!7". |
| 18:08:24 | <maerwald> | who's good with windows here? What type of path is `\??\C:\foo`? Doesn't appear to be an extended-length path, yet the directory package treats it specially: https://git.io/JPbcY |
| 18:08:45 | → | hightower2 joins (~hightower@213.147.110.20) |
| 18:09:36 | × | ec quits (~ec@gateway/tor-sasl/ec) (Ping timeout: 276 seconds) |
| 18:10:24 | <geekosaur> | iirc it's just a way to hide the drive letter inside the path instead of in front of it. but double check that |
| 18:11:21 | <maerwald> | cmd.exe doesn't even accept this path |
| 18:11:23 | <monochrom> | simplifyWindows is a great name :) |
| 18:11:43 | <maerwald> | normalise "\\??????????????\\D:\lol" -> "D:\lol", which is even more confusing |
| 18:11:51 | <maerwald> | since that is definitely rejected on windows |
| 18:12:28 | <Cale> | Maybe you can git blame and figure out where this feature got added? |
| 18:12:54 | <Bleant> | If, in repeatedly calling the mergesort function, I get a list of thunks, will calling foldr (\x y -> x 'seq` y) () listOfThunks force the call to each individual sort, essentially evaluating every UArray? It's what I'm trying, but it's executing so fast for a million elements that I suspect I'm doing something wrong |
| 18:13:41 | <geekosaur> | (\x y -> x `seq` y) is the same as plain seq |
| 18:13:48 | × | dschrempf quits (~dominik@070-207.dynamic.dsl.fonira.net) (Ping timeout: 268 seconds) |
| 18:14:10 | <monochrom> | > foldr seq () [undefined, 3] |
| 18:14:12 | <lambdabot> | *Exception: Prelude.undefined |
| 18:14:21 | <monochrom> | > foldr seq () [3, undefined] |
| 18:14:22 | <lambdabot> | *Exception: Prelude.undefined |
| 18:14:27 | <monochrom> | > foldr seq () [3, 3] |
| 18:14:29 | <lambdabot> | () |
| 18:14:44 | <monochrom> | It seqs all elements. "Proved by a few test cases" |
| 18:15:03 | <geekosaur> | but as mentioned earlier the contents of the UArray are already evaluated, because they are unboxed |
| 18:15:20 | ← | Profpatsch parts (~Profpatsc@static.88-198-193-255.clients.your-server.de) (WeeChat 3.3) |
| 18:15:32 | <geekosaur> | I think it is only the UArray itself that can be a thunk |
| 18:15:46 | <Bleant> | What I'm trying to prevent is getting a list of thunks, but in not using them, not having the individual functions to mergesort called |
| 18:16:24 | <Bleant> | Something's weird, though. I'm running a million element ten thousand times, and it's going faster than my C implementation. I'll quadruple check |
| 18:16:33 | → | ec joins (~ec@gateway/tor-sasl/ec) |
| 18:16:40 | <monochrom> | Now, this is what you should watch out for: |
| 18:16:52 | <monochrom> | > const 42 (foldr seq () [undefined, 3]) |
| 18:16:54 | × | raehik quits (~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) (Ping timeout: 268 seconds) |
| 18:16:54 | <lambdabot> | 42 |
| 18:18:08 | × | aleator quits (~aleator@188-67-216-232.bb.dnainternet.fi) (Ping timeout: 268 seconds) |
| 18:18:36 | → | raehik joins (~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) |
| 18:18:49 | <Bleant> | I'm not familiar with const, unfortunately. I'll check it. What I'm doing currently is return $! foldr seq () [...] |
| 18:18:56 | <Cale> | const x y = x |
| 18:19:02 | → | burnsidesLlama joins (~burnsides@dhcp168-032.wadham.ox.ac.uk) |
| 18:19:07 | <monochrom> | I can do that too. |
| 18:19:13 | <monochrom> | > const 42 (return $! foldr seq () [undefined, 3]) |
| 18:19:15 | <lambdabot> | error: |
| 18:19:15 | <lambdabot> | • Could not deduce (Monad m0) arising from a use of ‘return’ |
| 18:19:15 | <lambdabot> | from the context: Num a |
| 18:19:30 | <monochrom> | Dammit. |
| 18:19:38 | <Cale> | Bleant: are you doing something like printing the () at the end? |
| 18:19:38 | <monochrom> | > const 42 (return $! foldr seq () [undefined, 3] :: Maybe ()) |
| 18:19:40 | <lambdabot> | 42 |
| 18:19:50 | <Bleant> | Wait, there is a GHCI bot? That's the coolest thing ever |
| 18:20:08 | <Bleant> | Cale: No, it's just the last statement in my main :: IO () |
| 18:20:27 | <Bleant> | How do I reply properly? |
| 18:20:33 | <monochrom> | Here is another strategy. You can print just one element of the sorted array. That will be quite enough to cause a lot of evaluations. |
| 18:20:41 | <monochrom> | or rather s/cause/ensure/ |
| 18:20:42 | → | econo joins (uid147250@user/econo) |
| 18:20:49 | <Cale> | Actually, what you have is probably fine, but it would be better to use Control.Exception.evaluate to force the evaluation to happen in sequence with IO |
| 18:21:13 | × | shidima quits (~shidima@84-104-108-90.cable.dynamic.v4.ziggo.nl) (Ping timeout: 268 seconds) |
| 18:21:13 | <int-e> | Bleant: Prefixing with nicks is as proper as it gets on IRC. |
| 18:21:16 | <geekosaur> | Bleant, lambdabot is not a ghci bot although it can evaluate expressions. but there is also yahb which is a ghci bot |
| 18:21:16 | <Cale> | Or yeah, just print one element of the array, which would guarantee that you've evaluated them all |
| 18:21:50 | <Bleant> | Gotta go, guys! Thanks for all the help. Looking forward to talking to you again :D |
| 18:21:54 | <int-e> | There's yahb which is actually a ghci frontend. |
| 18:22:02 | <Bleant> | I'll still take a look to see what's going on, of course |
| 18:22:02 | <int-e> | % foo = 1+1 |
| 18:22:02 | <yahb> | int-e: |
| 18:22:05 | <int-e> | % foo |
| 18:22:05 | <yahb> | int-e: 2 |
| 18:22:09 | × | Bleant quits (~Bleant@2804:7f7:d68c:6ec3:ba71:4b18:997c:9fc1) (Remote host closed the connection) |
| 18:24:55 | × | burnsidesLlama quits (~burnsides@dhcp168-032.wadham.ox.ac.uk) (Ping timeout: 268 seconds) |
| 18:31:36 | → | desantra joins (~skykanin@user/skykanin) |
| 18:34:03 | × | vicfred quits (~vicfred@user/vicfred) (Quit: Leaving) |
| 18:38:59 | → | dschrempf joins (~dominik@070-207.dynamic.dsl.fonira.net) |
| 18:42:07 | × | dsamperi quits (~dsamperi@2603-7000-3b42-5400-0c2e-16c3-2bfb-81aa.res6.spectrum.com) (Quit: Konversation terminated!) |
| 18:42:56 | × | Hanicef quits (~gustaf@81-229-9-108-no92.tbcn.telia.com) (Quit: leaving) |
| 18:44:38 | × | dschrempf quits (~dominik@070-207.dynamic.dsl.fonira.net) (Ping timeout: 268 seconds) |
| 18:50:35 | → | mc47 joins (~mc47@xmonad/TheMC47) |
| 18:50:35 | → | Lycurgus joins (~juan@98.4.112.204) |
| 18:53:56 | × | favonia quits (~favonia@user/favonia) (Ping timeout: 256 seconds) |
| 18:56:03 | × | azeem quits (~azeem@2a00:801:238:f0f3:c4db:a6a8:71e6:c28) (Quit: Quit) |
| 18:57:39 | × | tromp quits (~textual@dhcp-077-249-230-040.chello.nl) (Quit: My iMac has gone to sleep. ZZZzzz…) |
| 18:59:44 | × | Lycurgus quits (~juan@98.4.112.204) (Quit: Exeunt) |
| 19:01:00 | × | machinedgod quits (~machinedg@135-23-192-217.cpe.pppoe.ca) (Remote host closed the connection) |
| 19:02:28 | → | machinedgod joins (~machinedg@135-23-192-217.cpe.pppoe.ca) |
| 19:04:28 | → | aegon joins (~mike@174.127.249.180) |
| 19:06:05 | → | yinghua_ joins (~yinghua@2800:2121:1400:900:c56e:96f4:75cd:50ac) |
| 19:06:16 | → | sciencentistguy joins (~sciencent@hacksoc/ordinary-member) |
| 19:07:33 | → | favonia joins (~favonia@user/favonia) |
| 19:08:42 | × | yinghua quits (~yinghua@2800:2121:1400:900:9d55:2c9d:5a16:a12) (Ping timeout: 268 seconds) |
| 19:11:14 | × | raehik quits (~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) (Ping timeout: 260 seconds) |
| 19:16:22 | × | myShoggoth quits (~myShoggot@97-120-85-195.ptld.qwest.net) (Ping timeout: 260 seconds) |
| 19:18:18 | × | favonia quits (~favonia@user/favonia) (Ping timeout: 256 seconds) |
| 19:19:28 | → | myShoggoth joins (~myShoggot@97-120-85-195.ptld.qwest.net) |
| 19:19:51 | × | eggplantade quits (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Remote host closed the connection) |
| 19:20:33 | → | cads joins (~cads@ip-64-72-99-234.lasvegas.net) |
| 19:20:39 | → | tromp joins (~textual@dhcp-077-249-230-040.chello.nl) |
| 19:23:29 | × | hightower2 quits (~hightower@213.147.110.20) (Ping timeout: 268 seconds) |
| 19:25:17 | → | eggplantade joins (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) |
| 19:25:20 | → | ubert joins (~Thunderbi@p200300ecdf4fca7ce019fddc82d0353e.dip0.t-ipconnect.de) |
| 19:25:58 | × | Feuermagier quits (~Feuermagi@user/feuermagier) (Ping timeout: 268 seconds) |
| 19:30:49 | × | sonny quits (~sonny@bras-base-london1483w-grc-30-74-12-157-200.dsl.bell.ca) (Ping timeout: 256 seconds) |
| 19:33:21 | × | johnny_sitar quits (~artur@078088015209.bialystok.vectranet.pl) (Ping timeout: 268 seconds) |
| 19:35:47 | × | ent quits (entgod@kapsi.fi) (Ping timeout: 264 seconds) |
| 19:36:20 | → | ent joins (entgod@kapsi.fi) |
| 19:36:52 | × | eggplantade quits (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Remote host closed the connection) |
| 19:37:28 | × | kuribas quits (~user@ptr-25vy0i85hqqtidw9mko.18120a2.ip6.access.telenet.be) (Remote host closed the connection) |
| 19:37:39 | → | lavaman joins (~lavaman@98.38.249.169) |
| 19:39:31 | × | vysn quits (~vysn@user/vysn) (Ping timeout: 268 seconds) |
| 19:42:07 | → | raehik joins (~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) |
| 19:44:28 | <aegon> | i'm using derive generic on MessagePack instances of data. I dug in and saw that encoding / decoding was using from and to from Generics to order things. How can i look up how that is ordering objects? (i need to parse these from a different language and order matters for the encoding / decoding) |
| 19:44:55 | → | unit73e joins (~emanuel@2001:818:e8dd:7c00:32b5:c2ff:fe6b:5291) |
| 19:45:32 | <aegon> | i'm also using it on a UUID and i'm not sure if its using show on it or whatnot to encode, learniung how to poke around at generic derivations today it seems |
| 19:47:41 | → | merijn joins (~merijn@83-160-49-249.ip.xs4all.nl) |
| 19:48:17 | eldritch__ | is now known as eldritch |
| 19:49:30 | → | sprout_ joins (~quassel@2a02:a467:ccd6:1:f161:c9c3:b403:49f6) |
| 19:49:38 | <aegon> | hmm, i guess i could use from and to manually on an instance and just look |
| 19:49:39 | <dsal> | If order matters in such a way that isn't clearly defined by spec, I wouldn't expect derived values to do exactly what you need. |
| 19:50:24 | <aegon> | the order within a field matters but the spec doesnt state which value comes first and there are no unique ids or names thrown into the packed representation, just type identifiers |
| 19:51:20 | <aegon> | is the order of GHC.Generics (form, to) unreliable? |
| 19:51:45 | <aegon> | er, unreliable / undetermined |
| 19:52:29 | × | sprout quits (~quassel@2a02:a467:ccd6:1:58cd:ccc2:f66c:e3b) (Ping timeout: 268 seconds) |
| 19:53:21 | <aegon> | i think manually instancing is fine i'm just trying to understand Generics more |
| 19:53:27 | → | burnsidesLlama joins (~burnsides@dhcp168-032.wadham.ox.ac.uk) |
| 19:54:10 | <aegon> | this is a wierd case to me because it accepted / auto derived UUID, which doesn't have an instance of the target for derivation, but i can't see anything in the lib that determines or defines the needed class by Show or Storable or StorableFixed so :? |
| 19:54:18 | → | mmhat joins (~mmh@55d4a8dc.access.ecotel.net) |
| 19:54:32 | <aegon> | it might be doing it by constructor and data fields? |
| 19:54:43 | <dsal> | If the spec doesn't say an order matters, but an order matters to your application, then it sounds like you're going beyond the specification so a generic implementation shouldn't help. |
| 19:55:05 | <dsal> | I'm not familiar with the specific things you're talking about, though. |
| 19:55:50 | <aegon> | its messge pack, the spec just doen't choose to restrict a sequencing |
| 19:56:04 | <dsal> | Understood. I just barely know what message pack is. :) |
| 19:56:09 | <aegon> | you could say thats a bad spec but it also mostly doesn't matter, the use case is apps that know data ahead of time |
| 19:56:34 | → | eggplantade joins (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) |
| 19:56:46 | <aegon> | its a json like format specializing in fast, small, in place parsing / encoding with good memory management controls |
| 19:56:50 | <dsal> | Just at the point where there's no canonical ordering by spec, but you need an ordering, I'd expect to have to write some code. |
| 19:57:22 | <aegon> | yeah, it looks like there is a instance based of Storable but also Unbox, does a class have to explicitly instance Unbox or is it a side effect possibly of Bang syntax |
| 19:57:48 | <aegon> | the class in question doesn't have an Unbox written but afaik is written "unboxed" `data UUID = UUID !Word64 !Word64` |
| 19:58:44 | × | desantra quits (~skykanin@user/skykanin) (Quit: WeeChat 3.3) |
| 20:00:23 | × | krjst quits (~krjst@2604:a880:800:c1::16b:8001) (Ping timeout: 246 seconds) |
| 20:01:07 | × | pop3 quits (~pop3@user/pop3) (Remote host closed the connection) |
| 20:01:27 | → | hightower2 joins (~hightower@213.147.110.20) |
| 20:01:42 | <aegon> | wellll, manual it is, i don't want the Storable derived version of this, but the Binary version and hwo knows what these generics are doing |
| 20:01:57 | → | pop3 joins (~pop3@user/pop3) |
| 20:03:53 | × | pop3 quits (~pop3@user/pop3) (Remote host closed the connection) |
| 20:04:38 | → | pop3 joins (~pop3@user/pop3) |
| 20:05:25 | × | juhp quits (~juhp@128.106.188.220) (Ping timeout: 268 seconds) |
| 20:05:39 | <dsal> | Sometimes, I spend so much of my day trying to figure out how to avoid writing code that I don't even write any code. |
| 20:06:40 | × | raehik quits (~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) (Ping timeout: 268 seconds) |
| 20:07:02 | × | hightower2 quits (~hightower@213.147.110.20) (Ping timeout: 256 seconds) |
| 20:07:35 | → | juhp joins (~juhp@128.106.188.220) |
| 20:09:34 | <aegon> | lol, i live with another coder and she's doing the same today. Afaik the whole morning has been spent trying to figure out how to use the infer keyword in typescript to remove the need for a switch statement... in all liklihood this would end up in javascript with the same runtime. but we both get sucked down typing rabbit holes |
| 20:10:18 | <aegon> | i'm manually instancing now though |
| 20:10:36 | <dsal> | I was working with interns doing typescript and it proxied a lot of pain back to me. |
| 20:10:48 | <shapr> | I shall change my title to explorer of rabbit holes. |
| 20:11:08 | <geekosaur> | <-- human fuzzer |
| 20:13:55 | × | albet70 quits (~xxx@2400:8902::f03c:92ff:fe60:98d8) (Remote host closed the connection) |
| 20:14:42 | × | mjs2600 quits (~mjs2600@c-24-91-3-49.hsd1.vt.comcast.net) (Ping timeout: 260 seconds) |
| 20:15:53 | × | Guest41 quits (~Guest41@eth-west-pareq2-46-193-4-100.wb.wifirst.net) (Quit: Client closed) |
| 20:17:14 | × | alx741 quits (~alx741@186.178.109.189) (Ping timeout: 256 seconds) |
| 20:20:01 | → | albet70 joins (~xxx@2400:8902::f03c:92ff:fe60:98d8) |
| 20:21:23 | × | merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 264 seconds) |
| 20:24:21 | × | caef^ quits (~caef@wsip-98-188-242-6.mc.at.cox.net) (Remote host closed the connection) |
| 20:29:43 | × | eggplantade quits (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Remote host closed the connection) |
| 20:31:45 | → | alx741 joins (~alx741@181.196.68.55) |
| 20:32:53 | → | lortabac joins (~lortabac@2a01:e0a:541:b8f0:b05b:c1ec:b58c:ef2d) |
| 20:32:54 | → | eggplantade joins (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) |
| 20:38:07 | × | slack1256 quits (~slack1256@191.125.227.82) (Ping timeout: 268 seconds) |
| 20:39:04 | → | pavonia joins (~user@user/siracusa) |
| 20:41:38 | → | krjst joins (~krjst@2604:a880:800:c1::16b:8001) |
| 20:46:54 | → | doyougnu joins (~doyougnu@c-73-25-202-122.hsd1.or.comcast.net) |
| 20:48:26 | × | dhouthoo quits (~dhouthoo@178-117-36-167.access.telenet.be) (Quit: WeeChat 3.3) |
| 20:49:54 | → | sprout joins (~quassel@2a02:a467:ccd6:1:5495:68b3:d03c:732e) |
| 20:51:13 | → | _ht joins (~quassel@82-169-194-8.biz.kpn.net) |
| 20:53:31 | × | sprout_ quits (~quassel@2a02:a467:ccd6:1:f161:c9c3:b403:49f6) (Ping timeout: 268 seconds) |
| 20:59:42 | × | xff0x quits (~xff0x@2001:1a81:5236:1e00:2c63:dc9c:df4d:2374) (Ping timeout: 268 seconds) |
| 21:00:18 | → | xff0x joins (~xff0x@2001:1a81:5236:1e00:5867:e42a:e65f:e597) |
| 21:00:56 | <aegon> | hmm, will GHC always choose the most specific instance? Trying to figure out if i need to use a newtype here. UUID is an instance of Storable which means by proxy it has an instance of MessagePack already.. however, i always want my instances to use a custom instance of message pack that uses bytestring serialization (which is rfc compliant) can i get away with instancing this for uuid somewhere in my |
| 21:01:02 | <aegon> | module and be assured it will be used within the module instaead of the generic Storable instance? |
| 21:02:05 | → | werner100 joins (~werner100@2601:2c2:400:4440:99e8:39f6:7f1b:a334) |
| 21:02:58 | × | _ht quits (~quassel@82-169-194-8.biz.kpn.net) (Remote host closed the connection) |
| 21:03:43 | → | Guest4193 joins (~Guest41@eth-west-pareq2-46-193-4-100.wb.wifirst.net) |
| 21:04:16 | × | wonko quits (~wjc@user/wonko) (Ping timeout: 256 seconds) |
| 21:05:24 | → | dsrt^ joins (~dsrt@wsip-98-188-242-6.mc.at.cox.net) |
| 21:05:39 | → | johnny_sitar joins (~artur@078088015209.bialystok.vectranet.pl) |
| 21:07:33 | × | eggplantade quits (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Remote host closed the connection) |
| 21:07:46 | <geekosaur> | it won't let you without an OVERLAP pragma of some kind, and even then it's best effort, not guaranteed |
| 21:08:45 | <geekosaur> | actually if there's already an instance for that type I think you may need IncoherentInstances. or it m9ight just not let you at all |
| 21:08:51 | <geekosaur> | you'd have to newtype it |
| 21:09:26 | <awpr> | if this is https://hackage.haskell.org/package/msgpack-1.0.1.0/docs/Data-MessagePack-Object.html#t:MessagePack, there isn't a catch-all instance based on Storable, at least not in that package |
| 21:11:01 | <geekosaur> | catch-all instances are generally a bad thing, so I'd not expect to see one. unless you defined it yourself, in which case you may be about to discover why it's a bad idea |
| 21:11:04 | × | sciencentistguy quits (~sciencent@hacksoc/ordinary-member) (Ping timeout: 256 seconds) |
| 21:11:57 | <aegon> | awpr's right, itstht package and i was misreading the constrains on instances for Vector a :! |
| 21:17:33 | × | werner100 quits (~werner100@2601:2c2:400:4440:99e8:39f6:7f1b:a334) (Quit: Ping timeout (120 seconds)) |
| 21:18:02 | → | Pickchea joins (~private@user/pickchea) |
| 21:19:31 | → | Tuplanolla joins (~Tuplanoll@91-159-69-50.elisa-laajakaista.fi) |
| 21:26:12 | × | yrlnry quits (~mjd@pool-74-109-22-90.phlapa.fios.verizon.net) (Ping timeout: 268 seconds) |
| 21:33:45 | → | sonny joins (~sonny@bras-base-london1483w-grc-30-74-12-157-200.dsl.bell.ca) |
| 21:33:45 | × | lortabac quits (~lortabac@2a01:e0a:541:b8f0:b05b:c1ec:b58c:ef2d) (Quit: WeeChat 2.8) |
| 21:35:58 | ← | sonny parts (~sonny@bras-base-london1483w-grc-30-74-12-157-200.dsl.bell.ca) () |
| 21:36:22 | × | fendor quits (~fendor@178.115.33.172.wireless.dyn.drei.com) (Remote host closed the connection) |
| 21:37:03 | × | azimut_ quits (~azimut@gateway/tor-sasl/azimut) (Remote host closed the connection) |
| 21:37:34 | → | azimut joins (~azimut@gateway/tor-sasl/azimut) |
| 21:37:58 | → | fendor joins (~fendor@178.115.33.172.wireless.dyn.drei.com) |
| 21:40:43 | × | pop3 quits (~pop3@user/pop3) (Remote host closed the connection) |
| 21:41:27 | → | acidjnk_new joins (~acidjnk@p200300d0c726704784feaa35b47dd204.dip0.t-ipconnect.de) |
| 21:48:25 | × | gg quits (~gg@88.160.100.84) (Ping timeout: 268 seconds) |
| 21:58:28 | → | pop3 joins (~pop3@user/pop3) |
| 21:59:23 | × | fendor quits (~fendor@178.115.33.172.wireless.dyn.drei.com) (Read error: Connection reset by peer) |
| 22:01:38 | → | gg joins (~gg@2a01:e0a:819:1510:89f0:97ca:21c4:6ea6) |
| 22:03:34 | × | Pickchea quits (~private@user/pickchea) (Quit: Leaving) |
| 22:07:45 | × | shapr quits (~user@pool-100-36-247-68.washdc.fios.verizon.net) (Remote host closed the connection) |
| 22:08:02 | → | eggplantade joins (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) |
| 22:08:02 | → | hightower2 joins (~hightower@213.147.110.20) |
| 22:08:23 | × | johnny_sitar quits (~artur@078088015209.bialystok.vectranet.pl) (Remote host closed the connection) |
| 22:11:21 | → | vysn joins (~vysn@user/vysn) |
| 22:11:27 | → | [itchyjunk] joins (~itchyjunk@user/itchyjunk/x-7353470) |
| 22:13:04 | × | eggplantade quits (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 268 seconds) |
| 22:15:16 | × | cosimone quits (~user@93-44-187-173.ip98.fastwebnet.it) (Quit: ERC (IRC client for Emacs 27.1)) |
| 22:15:50 | × | burnsidesLlama quits (~burnsides@dhcp168-032.wadham.ox.ac.uk) (Remote host closed the connection) |
| 22:16:08 | × | mc47 quits (~mc47@xmonad/TheMC47) (Remote host closed the connection) |
| 22:17:00 | × | jinsun quits (~quassel@user/jinsun) (Read error: Connection reset by peer) |
| 22:17:52 | → | merijn joins (~merijn@83-160-49-249.ip.xs4all.nl) |
| 22:18:26 | → | jinsun joins (~quassel@user/jinsun) |
| 22:19:11 | → | [_] joins (~itchyjunk@user/itchyjunk/x-7353470) |
| 22:21:28 | → | shapr joins (~user@pool-100-36-247-68.washdc.fios.verizon.net) |
| 22:22:20 | × | [itchyjunk] quits (~itchyjunk@user/itchyjunk/x-7353470) (Ping timeout: 268 seconds) |
| 22:25:22 | × | lavaman quits (~lavaman@98.38.249.169) (Remote host closed the connection) |
| 22:26:01 | × | myShoggoth quits (~myShoggot@97-120-85-195.ptld.qwest.net) (Ping timeout: 268 seconds) |
| 22:34:57 | → | burnsidesLlama joins (~burnsides@dhcp168-032.wadham.ox.ac.uk) |
| 22:36:01 | × | pop3 quits (~pop3@user/pop3) (Remote host closed the connection) |
| 22:36:15 | → | myShoggoth joins (~myShoggot@97-120-85-195.ptld.qwest.net) |
| 22:36:44 | → | pop3 joins (~pop3@user/pop3) |
| 22:41:52 | → | mestre joins (~mestre@191.177.175.57) |
| 22:42:42 | × | gehmehgeh quits (~user@user/gehmehgeh) (Quit: Leaving) |
| 22:42:52 | × | doyougnu quits (~doyougnu@c-73-25-202-122.hsd1.or.comcast.net) (Ping timeout: 256 seconds) |
| 22:43:24 | → | Inst_ joins (~Inst@2601:6c4:4080:3f80:1d49:739d:9075:d5df) |
| 22:46:56 | × | max22- quits (~maxime@lfbn-ren-1-762-224.w81-53.abo.wanadoo.fr) (Quit: Leaving) |
| 22:47:42 | × | Inst quits (~Inst@2601:6c4:4080:3f80:cd36:4dbb:1af8:be8) (Ping timeout: 260 seconds) |
| 22:51:53 | × | mestre quits (~mestre@191.177.175.57) (Quit: Lost terminal) |
| 22:52:32 | × | merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 268 seconds) |
| 22:58:44 | × | ec quits (~ec@gateway/tor-sasl/ec) (Quit: ec) |
| 22:59:56 | × | xff0x quits (~xff0x@2001:1a81:5236:1e00:5867:e42a:e65f:e597) (Ping timeout: 268 seconds) |
| 23:00:29 | → | xff0x joins (~xff0x@2001:1a81:5236:1e00:dda8:eac2:4d01:562e) |
| 23:06:50 | → | raehik joins (~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) |
| 23:09:45 | × | michalz quits (~michalz@185.246.204.58) (Remote host closed the connection) |
| 23:17:49 | × | unit73e quits (~emanuel@2001:818:e8dd:7c00:32b5:c2ff:fe6b:5291) (Ping timeout: 268 seconds) |
| 23:20:26 | × | myShoggoth quits (~myShoggot@97-120-85-195.ptld.qwest.net) (Ping timeout: 260 seconds) |
| 23:28:39 | → | eggplantade joins (~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) |
| 23:31:38 | → | onion joins (~z@user/zero) |
| 23:32:04 | ← | onion parts (~z@user/zero) () |
| 23:32:08 | → | onion joins (~z@user/zero) |
| 23:32:52 | ← | onion parts (~z@user/zero) () |
| 23:37:11 | → | nvmd joins (~nvmd@user/nvmd) |
| 23:39:20 | → | brainfreeze joins (~brainfree@2a03:1b20:4:f011::20d) |
| 23:40:09 | → | myShoggoth joins (~myShoggot@97-120-85-195.ptld.qwest.net) |
| 23:41:55 | → | wroathe joins (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) |
| 23:41:55 | × | myShoggoth quits (~myShoggot@97-120-85-195.ptld.qwest.net) (Client Quit) |
| 23:41:55 | × | wroathe quits (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Changing host) |
| 23:41:55 | → | wroathe joins (~wroathe@user/wroathe) |
| 23:45:12 | × | raehik quits (~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) (Ping timeout: 256 seconds) |
| 23:50:54 | × | emf quits (~emf@2620:10d:c090:400::5:ba1c) (Quit: emf) |
| 23:51:33 | × | burnsidesLlama quits (~burnsides@dhcp168-032.wadham.ox.ac.uk) (Remote host closed the connection) |
All times are in UTC on 2021-11-04.