2024/03/09

2024-03-09 00:00:55 +0100acidjnk_new3(~acidjnk@p200300d6e737e7998d5743bf05995198.dip0.t-ipconnect.de) (Ping timeout: 256 seconds)
2024-03-09 00:04:27 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2024-03-09 00:12:04 +0100 <monochrom> The name lookup is used up by Prelude in GHC 9.4.* :(
2024-03-09 00:12:48 +0100 <monochrom> Hrm maybe it has been there longer.
2024-03-09 00:15:27 +0100 <geekosaur> https://downloads.haskell.org/ghc/6.6.1/docs/html/libraries/base/Prelude.html#v%3Alookup
2024-03-09 00:16:06 +0100 <int-e> gah, "name lookup" is a technical term of its own... failed to parse
2024-03-09 00:17:29 +0100 <int-e> monochrom: it's in the Haskell 98 report Prelude as part of PreludeList
2024-03-09 00:17:40 +0100 <int-e> So "forever".
2024-03-09 00:17:57 +0100 <monochrom> :(
2024-03-09 00:19:38 +0100son0p(~ff@152.203.102.157)
2024-03-09 00:23:59 +0100machinedgod(~machinedg@d173-183-246-216.abhsia.telus.net)
2024-03-09 00:24:36 +0100wootehfoot(~wootehfoo@user/wootehfoot) (Read error: Connection reset by peer)
2024-03-09 00:28:42 +0100 <ph88> is there some ghc version that doesn't require you to list mtl as a separate package ?
2024-03-09 00:29:30 +0100bitdex(~bitdex@gateway/tor-sasl/bitdex)
2024-03-09 00:29:48 +0100 <geekosaur> 5.x maybe
2024-03-09 00:30:11 +0100 <ph88> wow that's old
2024-03-09 00:31:16 +0100 <ph88> when i have -Weverything -Wno-incomplete-uni-patterns why does it still complain about incomplete-uni-patterns ?
2024-03-09 00:33:10 +0100 <glguy> ph88: I'd guess you have another flag after that that turns them back on
2024-03-09 00:33:26 +0100 <glguy> or that the order you wrote here isn't the order you wrote them to the compiler
2024-03-09 00:33:31 +0100tri(~tri@ool-18bc2e74.dyn.optonline.net) (Remote host closed the connection)
2024-03-09 00:33:42 +0100 <EvanR> you have to lookup the name name lookup
2024-03-09 00:34:06 +0100tri(~tri@ool-18bc2e74.dyn.optonline.net)
2024-03-09 00:37:23 +0100 <ph88> glguy, i have it like this https://bpa.st/GC5Q building with stack build
2024-03-09 00:38:22 +0100tri(~tri@ool-18bc2e74.dyn.optonline.net) (Ping timeout: 246 seconds)
2024-03-09 00:42:21 +0100mizlan(~mizlan@2607:f010:2e9:b:a0b8:d43d:4e1e:e149) (Remote host closed the connection)
2024-03-09 00:43:12 +0100L29Ah(~L29Ah@wikipedia/L29Ah) (Read error: Connection reset by peer)
2024-03-09 00:43:44 +0100mizlan(~mizlan@wifi-131-179-21-178.host.ucla.edu)
2024-03-09 00:46:30 +0100mizlan(~mizlan@wifi-131-179-21-178.host.ucla.edu) (Remote host closed the connection)
2024-03-09 00:47:54 +0100mizlan(~mizlan@wifi-131-179-21-178.host.ucla.edu)
2024-03-09 00:50:14 +0100Guest87(~Guest34@2409:40f2:1020:7082:a9b9:5ddd:1c1:e02d)
2024-03-09 00:50:28 +0100renpose(~renpose@user/renpose)
2024-03-09 00:50:46 +0100 <geekosaur> did you forget to add it to the executable stanza?
2024-03-09 00:51:31 +0100 <geekosaur> cf. line 18
2024-03-09 00:51:50 +0100 <geekosaur> also perhaps you have things set up wrong such that it's rebuilding the library as part of the executable
2024-03-09 00:52:05 +0100mizlan(~mizlan@wifi-131-179-21-178.host.ucla.edu) (Ping timeout: 240 seconds)
2024-03-09 00:52:14 +0100Guest87(~Guest34@2409:40f2:1020:7082:a9b9:5ddd:1c1:e02d) (Client Quit)
2024-03-09 00:52:18 +0100 <geekosaur> (commonly this means you tried to use the same surce directory for both)
2024-03-09 00:52:25 +0100 <geekosaur> *source
2024-03-09 00:55:38 +0100 <geekosaur> sorry, I meant line 18 of the build log, which shows it configuring and building the executable after building the library
2024-03-09 00:55:50 +0100 <renpose> Is there a way to unzip(ish) a HKD record generically: When I have `Record mode = { v :: mode :- T, ... }` and I have modes for `T` (Value), `IO T` (Fetch), and `T -> IO ()` (Store) and a combined mode `(IO T, T -> IO T)` (Loc). Given types in combined mode can I split them? So a generic function `Record Loc -> (Record Fetch, Record Store)`?
2024-03-09 00:57:03 +0100 <renpose> Excuse formatting, I have a readable, cleaned up, commented and minimal example: https://pastebin.com/CThDgD2E
2024-03-09 00:57:56 +0100 <renpose> I can generate the combined record, but struggle with the `K1` case for the split version. Surely this is some kind of pattern that has occurred somewhere and I just don't know it?
2024-03-09 01:00:46 +0100 <renpose> (ChatGPT claims it is impossible and Google was not of much help)
2024-03-09 01:01:16 +0100 <geekosaur> ph88, you have Data.C2Hsc in other-modules for the executable,, this causes it to be rebuilt for the executable. You probably want the executable to depend on the library instead
2024-03-09 01:02:26 +0100glguysees the highlight and then geekosaur having the right answer
2024-03-09 01:02:27 +0100jargon(~jargon@154.sub-174-205-226.myvzw.com) (Remote host closed the connection)
2024-03-09 01:02:38 +0100peterbecich(~Thunderbi@047-229-123-186.res.spectrum.com)
2024-03-09 01:03:27 +0100 <ph88> geekosaur, i rebuild everything library and executable. Not sure what you mean with missing executable stanza, it's on line 66
2024-03-09 01:03:49 +0100 <geekosaur> yes, but its ghc-options doesn't have -Wno-incomplete-uni-patterns
2024-03-09 01:04:15 +0100 <ph88> ah it works like that
2024-03-09 01:04:17 +0100 <geekosaur> and because you listed Data.C2Hsc in its other-modules, it rebuilds that module again with the execcutable's ghc-options
2024-03-09 01:04:38 +0100 <ph88> geekosaur, did i mess up line 70? i thought i need to specify that the executable is using the module from the main library
2024-03-09 01:05:01 +0100 <geekosaur> you want to list the library in your build-depends
2024-03-09 01:05:22 +0100 <geekosaur> that is, you want the executable to have a dependency on c2hsc
2024-03-09 01:05:34 +0100 <geekosaur> which will be resolved to the library part
2024-03-09 01:06:10 +0100 <ph88> geekosaur, i did that because i was getting this warning Warning: The following modules should be added to exposed-modules or other-modules
2024-03-09 01:06:40 +0100 <ph88> In exe:c2hsc: Data.C2Hsc
2024-03-09 01:07:09 +0100 <geekosaur> that's because everything is using the same source directory (which defaults to .) so it finds the module while building the executable and wants to rebuild it again
2024-03-09 01:07:12 +0100target_i(~target_i@user/target-i/x-6023099) (Quit: leaving)
2024-03-09 01:07:35 +0100tri(~tri@ool-18bc2e74.dyn.optonline.net)
2024-03-09 01:07:38 +0100 <geekosaur> normally you use different hs-sources dirs for different components, and have dependencies between the components
2024-03-09 01:08:12 +0100 <ph88> geekosaur, the library is in ./Data and the executable in . what do you mean same directory ?
2024-03-09 01:08:35 +0100 <geekosaur> Data is part of the library path (Data.C2Hsc)
2024-03-09 01:08:47 +0100 <geekosaur> so it is found from source directory .
2024-03-09 01:09:42 +0100 <geekosaur> that is, the source for a module Foo.Bar is Foo/Bar.hs
2024-03-09 01:09:44 +0100mizlan(~mizlan@wifi-131-179-21-178.host.ucla.edu)
2024-03-09 01:11:03 +0100 <ph88> aaah i see thanks
2024-03-09 01:11:49 +0100mizlan(~mizlan@wifi-131-179-21-178.host.ucla.edu) (Remote host closed the connection)
2024-03-09 01:12:27 +0100mizlan(~mizlan@2607:f010:2e9:b:41e2:3511:eccc:fc51)
2024-03-09 01:12:31 +0100peterbecich(~Thunderbi@047-229-123-186.res.spectrum.com) (Ping timeout: 272 seconds)
2024-03-09 01:12:34 +0100tri(~tri@ool-18bc2e74.dyn.optonline.net) (Ping timeout: 264 seconds)
2024-03-09 01:15:25 +0100rvalue(~rvalue@user/rvalue) (Ping timeout: 264 seconds)
2024-03-09 01:17:25 +0100califax(~califax@user/califx) (Remote host closed the connection)
2024-03-09 01:17:50 +0100califax(~califax@user/califx)
2024-03-09 01:22:09 +0100igemnace(~ian@user/igemnace)
2024-03-09 01:38:16 +0100L29Ah(~L29Ah@wikipedia/L29Ah)
2024-03-09 01:39:36 +0100oo_miguel(~Thunderbi@78-11-181-16.static.ip.netia.com.pl) (Ping timeout: 255 seconds)
2024-03-09 01:44:11 +0100 <renpose> It is not [distributive](https://github.com/ekmett/distributive), or is it?
2024-03-09 01:44:24 +0100 <renpose> oh my, i think i need a break from this
2024-03-09 01:44:57 +0100mvk(~mvk@2607:fea8:5c96:5800::f1d8)
2024-03-09 01:45:12 +0100tri(~tri@ool-18bc2e74.dyn.optonline.net)
2024-03-09 01:45:46 +0100mvk(~mvk@2607:fea8:5c96:5800::f1d8) (Client Quit)
2024-03-09 01:45:55 +0100ski(~ski@ext-1-033.eduroam.chalmers.se) (Ping timeout: 255 seconds)
2024-03-09 01:46:28 +0100igemnace(~ian@user/igemnace) (Quit: WeeChat 4.2.1)
2024-03-09 01:47:23 +0100ski(~ski@ext-1-033.eduroam.chalmers.se)
2024-03-09 01:49:18 +0100tri(~tri@ool-18bc2e74.dyn.optonline.net) (Remote host closed the connection)
2024-03-09 01:49:31 +0100tri(~tri@ool-18bc2e74.dyn.optonline.net)
2024-03-09 01:58:23 +0100Inst(~Inst@120.244.192.27)
2024-03-09 01:58:43 +0100 <Inst> did anyone ever try to make overloaded chars a thing in Haskell?
2024-03-09 01:58:53 +0100 <Inst> Can't possibly figure out what you'd use it for, but it'd be hilarious
2024-03-09 02:02:12 +0100califax(~califax@user/califx) (Remote host closed the connection)
2024-03-09 02:05:05 +0100dsrt^(~cd@c-98-242-74-66.hsd1.ga.comcast.net) (Remote host closed the connection)
2024-03-09 02:07:53 +0100jargon(~jargon@154.sub-174-205-226.myvzw.com)
2024-03-09 02:08:43 +0100jargon(~jargon@154.sub-174-205-226.myvzw.com) (Remote host closed the connection)
2024-03-09 02:08:51 +0100ph88(~ph88@2a02:8109:9e26:c800:f5bf:fee6:a40b:7301) (Remote host closed the connection)
2024-03-09 02:09:10 +0100califax(~califax@user/califx)
2024-03-09 02:10:08 +0100jargon(~jargon@154.sub-174-205-226.myvzw.com)
2024-03-09 02:12:36 +0100 <haskellbridge> <s​m> Inst you troublemaker
2024-03-09 02:13:01 +0100 <Inst> Sorry I've been gone, I decided learning Marxism and Communism was more fun than Haskell
2024-03-09 02:13:03 +0100 <haskellbridge> <s​m> stop having ideas 😆
2024-03-09 02:13:16 +0100mizlan(~mizlan@2607:f010:2e9:b:41e2:3511:eccc:fc51) (Ping timeout: 268 seconds)
2024-03-09 02:13:56 +0100 <Inst> also I need to fulfill sclv's dream by making Haskell way too Red for Anduril to touch
2024-03-09 02:14:31 +0100 <sclv> lol
2024-03-09 02:17:19 +0100 <jle`> renpose: i've had pretty bad luck with chatgpt and haskell heh. it should be possible, since it's possible at least via generics-sop
2024-03-09 02:17:58 +0100 <bontaq> it's weird, I've gotten some alright results w it but I do have to tell it it's wrong to to check it's work a lot
2024-03-09 02:18:56 +0100 <jle`> i guess maybe with respect to type-level programming it struggles since i don't think there's much of a corpus for it to draw from
2024-03-09 02:20:01 +0100 <jle`> it would have to somehow get a mental model of dependently typed programming from the small corpus of dependently typed programs or literature and then synthesize it against the constantly changing GHC capabilities
2024-03-09 02:21:05 +0100 <jle`> (in the context of renpose's original question)
2024-03-09 02:23:01 +0100 <sclv> Inst btw i am in both a categorical topology reading group and a Capital vol 3 reading group :-)
2024-03-09 02:25:54 +0100mizlan(~mizlan@wifi-131-179-21-178.host.ucla.edu)
2024-03-09 02:30:11 +0100ec(~ec@gateway/tor-sasl/ec) (Remote host closed the connection)
2024-03-09 02:30:24 +0100mizlan(~mizlan@wifi-131-179-21-178.host.ucla.edu) (Ping timeout: 260 seconds)
2024-03-09 02:30:51 +0100ec(~ec@gateway/tor-sasl/ec)
2024-03-09 02:36:25 +0100bitdex(~bitdex@gateway/tor-sasl/bitdex) (Read error: Connection reset by peer)
2024-03-09 02:36:25 +0100chexum(~quassel@gateway/tor-sasl/chexum) (Remote host closed the connection)
2024-03-09 02:37:06 +0100chexum(~quassel@gateway/tor-sasl/chexum)
2024-03-09 02:37:35 +0100bitdex(~bitdex@gateway/tor-sasl/bitdex)
2024-03-09 02:37:52 +0100 <bontaq> part of a balanced meal, lil haskell, lil marx
2024-03-09 02:43:23 +0100 <Inst> On my copy it reads:
2024-03-09 02:44:02 +0100tri(~tri@ool-18bc2e74.dyn.optonline.net) (Remote host closed the connection)
2024-03-09 02:45:30 +0100 <Inst> 出版物中任何不符合中华人民共和国主权,宪法和法规的内容,该不认可。
2024-03-09 02:45:42 +0100 <Inst> Any content in the publication that is not in accordance with the sovereignty of the People's Republic of China, its constitution and laws and regulations is not endorsed.
2024-03-09 02:45:43 +0100 <Inst> ;)
2024-03-09 02:46:17 +0100 <int-e> followed by 5 pages?
2024-03-09 02:49:25 +0100 <Inst> You can buy 1984 here both in Western editions and in translation. :)
2024-03-09 02:49:51 +0100 <Inst> I think it's more that the censor tried reading it, then gave up. :)
2024-03-09 02:52:19 +0100bitdex(~bitdex@gateway/tor-sasl/bitdex) (Remote host closed the connection)
2024-03-09 02:53:41 +0100bitdex(~bitdex@gateway/tor-sasl/bitdex)
2024-03-09 03:00:02 +0100Lord_of_Life(~Lord@user/lord-of-life/x-2819915) (Ping timeout: 252 seconds)
2024-03-09 03:01:03 +0100waleee(~waleee@h-176-10-144-38.NA.cust.bahnhof.se) (Ping timeout: 255 seconds)
2024-03-09 03:01:05 +0100Lord_of_Life(~Lord@user/lord-of-life/x-2819915)
2024-03-09 03:01:13 +0100tri(~tri@ool-18bc2e74.dyn.optonline.net)
2024-03-09 03:03:04 +0100finsternis(~X@23.226.237.192) (Read error: Connection reset by peer)
2024-03-09 03:04:48 +0100benjaminl(~benjaminl@user/benjaminl)
2024-03-09 03:05:58 +0100tri(~tri@ool-18bc2e74.dyn.optonline.net) (Ping timeout: 264 seconds)
2024-03-09 03:07:47 +0100finsternis(~X@23.226.237.192)
2024-03-09 03:24:12 +0100allan453(~allan453@2804:18:40:f10b:58f8:8677:4901:5aa4)
2024-03-09 03:26:25 +0100allan453(~allan453@2804:18:40:f10b:58f8:8677:4901:5aa4) (Client Quit)
2024-03-09 03:26:25 +0100 <Inst> sclv: did you guys do Mao yet?
2024-03-09 03:26:38 +0100 <Inst> I guess it's kiddy stuff compared to Capital.
2024-03-09 03:33:49 +0100peterbecich(~Thunderbi@047-229-123-186.res.spectrum.com)
2024-03-09 03:34:33 +0100 <sclv> yeah its just a fun little political economy and value theory reading group. lotta people that like to make little spreadsheet models of economic reproduction.
2024-03-09 03:44:15 +0100mulk(~mulk@p5b11243f.dip0.t-ipconnect.de) (Ping timeout: 255 seconds)
2024-03-09 03:44:59 +0100otto_s(~user@p4ff27cc1.dip0.t-ipconnect.de) (Ping timeout: 264 seconds)
2024-03-09 03:45:51 +0100mizlan(~mizlan@2607:f010:2a7:1026:cd3d:92f4:f814:59c4)
2024-03-09 03:46:33 +0100otto_s(~user@p4ff27bc5.dip0.t-ipconnect.de)
2024-03-09 03:47:59 +0100mulk(~mulk@p5b2dc01b.dip0.t-ipconnect.de)
2024-03-09 03:55:18 +0100 <Inst> I guess it's the Dengist in me, but you should bother to do neoclassical economics as well; IIRC, Marx wrote Capital to explain why, despite his analysis, capitalism hadn't failed in the 1850s, and leftists in general have been waiting more than 170 years for the collapse of capitalism he envisioned to happen.
2024-03-09 04:01:00 +0100FinnElija(~finn_elij@user/finn-elija/x-0085643) (Remote host closed the connection)
2024-03-09 04:02:43 +0100phma(phma@2001:5b0:215d:d9f8:8a50:43b0:3984:5f61) (Read error: Connection reset by peer)
2024-03-09 04:02:50 +0100FinnElija(~finn_elij@user/finn-elija/x-0085643)
2024-03-09 04:03:35 +0100phma(~phma@host-67-44-208-98.hnremote.net)
2024-03-09 04:05:03 +0100 <bontaq> any moment the contradictions will end it surely
2024-03-09 04:07:52 +0100 <monochrom> https://discourse.haskell.org/t/do-your-taxes-with-haskell/8942/6 is a more interesting and relevant kind of contradiction.
2024-03-09 04:08:25 +0100 <monochrom> Err nevermind, it's underspecified (too many solutions), not contradiction (no solution).
2024-03-09 04:13:59 +0100 <sclv> Inst, that's not my understanding at all but if we're to continue we should probably take it to #haskell-offtopic lol
2024-03-09 04:18:25 +0100peterbecich(~Thunderbi@047-229-123-186.res.spectrum.com) (Ping timeout: 264 seconds)
2024-03-09 04:20:24 +0100 <Inst> yeah k
2024-03-09 04:42:49 +0100terrorjack(~terrorjac@2a01:4f8:c17:87f8::) (Quit: The Lounge - https://thelounge.chat)
2024-03-09 04:45:35 +0100ski(~ski@ext-1-033.eduroam.chalmers.se) (Ping timeout: 264 seconds)
2024-03-09 04:46:15 +0100terrorjack(~terrorjac@2a01:4f8:c17:87f8::)
2024-03-09 04:48:16 +0100mizlan(~mizlan@2607:f010:2a7:1026:cd3d:92f4:f814:59c4) (Ping timeout: 246 seconds)
2024-03-09 04:50:16 +0100hgolden(~hgolden@2603-8000-9d00-3ed1-2678-8497-aa5c-7fa9.res6.spectrum.com)
2024-03-09 04:57:06 +0100ski(~ski@ext-1-033.eduroam.chalmers.se)
2024-03-09 04:59:33 +0100td_(~td@i53870902.versanet.de) (Ping timeout: 256 seconds)
2024-03-09 05:01:24 +0100td_(~td@i5387090F.versanet.de)
2024-03-09 05:24:15 +0100aforemny(~aforemny@i59F516FB.versanet.de) (Ping timeout: 260 seconds)
2024-03-09 05:24:27 +0100aforemny_(~aforemny@2001:9e8:6cc9:7200:b326:eda8:743b:1401)
2024-03-09 05:26:58 +0100ania123(~ania123@94-43-231-47.dsl.utg.ge)
2024-03-09 05:32:54 +0100sp1ff(~user@c-24-21-45-157.hsd1.wa.comcast.net) (Remote host closed the connection)
2024-03-09 05:33:38 +0100peterbecich(~Thunderbi@047-229-123-186.res.spectrum.com)
2024-03-09 05:37:12 +0100slack1256(~slack1256@191.126.144.248)
2024-03-09 05:38:29 +0100 <slack1256> Does the RTS release memory (RSS) back the OS? If so when it?
2024-03-09 05:41:30 +0100 <glguy> slack1256: check out https://gitlab.haskell.org/ghc/ghc/-/merge_requests/5036
2024-03-09 05:41:35 +0100foul_owl(~kerry@157.97.134.168) (Quit: WeeChat 3.8)
2024-03-09 05:42:18 +0100foul_owl(~kerry@157.97.134.168)
2024-03-09 05:43:41 +0100 <int-e> https://gitlab.haskell.org/ghc/ghc/-/blob/master/rts/posix/OSMem.c#L644-650 is relevant too (RSS might not decrease immediately even when the RTS releases memory)
2024-03-09 05:58:47 +0100bontaq(~user@ool-45779c03.dyn.optonline.net) (Ping timeout: 264 seconds)
2024-03-09 05:59:16 +0100igemnace(~ian@user/igemnace)
2024-03-09 05:59:44 +0100 <slack1256> This is great info, thanks glguy, int-e .
2024-03-09 06:06:05 +0100komikat(~akshitkr@218.185.248.66)
2024-03-09 06:06:29 +0100komikat_(~akshitkr@218.185.248.66) (Read error: Connection reset by peer)
2024-03-09 06:30:46 +0100komikat(~akshitkr@218.185.248.66) (Read error: Connection reset by peer)
2024-03-09 06:31:00 +0100komikat(~akshitkr@218.185.248.66)
2024-03-09 06:31:05 +0100machinedgod(~machinedg@d173-183-246-216.abhsia.telus.net) (Ping timeout: 272 seconds)
2024-03-09 06:31:39 +0100peterbecich(~Thunderbi@047-229-123-186.res.spectrum.com) (Quit: peterbecich)
2024-03-09 06:32:07 +0100peterbecich(~Thunderbi@047-229-123-186.res.spectrum.com)
2024-03-09 06:33:22 +0100ec(~ec@gateway/tor-sasl/ec) (Remote host closed the connection)
2024-03-09 06:33:54 +0100ec(~ec@gateway/tor-sasl/ec)
2024-03-09 06:49:22 +0100euphores(~SASL_euph@user/euphores) (Quit: Leaving.)
2024-03-09 06:54:48 +0100slack1256(~slack1256@191.126.144.248) (Remote host closed the connection)
2024-03-09 06:57:38 +0100ski(~ski@ext-1-033.eduroam.chalmers.se) (Ping timeout: 252 seconds)
2024-03-09 07:06:34 +0100komikat_(~akshitkr@218.185.248.66)
2024-03-09 07:06:51 +0100komikat(~akshitkr@218.185.248.66) (Read error: Connection reset by peer)
2024-03-09 07:07:16 +0100euphores(~SASL_euph@user/euphores)
2024-03-09 07:08:00 +0100oo_miguel(~Thunderbi@78-11-181-16.static.ip.netia.com.pl)
2024-03-09 07:17:05 +0100takuan(~takuan@178-116-218-225.access.telenet.be)
2024-03-09 07:18:27 +0100notzmv(~daniel@user/notzmv) (Ping timeout: 255 seconds)
2024-03-09 07:29:17 +0100ski(~ski@ext-1-033.eduroam.chalmers.se)
2024-03-09 07:46:02 +0100 <endojelly> Am I seeing it right that there are combinators to set state, but not to get state, in lens?
2024-03-09 07:46:17 +0100 <endojelly> Not a problem, I can just "gets", just wondering if I missed something.
2024-03-09 07:48:18 +0100Shaeto(~Shaeto@94.25.234.62)
2024-03-09 07:50:26 +0100stiell_(~stiell@gateway/tor-sasl/stiell) (Ping timeout: 260 seconds)
2024-03-09 07:52:05 +0100m1dnight(~christoph@82.146.125.185) (Ping timeout: 240 seconds)
2024-03-09 07:52:22 +0100peterbecich(~Thunderbi@047-229-123-186.res.spectrum.com) (Ping timeout: 246 seconds)
2024-03-09 07:55:41 +0100 <c_wraith> endojelly: are you looking for use?
2024-03-09 07:55:42 +0100 <c_wraith> > runState (do { x <- use _1 ; _2 += x }) (3,4)
2024-03-09 07:55:44 +0100 <lambdabot> ((),(3,7))
2024-03-09 08:05:27 +0100oo_miguel(~Thunderbi@78-11-181-16.static.ip.netia.com.pl) (Ping timeout: 272 seconds)
2024-03-09 08:08:08 +0100hgolden(~hgolden@2603-8000-9d00-3ed1-2678-8497-aa5c-7fa9.res6.spectrum.com) (Remote host closed the connection)
2024-03-09 08:08:13 +0100jau(~user@2a04:4540:7216:6500:aa9c:7a13:5b21:2c7)
2024-03-09 08:12:22 +0100azimut(~azimut@gateway/tor-sasl/azimut) (Ping timeout: 260 seconds)
2024-03-09 08:13:59 +0100acidjnk_new3(~acidjnk@p200300d6e737e708aca1d43a8c2c1f62.dip0.t-ipconnect.de)
2024-03-09 08:17:05 +0100 <Shaeto> hi, can someone check code https://onlinegdb.com/_Pd25PEum and recommend solution how to solve problem in line 3, i don't understand why compiler can't resolve types automatically
2024-03-09 08:19:24 +0100 <c_wraith> Shaeto: it's a precedence issue. It looks like you're hoping it will parse as blah * (sin $ 2 * g), but it parses as (blah * sin) $ (g * 2)
2024-03-09 08:19:51 +0100 <c_wraith> Shaeto: the easiest fix is to throw out the $ operator entirely and use use parens
2024-03-09 08:21:54 +0100dtman34(~dtman34@2601:447:d001:ed50:6848:2021:a4eb:5671) (Ping timeout: 256 seconds)
2024-03-09 08:22:14 +0100 <Shaeto> @c_wraith thank you! okay, so, parens everythere in math :)
2024-03-09 08:22:14 +0100 <lambdabot> Unknown command, try @list
2024-03-09 08:22:52 +0100 <c_wraith> at least until you get comfortable with operator precedence. Parens are nicely unambiguous.
2024-03-09 08:28:11 +0100 <Shaeto> c_wraith: thank you! okay, parens solved problem really don't understand what is bad in the original formula
2024-03-09 08:28:31 +0100 <c_wraith> well, the way it parses, you're trying to multiple a number by a function
2024-03-09 08:32:43 +0100waleee(~waleee@h-176-10-144-38.NA.cust.bahnhof.se)
2024-03-09 08:39:37 +0100rainbyte(~rainbyte@186.22.19.215) (Ping timeout: 268 seconds)
2024-03-09 08:43:46 +0100 <Shaeto> okay, new example with correct precedence but it does not work w/o parens ":t 0.020 * sin $ 2 * (3.0::Double)" and works now ":t 0.020 * (sin $ 2 * (3.0::Double))"
2024-03-09 08:44:23 +0100 <c_wraith> err, $ will always have lower precedence than *
2024-03-09 08:45:13 +0100 <c_wraith> so that's (0.020 * sin) $ (2 * (3 :: Double))
2024-03-09 08:45:16 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
2024-03-09 08:45:48 +0100 <Shaeto> but sin as a functional call have highest precedence so "2 * (3.0::Double)" must be calculated first ?
2024-03-09 08:46:37 +0100 <c_wraith> only if it's syntactically a function call
2024-03-09 08:46:53 +0100 <c_wraith> but since the token after sin is an operator, it's not syntactically a function call
2024-03-09 08:47:08 +0100 <c_wraith> function calls are a series of non-operator tokens in a row
2024-03-09 08:47:37 +0100 <Shaeto> okay, understand now problem is here "$ 2 *"
2024-03-09 08:48:56 +0100zetef(~quassel@95.77.17.251)
2024-03-09 08:49:03 +0100jinsun(~jinsun@user/jinsun) (Ping timeout: 256 seconds)
2024-03-09 08:49:20 +0100 <c_wraith> well, the problem is mixing two different precedences
2024-03-09 08:50:36 +0100 <Shaeto> c_wraith: understand, most books teach me to use . and $ but do not provide table of precedences nor examples :)
2024-03-09 08:51:12 +0100 <c_wraith> You can ask ghci for that
2024-03-09 08:51:24 +0100 <c_wraith> the :info or :i commnad will tell you precedence of operators
2024-03-09 08:52:01 +0100 <c_wraith> To anchor the information, $ has the lowest precedence (0), and . has the highest precedence (9)
2024-03-09 08:53:08 +0100 <mauke> function application has the highestest precedence (10), and record update has the highestestest precedence (11)
2024-03-09 08:53:24 +0100zetef(~quassel@95.77.17.251) (Ping timeout: 255 seconds)
2024-03-09 08:53:29 +0100 <Shaeto> one more question about .
2024-03-09 08:53:36 +0100zetef(~quassel@5.2.182.98)
2024-03-09 08:53:39 +0100 <Shaeto> daysSinceJ2000 :: Year -> MonthOfYear -> DayOfMonth -> Double
2024-03-09 08:53:43 +0100 <endojelly> c_wraith, ah, thanks!
2024-03-09 08:53:50 +0100 <Shaeto> sunEclipticLongitude :: Double -> Double
2024-03-09 08:54:04 +0100 <Shaeto> does not work: sunEclipticLongitudeAtDate = sunEclipticLongitude . daysSinceJ2000
2024-03-09 08:54:35 +0100 <mauke> that's due to the definition of (.)
2024-03-09 08:54:44 +0100 <mauke> (f . g) x = f (g x)
2024-03-09 08:54:51 +0100 <mauke> it only composes functions of one argument
2024-03-09 08:55:21 +0100 <mauke> your code is saying: sunEclipticLongitudeAtDate x = sunEclipticLongitude (daysSinceJ2000 x)
2024-03-09 08:56:05 +0100 <mauke> which is an error because daysSinceJ2000 x is a function (it's will waiting for two more arguments), but sunEclipticLongitude expects a Double
2024-03-09 08:56:13 +0100 <Shaeto> okay, so, it must be : daysSinceJ2000 :: (Year -> MonthOfYear -> DayOfMonth) -> Double
2024-03-09 08:56:15 +0100 <mauke> s/will waiting/still waiting/
2024-03-09 08:56:42 +0100 <mauke> Shaeto: huh?
2024-03-09 08:56:45 +0100 <Shaeto> sorry, i meant daysSinceJ2000 :: (Year, MonthOfYear, DayOfMonth) -> Double
2024-03-09 08:56:56 +0100 <mauke> yes, that would work
2024-03-09 08:57:51 +0100 <Shaeto> okay thank you, continue to calculate the sun position :)
2024-03-09 08:58:32 +0100Domitar(~Domitar@193.198.16.218)
2024-03-09 08:58:58 +0100jinsun(~jinsun@user/jinsun)
2024-03-09 09:00:13 +0100 <mauke> > let { f = fun "f" :: Expr -> Expr } in (f . g) x
2024-03-09 09:00:14 +0100 <lambdabot> f (g x)
2024-03-09 09:00:20 +0100 <mauke> > let { f = fun "f" :: Expr -> Expr } in ((f .) . g) x y
2024-03-09 09:00:22 +0100 <lambdabot> f (g x y)
2024-03-09 09:00:34 +0100 <mauke> > let { f = fun "f" :: Expr -> Expr } in (((f .) .) . g) x y z
2024-03-09 09:00:36 +0100 <lambdabot> f (g x y z)
2024-03-09 09:12:34 +0100harveypwca(~harveypwc@2601:246:c200:2740:15b6:f225:14ff:9821)
2024-03-09 09:27:26 +0100m1dnight(~christoph@82.146.125.185)
2024-03-09 09:29:17 +0100notzmv(~daniel@user/notzmv)
2024-03-09 09:29:38 +0100misterfish(~misterfis@84.53.85.146)
2024-03-09 09:37:44 +0100phma(~phma@host-67-44-208-98.hnremote.net) (Read error: Connection reset by peer)
2024-03-09 09:38:40 +0100phma(phma@2001:5b0:211b:9188:599a:22ec:6887:20f1)
2024-03-09 09:40:20 +0100_ht(~Thunderbi@28-52-174-82.ftth.glasoperator.nl)
2024-03-09 09:41:23 +0100causal(~eric@50.35.85.7)
2024-03-09 09:43:06 +0100euphores(~SASL_euph@user/euphores) (Quit: Leaving.)
2024-03-09 09:56:29 +0100wootehfoot(~wootehfoo@user/wootehfoot)
2024-03-09 09:59:15 +0100peterbecich(~Thunderbi@047-229-123-186.res.spectrum.com)
2024-03-09 10:00:32 +0100euphores(~SASL_euph@user/euphores)
2024-03-09 10:12:29 +0100Domitar(~Domitar@193.198.16.218) (Remote host closed the connection)
2024-03-09 10:14:16 +0100waleee(~waleee@h-176-10-144-38.NA.cust.bahnhof.se) (Ping timeout: 268 seconds)
2024-03-09 10:22:46 +0100dtman34(~dtman34@2601:447:d001:ed50:71b1:9fdc:d135:745b)
2024-03-09 10:34:10 +0100misterfish(~misterfis@84.53.85.146) (Ping timeout: 264 seconds)
2024-03-09 10:37:49 +0100Sgeo(~Sgeo@user/sgeo) (Read error: Connection reset by peer)
2024-03-09 10:38:59 +0100Shaeto(~Shaeto@94.25.234.62) (Quit: WeeChat 4.2.1)
2024-03-09 10:43:11 +0100peterbecich(~Thunderbi@047-229-123-186.res.spectrum.com) (Ping timeout: 264 seconds)
2024-03-09 10:59:04 +0100econo_(uid147250@id-147250.tinside.irccloud.com) (Quit: Connection closed for inactivity)
2024-03-09 11:12:30 +0100Tuplanolla(~Tuplanoll@91-159-69-59.elisa-laajakaista.fi)
2024-03-09 11:13:40 +0100tzh(~tzh@c-73-164-206-160.hsd1.or.comcast.net) (Quit: zzz)
2024-03-09 11:18:16 +0100raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net)
2024-03-09 11:19:13 +0100danza(~francesco@151.43.204.95)
2024-03-09 11:32:42 +0100jinsun(~jinsun@user/jinsun) (Read error: Connection reset by peer)
2024-03-09 11:36:58 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2024-03-09 11:48:19 +0100rvalue(~rvalue@user/rvalue)
2024-03-09 11:49:09 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
2024-03-09 11:57:24 +0100stiell_(~stiell@gateway/tor-sasl/stiell)
2024-03-09 12:10:12 +0100igemnace(~ian@user/igemnace) (Read error: Connection reset by peer)
2024-03-09 12:10:47 +0100Square(~Square@user/square) (Ping timeout: 264 seconds)
2024-03-09 12:13:33 +0100noumenon(~noumenon@113.51-175-156.customer.lyse.net) (Quit: Leaving)
2024-03-09 12:27:50 +0100igemnace(~ian@user/igemnace)
2024-03-09 12:30:18 +0100 <raehik> What do the indexXOffAddr# primops do exactly? They return primitive types, but are somehow not stateful (no State# s tokens), so I can't believe they're reading arbitrary addresses
2024-03-09 12:39:51 +0100harveypwca(~harveypwc@2601:246:c200:2740:15b6:f225:14ff:9821) (Quit: Leaving)
2024-03-09 12:40:26 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2024-03-09 12:47:56 +0100Joao[3](~Joao003@190.108.99.67)
2024-03-09 12:50:34 +0100__monty__(~toonn@user/toonn)
2024-03-09 13:04:30 +0100FinnElija(~finn_elij@user/finn-elija/x-0085643) (Ping timeout: 260 seconds)
2024-03-09 13:06:40 +0100hgolden(~hgolden@2603-8000-9d00-3ed1-2678-8497-aa5c-7fa9.res6.spectrum.com)
2024-03-09 13:06:43 +0100FinnElija(~finn_elij@user/finn-elija/x-0085643)
2024-03-09 13:08:01 +0100ski(~ski@ext-1-033.eduroam.chalmers.se) (Ping timeout: 256 seconds)
2024-03-09 13:11:49 +0100acidjnk_new3(~acidjnk@p200300d6e737e708aca1d43a8c2c1f62.dip0.t-ipconnect.de) (Ping timeout: 264 seconds)
2024-03-09 13:12:13 +0100fmd(~fmd@user/framend)
2024-03-09 13:13:35 +0100phma(phma@2001:5b0:211b:9188:599a:22ec:6887:20f1) (Read error: Connection reset by peer)
2024-03-09 13:14:47 +0100Lycurgus(~georg@user/Lycurgus) (Quit: leaving)
2024-03-09 13:15:37 +0100phma(~phma@host-67-44-208-101.hnremote.net)
2024-03-09 13:20:45 +0100pavonia(~user@user/siracusa) (Quit: Bye!)
2024-03-09 13:31:53 +0100 <tomsmeding> raehik: the ones with the "this is only available on LLVM" warning?
2024-03-09 13:33:24 +0100 <raehik> tomsmeding: yes, though not just those
2024-03-09 13:33:41 +0100 <raehik> I figured it out, they're for reading from immutable memory. see #ghc
2024-03-09 13:34:25 +0100 <raehik> the Haddock docstrings are a bit lacking for some of the primops, specifically the ones reading from immutable Addr# (fairly unintuitive)
2024-03-09 13:35:13 +0100tomsmedingshould just lurk in #ghc instead of leaving each time
2024-03-09 13:36:27 +0100 <raehik> with all my recent messing around i should add it back to my autojoin xd
2024-03-09 13:43:54 +0100 <tomsmeding> mauke: https://hackage.haskell.org/package/composition-1.0.2.2/docs/Data-Composition.html
2024-03-09 13:48:14 +0100 <jackdk> tomsmeding: in a similar vein: https://raw.githubusercontent.com/mxswd/flip-plus/master/Control/FlipPlus.hs
2024-03-09 13:55:38 +0100danza(~francesco@151.43.204.95) (Ping timeout: 252 seconds)
2024-03-09 13:58:05 +0100__monty__(~toonn@user/toonn) (Ping timeout: 240 seconds)
2024-03-09 14:11:33 +0100CiaoSen(~Jura@2a05:5800:2a2:9900:e6b9:7aff:fe80:3d03)
2024-03-09 14:16:29 +0100renpose(~renpose@user/renpose) (Ping timeout: 250 seconds)
2024-03-09 14:20:03 +0100glguy(g@libera/staff/glguy) (Ping timeout: 612 seconds)
2024-03-09 14:48:17 +0100bontaq(~user@ool-45779c03.dyn.optonline.net)
2024-03-09 14:50:05 +0100glguy(g@libera/staff/glguy)
2024-03-09 14:55:26 +0100acidjnk_new3(~acidjnk@p200300d6e737e7747555095b6f843b59.dip0.t-ipconnect.de)
2024-03-09 15:03:00 +0100L29Ah(~L29Ah@wikipedia/L29Ah) (Read error: Connection reset by peer)
2024-03-09 15:05:04 +0100L29Ah(~L29Ah@wikipedia/L29Ah)
2024-03-09 15:07:47 +0100Unicorn_Princess(~Unicorn_P@user/Unicorn-Princess/x-3540542)
2024-03-09 15:07:48 +0100Vajb(~Vajb@n70t65z9ztei3blo55b-1.v6.elisa-mobile.fi) (Ping timeout: 260 seconds)
2024-03-09 15:08:38 +0100 <komikat_> hey, I was reading http://blog.sigfpe.com/2006/08/you-could-have-invented-monads-and.html and I kinda don't get why this is true:
2024-03-09 15:08:45 +0100 <komikat_> Exercise Three
2024-03-09 15:08:46 +0100 <komikat_> Show that lift f * lift g = lift (f.g)
2024-03-09 15:10:10 +0100Vajb(~Vajb@n70t65z9ztei3blo55b-1.v6.elisa-mobile.fi)
2024-03-09 15:11:48 +0100 <ncf> inline definitions and compute?
2024-03-09 15:15:09 +0100 <ncf> spoilers: https://f.monade.li/IQboLk
2024-03-09 15:18:55 +0100 <ncf> or more abstractly, using just the monad law (bind f . unit = f): https://f.monade.li/IwFwLl
2024-03-09 15:21:18 +0100sudden(~cat@user/sudden) (Ping timeout: 255 seconds)
2024-03-09 15:21:58 +0100sudden(~cat@user/sudden)
2024-03-09 15:33:01 +0100rvalue(~rvalue@user/rvalue) (Read error: Connection reset by peer)
2024-03-09 15:33:20 +0100rvalue(~rvalue@user/rvalue)
2024-03-09 15:37:20 +0100 <komikat_> ncf: i'm not sure what the "*" means in this context
2024-03-09 15:38:01 +0100 <mauke> Given a pair of debuggable functions, f' and g', we can now compose them together to make a new debuggable function bind f' . g'. Write this composition as f'*g'.
2024-03-09 15:38:33 +0100 <mauke> or in other words: f' * g' = bind f' . g'
2024-03-09 15:38:48 +0100 <mauke> unfortunately the definitions are kind of hidden throughout the text
2024-03-09 15:39:15 +0100 <komikat_> makes sense
2024-03-09 15:45:51 +0100glguy(g@libera/staff/glguy) (Ping timeout: 612 seconds)
2024-03-09 15:47:36 +0100misterfish(~misterfis@87.215.131.102)
2024-03-09 15:51:26 +0100AlexNoo_(~AlexNoo@5.139.232.124)
2024-03-09 15:53:49 +0100AlexZenon(~alzenon@94.233.241.172) (Ping timeout: 264 seconds)
2024-03-09 15:55:14 +0100AlexNoo(~AlexNoo@94.233.241.172) (Ping timeout: 256 seconds)
2024-03-09 15:55:32 +0100AlexNoo_AlexNoo
2024-03-09 15:57:26 +0100azimut(~azimut@gateway/tor-sasl/azimut)
2024-03-09 16:00:11 +0100__monty__(~toonn@user/toonn)
2024-03-09 16:04:16 +0100AlexZenon(~alzenon@5.139.232.124)
2024-03-09 16:13:35 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
2024-03-09 16:14:10 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Client Quit)
2024-03-09 16:14:54 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
2024-03-09 16:18:07 +0100glguy(g@libera/staff/glguy)
2024-03-09 16:21:54 +0100bitdex(~bitdex@gateway/tor-sasl/bitdex) (Ping timeout: 260 seconds)
2024-03-09 16:22:09 +0100ania123(~ania123@94-43-231-47.dsl.utg.ge) (Ping timeout: 250 seconds)
2024-03-09 16:27:00 +0100noumenon(~noumenon@113.51-175-156.customer.lyse.net)
2024-03-09 16:31:21 +0100glguy(g@libera/staff/glguy) (Ping timeout: 612 seconds)
2024-03-09 16:32:33 +0100o-90(~o-90@gateway/tor-sasl/o-90)
2024-03-09 16:33:42 +0100o-90(~o-90@gateway/tor-sasl/o-90) (Client Quit)
2024-03-09 16:38:00 +0100jau(~user@2a04:4540:7216:6500:aa9c:7a13:5b21:2c7) (Quit: Leaving)
2024-03-09 16:42:25 +0100misterfish(~misterfis@87.215.131.102) (Ping timeout: 264 seconds)
2024-03-09 16:44:46 +0100azimut(~azimut@gateway/tor-sasl/azimut) (Ping timeout: 260 seconds)
2024-03-09 16:45:23 +0100machinedgod(~machinedg@d173-183-246-216.abhsia.telus.net)
2024-03-09 16:52:56 +0100ania123(~ania123@94-43-231-47.dsl.utg.ge)
2024-03-09 16:54:26 +0100glguy(g@libera/staff/glguy)
2024-03-09 17:04:46 +0100Joao[3](~Joao003@190.108.99.67) (Ping timeout: 264 seconds)
2024-03-09 17:05:00 +0100adanwan_(~adanwan@gateway/tor-sasl/adanwan)
2024-03-09 17:05:18 +0100chiselfuse(~chiselfus@user/chiselfuse) (Ping timeout: 260 seconds)
2024-03-09 17:05:18 +0100adanwan(~adanwan@gateway/tor-sasl/adanwan) (Ping timeout: 260 seconds)
2024-03-09 17:05:29 +0100Joao[3](~Joao003@190.108.99.67)
2024-03-09 17:05:46 +0100ChaiTRex(~ChaiTRex@user/chaitrex) (Ping timeout: 260 seconds)
2024-03-09 17:07:43 +0100misterfish(~misterfis@87.215.131.102)
2024-03-09 17:07:45 +0100chiselfuse(~chiselfus@user/chiselfuse)
2024-03-09 17:08:00 +0100ChaiTRex(~ChaiTRex@user/chaitrex)
2024-03-09 17:22:04 +0100 <tomsmeding> jackdk: that is ridiculous, I love it
2024-03-09 17:24:13 +0100agrosant(~agrosant@188.4.221.80.dsl.dyn.forthnet.gr)
2024-03-09 17:27:07 +0100CiaoSen(~Jura@2a05:5800:2a2:9900:e6b9:7aff:fe80:3d03) (Ping timeout: 260 seconds)
2024-03-09 17:34:41 +0100ania123(~ania123@94-43-231-47.dsl.utg.ge) (Quit: Client closed)
2024-03-09 17:39:48 +0100econo_(uid147250@id-147250.tinside.irccloud.com)
2024-03-09 17:46:55 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2024-03-09 17:52:27 +0100fmd(~fmd@user/framend) (Ping timeout: 268 seconds)
2024-03-09 18:05:01 +0100ania123(~ania123@94-43-231-47.dsl.utg.ge)
2024-03-09 18:05:46 +0100fmd(~fmd@2a02-8429-4b52-f901-b9d3-e786-8cb7-0e3d.rev.sfr.net)
2024-03-09 18:10:21 +0100tzh(~tzh@c-73-164-206-160.hsd1.or.comcast.net)
2024-03-09 18:12:45 +0100glguy(g@libera/staff/glguy) (Ping timeout: 612 seconds)
2024-03-09 18:12:50 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
2024-03-09 18:24:05 +0100bitdex(~bitdex@gateway/tor-sasl/bitdex)
2024-03-09 18:25:48 +0100misterfish(~misterfis@87.215.131.102) (Ping timeout: 255 seconds)
2024-03-09 18:28:20 +0100ph88(~ph88@2a02:8109:9e26:c800:61b8:7e22:3ff5:acf1)
2024-03-09 18:30:12 +0100 <ph88> i have this code which type checks https://bpa.st/MZKA i'm looking for ways to make it more concise. For example i wonder if it is possible to map over the error somehow so that i don't have to do runError twice. Does someone have some advises on how to improve this code ?
2024-03-09 18:30:29 +0100 <ph88> This is relevant documentation https://hackage.haskell.org/package/effectful-core-2.3.0.1/docs/Effectful-Error-Static.html
2024-03-09 18:35:43 +0100 <ph88> hmm actually i think i'm already on my way to reduce this code
2024-03-09 18:38:17 +0100azimut(~azimut@gateway/tor-sasl/azimut)
2024-03-09 18:38:41 +0100 <ph88> improvement but still could be clearer https://bpa.st/QYGQ
2024-03-09 18:40:41 +0100rito(~ritog@45.112.243.170)
2024-03-09 18:46:22 +0100destituion(~destituio@2a02:2121:650:17b6:dadb:8eeb:69ad:5745) (Ping timeout: 256 seconds)
2024-03-09 18:46:34 +0100destituion(~destituio@2001:4644:c37:0:6086:64f4:a213:b80d)
2024-03-09 18:50:07 +0100rito(~ritog@45.112.243.170) (Quit: Leaving)
2024-03-09 18:56:12 +0100target_i(~target_i@user/target-i/x-6023099)
2024-03-09 18:57:47 +0100a51(a51@gateway/vpn/protonvpn/a51) (Quit: WeeChat 4.2.1)
2024-03-09 18:58:16 +0100tabemann(~tabemann@2600:1700:7990:24e0:cad5:895e:d141:167b) (Remote host closed the connection)
2024-03-09 18:58:35 +0100tabemann(~tabemann@2600:1700:7990:24e0:bade:358a:4ab3:923a)
2024-03-09 18:59:44 +0100misterfish(~misterfis@84.53.85.146)
2024-03-09 18:59:51 +0100ania123(~ania123@94-43-231-47.dsl.utg.ge) (Quit: Client closed)
2024-03-09 19:07:17 +0100puke(~puke@user/puke) (Ping timeout: 272 seconds)
2024-03-09 19:15:18 +0100causal(~eric@50.35.85.7) (Quit: WeeChat 4.1.1)
2024-03-09 19:15:49 +0100 <Joao[3]> How do I get the last element of a list, while providing a default value if the list is empty?
2024-03-09 19:19:41 +0100jespada_(~jespada@cpc121308-nmal25-2-0-cust15.19-2.cable.virginm.net)
2024-03-09 19:21:41 +0100jespada(~jespada@cpc121308-nmal25-2-0-cust15.19-2.cable.virginm.net) (Ping timeout: 240 seconds)
2024-03-09 19:22:20 +0100rvalue(~rvalue@user/rvalue) (Ping timeout: 252 seconds)
2024-03-09 19:24:30 +0100 <monochrom> if null xs then default else last xs
2024-03-09 19:28:01 +0100rvalue(~rvalue@user/rvalue)
2024-03-09 19:29:48 +0100 <int-e> :t fromMaybe ?default . listToMaybe
2024-03-09 19:29:49 +0100 <lambdabot> (?default::c) => [c] -> c
2024-03-09 19:29:58 +0100michalz(~michalz@185.246.207.222)
2024-03-09 19:32:36 +0100 <ncf> wait what
2024-03-09 19:32:43 +0100 <geekosaur> int-e, that doesn't produce the last item in a non-empty list
2024-03-09 19:32:49 +0100 <Joao[3]> listToMaybe gets the first item
2024-03-09 19:32:54 +0100 <mauke> :t last . (++ [?default])
2024-03-09 19:32:55 +0100 <lambdabot> (?default::c) => [c] -> c
2024-03-09 19:33:05 +0100 <Joao[3]> that just returns default
2024-03-09 19:33:09 +0100 <int-e> geekosaur: ah
2024-03-09 19:33:11 +0100 <ncf> am i having a stroke
2024-03-09 19:33:13 +0100 <ncf> :t ?default
2024-03-09 19:33:14 +0100 <lambdabot> (?default::t) => t
2024-03-09 19:33:22 +0100 <ncf> :t ?what
2024-03-09 19:33:23 +0100 <lambdabot> (?what::t) => t
2024-03-09 19:33:25 +0100 <mauke> :t last . (++ [?renault])
2024-03-09 19:33:26 +0100 <lambdabot> (?renault::c) => [c] -> c
2024-03-09 19:33:43 +0100 <ncf> What Is This
2024-03-09 19:33:53 +0100 <mauke> :t ?what ?is ?this
2024-03-09 19:33:54 +0100 <lambdabot> (?is::t1, ?this::t2, ?what::t1 -> t2 -> t3) => t3
2024-03-09 19:33:54 +0100 <int-e> an implicit argument
2024-03-09 19:33:58 +0100 <Joao[3]> :t fromMaybe ?default . listToMaybe . reverse
2024-03-09 19:33:59 +0100 <lambdabot> (?default::c) => [c] -> c
2024-03-09 19:34:14 +0100 <ncf> > since 6.8.1
2024-03-09 19:34:15 +0100 <lambdabot> error:
2024-03-09 19:34:15 +0100 <lambdabot> Variable not in scope: since :: t0 -> b0 -> c
2024-03-09 19:34:27 +0100 <ncf> i must be from an alternate reality
2024-03-09 19:34:42 +0100 <geekosaur> they're not used very often
2024-03-09 19:34:54 +0100 <Joao[3]> "am i having a stroke" yes you are
2024-03-09 19:35:11 +0100 <geekosaur> https://chrisdone.com/posts/whats-wrong-with-implicitparams/
2024-03-09 19:35:36 +0100 <monochrom> Implicit parameters are how HasCallStack works. >:)
2024-03-09 19:35:39 +0100 <int-e> ncf: Ironically I essentially never use implicit arguments, but lambdabot is one context where they're occasionally useful... it's more pleasent to write ... ?default ... than to write a lambda abstraction \default -> ... default ...
2024-03-09 19:35:41 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2024-03-09 19:35:54 +0100 <Joao[3]> now let's make it point free >:)
2024-03-09 19:36:01 +0100 <mauke> :t last (theList ++ [?theDefault])
2024-03-09 19:36:02 +0100 <lambdabot> error:
2024-03-09 19:36:02 +0100 <lambdabot> • Variable not in scope: theList :: [a]
2024-03-09 19:36:02 +0100 <lambdabot> • Perhaps you meant one of these:
2024-03-09 19:36:05 +0100 <mauke> :t last (?theList ++ [?theDefault])
2024-03-09 19:36:06 +0100 <lambdabot> (?theDefault::a, ?theList::[a]) => a
2024-03-09 19:36:09 +0100 <mauke> there we go
2024-03-09 19:36:20 +0100 <Joao[3]> that just returns the default
2024-03-09 19:36:27 +0100 <mauke> true, I'm dumb
2024-03-09 19:36:37 +0100 <mauke> but at least I got the implicit parameters right!
2024-03-09 19:36:49 +0100 <Joao[3]> @pl \d -> fromMaybe d . listToMaybe . reverse
2024-03-09 19:36:49 +0100 <lambdabot> (. (listToMaybe . reverse)) . fromMaybe
2024-03-09 19:36:58 +0100 <monochrom> foo d xs = if null xs then d else last xs. Now you can use foo in pointfree code.
2024-03-09 19:36:59 +0100 <int-e> it should be last (?default : ?list) instead
2024-03-09 19:37:11 +0100 <int-e> (mauke's code that is)
2024-03-09 19:37:22 +0100 <mauke> thanks
2024-03-09 19:37:38 +0100 <int-e> I guess we've now mixed up head and last once each :)
2024-03-09 19:37:46 +0100 <Joao[3]> also the compiler knows you're stupid and even says it's type `a`
2024-03-09 19:38:05 +0100 <mauke> the type is correct from what I can see
2024-03-09 19:38:15 +0100 <ncf> > ?a + ?b
2024-03-09 19:38:17 +0100 <lambdabot> mueval-core: internal error: PAP object (0x42041f4be8) entered!
2024-03-09 19:38:17 +0100 <lambdabot> (GHC version 8.10.2 for x86_64_unknown_linux)
2024-03-09 19:38:17 +0100 <lambdabot> Please report this as a GHC bug: https://www.haskell.org/ghc/reportabug
2024-03-09 19:38:18 +0100 <int-e> (my type was correct too)
2024-03-09 19:38:20 +0100 <ncf> lol
2024-03-09 19:38:31 +0100 <int-e> ncf: ow
2024-03-09 19:38:33 +0100 <ncf> % ?a + ?b
2024-03-09 19:38:33 +0100 <yahb2> <interactive>:281:1: error: ; • Unbound implicit parameters (?a::Integer, ?b::Integer) ; arising from a use of ‘it’ ; • In the first argument of ‘Yahb2Defs.limitedPrint’, namely ‘it...
2024-03-09 19:38:38 +0100 <ncf> lmao
2024-03-09 19:38:56 +0100 <mauke> @pl \d xs -> last (d : xs)
2024-03-09 19:38:56 +0100 <lambdabot> (last .) . (:)
2024-03-09 19:39:10 +0100 <Joao[3]> -_-
2024-03-09 19:40:28 +0100 <int-e> (It's 99.99% not a ghc bug, mueval uses unsafeCoerce after some manual type-checking that appears to be insufficient in this case)
2024-03-09 19:41:00 +0100 <Joao[3]> > let f = f in f
2024-03-09 19:41:02 +0100 <lambdabot> *Exception: <<loop>>
2024-03-09 19:42:55 +0100 <Joao[3]> > let f _ = f f in f f -- let's see what happens!!!
2024-03-09 19:42:56 +0100 <lambdabot> error:
2024-03-09 19:42:56 +0100 <lambdabot> • Occurs check: cannot construct the infinite type: t1 ~ t1 -> t2
2024-03-09 19:42:57 +0100 <lambdabot> • In the first argument of ‘f’, namely ‘f’
2024-03-09 19:43:09 +0100 <mauke> @v
2024-03-09 19:43:09 +0100 <lambdabot> Just 'J'
2024-03-09 19:44:53 +0100 <int-e> > let f :: a -> b; f = f f in f f
2024-03-09 19:44:55 +0100 <lambdabot> *Exception: <<loop>>
2024-03-09 19:45:15 +0100 <Joao[3]> > let v = show v in v
2024-03-09 19:45:17 +0100 <lambdabot> "\"\\\"\\\\\\\"\\\\\\\\\\\\\\\"\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\"\\\\\\\\\\\\\...
2024-03-09 19:45:23 +0100 <int-e> > let f :: a -> b; f _ = f f in f f
2024-03-09 19:45:29 +0100 <lambdabot> mueval-core: Time limit exceeded
2024-03-09 19:46:37 +0100 <int-e> Joao[3]: an ancient version of lambdabot wrapped the expression in something like `let v = <expr> in show v`, so you could give `show v` as the expression and it would print that fixed point
2024-03-09 19:46:41 +0100 <int-e> > fix show
2024-03-09 19:46:43 +0100 <lambdabot> "\"\\\"\\\\\\\"\\\\\\\\\\\\\\\"\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\"\\\\\\\\\\\\\...
2024-03-09 19:48:00 +0100 <Joao[3]> > show show
2024-03-09 19:48:01 +0100 <lambdabot> "<() -> [Char]>"
2024-03-09 19:48:11 +0100 <Joao[3]> > iterate show show
2024-03-09 19:48:13 +0100 <lambdabot> error:
2024-03-09 19:48:13 +0100 <lambdabot> • Couldn't match type ‘a0 -> String’ with ‘[Char]’
2024-03-09 19:48:13 +0100 <lambdabot> Expected type: String
2024-03-09 19:48:24 +0100 <Joao[3]> > iterate show $ show show
2024-03-09 19:48:25 +0100 <lambdabot> ["<() -> [Char]>","\"<() -> [Char]>\"","\"\\\"<() -> [Char]>\\\"\"","\"\\\"\...
2024-03-09 19:48:55 +0100 <Joao[3]> > (iterate show $ show show)!!100
2024-03-09 19:48:56 +0100 <lambdabot> "\"\\\"\\\\\\\"\\\\\\\\\\\\\\\"\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\"\\\\\\\\\\\\\...
2024-03-09 19:53:21 +0100igemnace(~ian@user/igemnace) (Quit: WeeChat 4.2.1)
2024-03-09 19:54:48 +0100ski(~ski@ext-1-033.eduroam.chalmers.se)
2024-03-09 20:04:55 +0100elnegro(elnegro@r167-57-20-188.dialup.adsl.anteldata.net.uy)
2024-03-09 20:08:23 +0100vgtw(~vgtw@user/vgtw) (Ping timeout: 264 seconds)
2024-03-09 20:10:53 +0100elnegro1(elnegro@r167-57-9-32.dialup.adsl.anteldata.net.uy)
2024-03-09 20:11:41 +0100elnegro(elnegro@r167-57-20-188.dialup.adsl.anteldata.net.uy) (Ping timeout: 240 seconds)
2024-03-09 20:11:51 +0100vgtw(~vgtw@user/vgtw)
2024-03-09 20:12:03 +0100 <tomsmeding> I see you guys have been useful today
2024-03-09 20:12:19 +0100oo_miguel(~Thunderbi@78-11-181-16.static.ip.netia.com.pl)
2024-03-09 20:13:25 +0100 <Joao[3]> > fix id -- :)
2024-03-09 20:13:26 +0100Sgeo(~Sgeo@user/sgeo)
2024-03-09 20:13:27 +0100 <lambdabot> *Exception: <<loop>>
2024-03-09 20:13:46 +0100benjaminl(~benjaminl@user/benjaminl) (Remote host closed the connection)
2024-03-09 20:14:03 +0100benjaminl(~benjaminl@user/benjaminl)
2024-03-09 20:17:31 +0100 <Joao[3]> > fix fix -- >:D
2024-03-09 20:17:32 +0100 <lambdabot> error:
2024-03-09 20:17:33 +0100 <lambdabot> • Occurs check: cannot construct the infinite type: a ~ a -> a
2024-03-09 20:17:33 +0100 <lambdabot> Expected type: a -> a
2024-03-09 20:18:10 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
2024-03-09 20:18:20 +0100hueso_(~root@user/hueso)
2024-03-09 20:18:54 +0100hueso(~root@user/hueso) (Read error: Connection reset by peer)
2024-03-09 20:21:16 +0100hueso_(~root@user/hueso) (Client Quit)
2024-03-09 20:21:31 +0100Lycurgus(~georg@user/Lycurgus)
2024-03-09 20:22:49 +0100hueso(~root@user/hueso)
2024-03-09 20:24:06 +0100 <EvanR> fix error
2024-03-09 20:24:08 +0100 <EvanR> break error
2024-03-09 20:24:09 +0100 <EvanR> break fix
2024-03-09 20:24:31 +0100 <tomsmeding> :t break
2024-03-09 20:24:32 +0100 <lambdabot> (a -> Bool) -> [a] -> ([a], [a])
2024-03-09 20:24:42 +0100 <tomsmeding> :t break fix
2024-03-09 20:24:43 +0100 <lambdabot> [Bool -> Bool] -> ([Bool -> Bool], [Bool -> Bool])
2024-03-09 20:24:48 +0100 <EvanR> lol
2024-03-09 20:25:11 +0100tomsmedingwas expecting "'break' not defined", had forgotten about this function
2024-03-09 20:25:23 +0100 <EvanR> it's a good one
2024-03-09 20:25:49 +0100 <tomsmeding> 'break fix' is not terribly useful though lol
2024-03-09 20:26:00 +0100 <EvanR> it does explain the need to fix fix though
2024-03-09 20:26:07 +0100 <EvanR> unfortunate that it doesn't typecheck
2024-03-09 20:27:05 +0100raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) (Ping timeout: 272 seconds)
2024-03-09 20:27:17 +0100 <tomsmeding> any function f of type Bool -> Bool for which 'fix f' terminates is either 'const True' or 'const False'
2024-03-09 20:28:24 +0100 <EvanR> so there's at least two options
2024-03-09 20:28:30 +0100 <tomsmeding> :t break ($ False)
2024-03-09 20:28:32 +0100 <EvanR> then [Bool -> Bool] can do a lot
2024-03-09 20:28:33 +0100 <lambdabot> [Bool -> Bool] -> ([Bool -> Bool], [Bool -> Bool])
2024-03-09 20:28:44 +0100 <tomsmeding> for all parts of the output where both terminate, this is exactly the same function :')
2024-03-09 20:28:45 +0100 <EvanR> like encode reals
2024-03-09 20:30:04 +0100 <EvanR> const True and const False are well behaved in the sense you can check for them
2024-03-09 20:30:25 +0100 <EvanR> tell them apart
2024-03-09 20:30:53 +0100benjaminl(~benjaminl@user/benjaminl) (Ping timeout: 240 seconds)
2024-03-09 20:31:08 +0100benjaminl(~benjaminl@user/benjaminl)
2024-03-09 20:32:30 +0100peterbecich(~Thunderbi@047-229-123-186.res.spectrum.com)
2024-03-09 20:39:21 +0100 <ncf> fun fact: for any function f :: Bool -> Bool, f (f True) is the existential quantification of f
2024-03-09 20:39:34 +0100 <ncf> that is, f (f True) == True iff ∃ b. f b == True
2024-03-09 20:39:55 +0100ski(~ski@ext-1-033.eduroam.chalmers.se) (Remote host closed the connection)
2024-03-09 20:40:03 +0100ski(~ski@ext-1-033.eduroam.chalmers.se)
2024-03-09 20:45:12 +0100elnegro1(elnegro@r167-57-9-32.dialup.adsl.anteldata.net.uy) ()
2024-03-09 20:46:52 +0100Joao[3](~Joao003@190.108.99.67) (Quit: Bye!)
2024-03-09 20:52:53 +0100ania123(~ania123@94-43-231-47.dsl.utg.ge)
2024-03-09 20:55:37 +0100 <monochrom> That is interesting. :)
2024-03-09 20:58:48 +0100dcoutts(~duncan@cpc69402-oxfd27-2-0-cust903.4-3.cable.virginm.net) (Ping timeout: 255 seconds)
2024-03-09 20:59:42 +0100yangby(~secret@115.192.99.212)
2024-03-09 21:06:30 +0100jm_(~jm@pool-108-45-177-252.washdc.fios.verizon.net)
2024-03-09 21:12:03 +0100fmd(~fmd@2a02-8429-4b52-f901-b9d3-e786-8cb7-0e3d.rev.sfr.net) (Ping timeout: 272 seconds)
2024-03-09 21:12:45 +0100jm_(~jm@pool-108-45-177-252.washdc.fios.verizon.net) (Ping timeout: 255 seconds)
2024-03-09 21:13:23 +0100yangby(~secret@115.192.99.212) (Quit: Go out for a walk and buy a drink.)
2024-03-09 21:21:51 +0100raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net)
2024-03-09 21:22:43 +0100zetef_(~quassel@5.2.182.98)
2024-03-09 21:23:23 +0100zetef_(~quassel@5.2.182.98) (Client Quit)
2024-03-09 21:25:48 +0100zetef(~quassel@5.2.182.98) (Ping timeout: 255 seconds)
2024-03-09 21:29:51 +0100Joao[3](~Joao003@190.108.99.67)
2024-03-09 21:30:46 +0100ski(~ski@ext-1-033.eduroam.chalmers.se) (Ping timeout: 255 seconds)
2024-03-09 21:31:08 +0100Joao[3](~Joao003@190.108.99.67) (Remote host closed the connection)
2024-03-09 21:31:32 +0100Joao[3](~Joao003@190.108.99.67)
2024-03-09 21:32:29 +0100ski(~ski@ext-1-033.eduroam.chalmers.se)
2024-03-09 21:43:17 +0100santiagopim(~user@90.167.66.131) (Ping timeout: 240 seconds)
2024-03-09 21:43:29 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2024-03-09 21:50:29 +0100__monty__(~toonn@user/toonn) (Ping timeout: 240 seconds)
2024-03-09 21:52:35 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
2024-03-09 21:59:40 +0100cole-k(~cole@024-043-123-092.biz.spectrum.com)
2024-03-09 22:00:20 +0100 <cole-k> Is there something like cargo-dist (https://github.com/axodotdev/cargo-dist) for autogenerating a workflow to generate binaries for a release?
2024-03-09 22:01:32 +0100 <cole-k> best i found was this from a reddit thread: https://gist.github.com/aspidites/b27b1326fada1506f8f457286e8df5db
2024-03-09 22:05:51 +0100hgolden(~hgolden@2603-8000-9d00-3ed1-2678-8497-aa5c-7fa9.res6.spectrum.com) (Read error: Connection reset by peer)
2024-03-09 22:06:01 +0100driib(~driib@vmi931078.contaboserver.net) (Quit: The Lounge - https://thelounge.chat)
2024-03-09 22:06:46 +0100hgolden(~hgolden@2603-8000-9d00-3ed1-2678-8497-aa5c-7fa9.res6.spectrum.com)
2024-03-09 22:09:20 +0100_ht(~Thunderbi@28-52-174-82.ftth.glasoperator.nl) (Quit: _ht)
2024-03-09 22:11:10 +0100bgamari_(~bgamari@64.223.200.57)
2024-03-09 22:11:25 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2024-03-09 22:11:35 +0100bgamari(~bgamari@64.223.237.41) (Ping timeout: 272 seconds)
2024-03-09 22:13:36 +0100 <Joao[3]> I have an idea: If you want `tail` to return `[]` if the list is empty, just use `drop 1` instead >:)
2024-03-09 22:14:52 +0100 <haskellbridge> <s​m> indeed, take and drop are sometimes useful that way
2024-03-09 22:15:40 +0100 <haskellbridge> <s​m> otherwise I like to use safe's tailDef
2024-03-09 22:16:01 +0100 <Joao[3]> what is <sm>
2024-03-09 22:16:08 +0100driib(~driib@vmi931078.contaboserver.net)
2024-03-09 22:16:24 +0100 <sm> that is me
2024-03-09 22:16:33 +0100misterfish(~misterfis@84.53.85.146) (Ping timeout: 256 seconds)
2024-03-09 22:16:56 +0100 <Joao[3]> oh... why are they pinging you then if they're talking to me
2024-03-09 22:17:24 +0100 <sm> it's because I was talking from matrix. A bridge copied those messages here.
2024-03-09 22:17:36 +0100 <Joao[3]> oh
2024-03-09 22:17:49 +0100 <sm> the formatting is a bit weird.
2024-03-09 22:18:24 +0100 <sm> why is it always shown as <s_m> here, geekosaur ?
2024-03-09 22:20:22 +0100cole-k(~cole@024-043-123-092.biz.spectrum.com) (Ping timeout: 264 seconds)
2024-03-09 22:20:23 +0100 <geekosaur> because it inserts a zero-width space to try to prevent pinging
2024-03-09 22:20:39 +0100 <sm> aha
2024-03-09 22:20:46 +0100cole-k(~cole@024-043-123-092.biz.spectrum.com)
2024-03-09 22:21:16 +0100 <tomsmeding> (weechat doesn't show the ZWSP)
2024-03-09 22:21:27 +0100smis using erc
2024-03-09 22:21:36 +0100tomsmedinguses vim
2024-03-09 22:21:56 +0100 <ski> sm : no. it's shown as "<s​m>", not as "<s_m>", with a ZWSP (U+200B ZERO WIDTH SPACE) after the "s"
2024-03-09 22:22:13 +0100 <geekosaur> depends on the client
2024-03-09 22:22:21 +0100 <Joao[3]> geekosaur: true
2024-03-09 22:22:25 +0100 <geekosaur> we already know of a few which do weird things when they see ZWSP
2024-03-09 22:22:34 +0100 <Joao[3]> i use hexchat and it doesn't show the ZWSP
2024-03-09 22:22:39 +0100ski's suggested it not insert that, at least if there's no nick with that name on the IRC side, in the channel
2024-03-09 22:22:42 +0100 <tomsmeding> honestly it's not too surprising that a client would insert a replacement character when it finds non-ascii characters in a nick
2024-03-09 22:23:00 +0100Shaeto(~Shaeto@94.25.234.62)
2024-03-09 22:23:04 +0100 <geekosaur> sadly there's not a lot I can do unless I want to take over matterbridge
2024-03-09 22:23:05 +0100 <ski> (to me, it displays the ZWSP as a dotted box around the "s" (first character of nickname))
2024-03-09 22:23:14 +0100 <tomsmeding> (there is, in this case, though)
2024-03-09 22:23:29 +0100 <geekosaur> it doesn't track who's on either side of the bridge, for example
2024-03-09 22:24:09 +0100 <ski> (i'd rather have it not do that at all, tbh)
2024-03-09 22:24:13 +0100 <tomsmeding> keeping a nicklist on the irc side is little work, but I don't know how much of a refactor that would entail
2024-03-09 22:24:50 +0100 <Shaeto> hi, how to get UniversalTime from UTCTime ?
2024-03-09 22:25:01 +0100Joao[3](~Joao003@190.108.99.67) (Quit: Bye!)
2024-03-09 22:25:21 +0100jargon(~jargon@154.sub-174-205-226.myvzw.com) (Read error: Connection reset by peer)
2024-03-09 22:26:09 +0100 <tomsmeding> Shaeto: what do you need UniversalTime for? Are you sure you don't want UTCTime?
2024-03-09 22:26:11 +0100 <ski> (as it is, when i want to respond to someone, over the bridge, i have to manually remove the ZWSP, after copying the nickname)
2024-03-09 22:26:44 +0100 <Shaeto> tomsmeding: i calculate the Sun coordinates, i need days + fractional part (time) :)
2024-03-09 22:27:03 +0100 <tomsmeding> you'll need a specialised library for that :p
2024-03-09 22:27:17 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
2024-03-09 22:27:54 +0100 <geekosaur> tomsmeding, it's written in Go. I'd rather program in Python 😕
2024-03-09 22:28:26 +0100 <int-e> Would ^O (mIRC, reset color) instead of ZWSP work better? I guess clients might filter that before checking for nickname matches.
2024-03-09 22:29:17 +0100 <Shaeto> i see what UniversalTime has instance of ParseTime mb i can parse some string to UniversalTime ? but i don't understand how
2024-03-09 22:29:38 +0100 <tomsmeding> that would be to parse a string representation of the date to a date value
2024-03-09 22:29:48 +0100 <tomsmeding> that doesn't help you for _computing_ that date value from a different unit
2024-03-09 22:29:59 +0100 <sm> maybe the https://wiki.haskell.org/Time cheatsheet helps a bit
2024-03-09 22:30:13 +0100 <tomsmeding> I know very little about this but looking at this you'll need some kind of database of time offsets https://www.nist.gov/pml/time-and-frequency-division/time-realization/leap-seconds
2024-03-09 22:30:21 +0100 <tomsmeding> if you're interested in this level of precision
2024-03-09 22:31:04 +0100 <tomsmeding> sm: that link confirms what I found: "Converting between UniversalTime and AbsoluteTime would require a database build upon astronomical observations. No such conversion utilities are provided. " :p
2024-03-09 22:31:57 +0100 <Shaeto> okay thank you think i can leave w/o leap second... will calculate fractional part of dat from seconds
2024-03-09 22:32:05 +0100 <sm> this is an excellent page. Haskell wiki doing the job yet again
2024-03-09 22:33:02 +0100 <tomsmeding> in fact, it would be helpful to have that text in the haddocks for UniversalTime
2024-03-09 22:33:21 +0100 <tomsmeding> the current text is... unhelpful if you don't already know these details
2024-03-09 22:33:47 +0100 <sm> (the diagram implies you can go UTCTime -> LocalTime -> UniversalTime though)
2024-03-09 22:33:52 +0100 <ania123> ski: hi
2024-03-09 22:34:13 +0100 <sm> ooh. "Updates? Ask EvanR on #haskell."
2024-03-09 22:34:34 +0100 <tomsmeding> that sounds wrong
2024-03-09 22:34:42 +0100cole-k(~cole@024-043-123-092.biz.spectrum.com) (Remote host closed the connection)
2024-03-09 22:35:03 +0100 <sm> the Longitude arrow should be red maybe
2024-03-09 22:35:17 +0100 <tomsmeding> no it should be black but you need more info than just that
2024-03-09 22:35:24 +0100 <sm> I see
2024-03-09 22:35:27 +0100 <tomsmeding> it's "Gain info" :p
2024-03-09 22:35:30 +0100 <tomsmeding> by magic
2024-03-09 22:35:42 +0100 <sm> yes, "magic happens"
2024-03-09 22:36:02 +0100 <sm> you consult the stars and intuit their meaning
2024-03-09 22:36:50 +0100 <tomsmeding> summarising my nist link: TAI is seconds since an epoch, UT1 is astronomical time, UTC is TAI + an integer number of seconds so that it's close to UT1
2024-03-09 22:37:00 +0100 <tomsmeding> that integer number of seconds is the leap seconds between epoch and now
2024-03-09 22:37:17 +0100 <tomsmeding> so UTCTime ---(LeapSecondTable)--> TAI
2024-03-09 22:37:26 +0100 <tomsmeding> which is AbsoluteTime, which is correct in the diagram
2024-03-09 22:38:16 +0100 <tomsmeding> but I hink it would need to be AbsoluteTime(maybe UTCTime?) ---(AstronomicalObservationsTable)--> UT1=UniversalTime
2024-03-09 22:38:32 +0100 <EvanR> universal time is literally localtime with a longitude
2024-03-09 22:38:34 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2024-03-09 22:38:51 +0100 <tomsmeding> a ModJulianDate?
2024-03-09 22:39:07 +0100 <tomsmeding> is your "universal time" the UT1 from wikipedia / https://www.nist.gov/pml/time-and-frequency-division/time-realization/leap-seconds ?
2024-03-09 22:39:35 +0100 <tomsmeding> owait
2024-03-09 22:39:52 +0100 <tomsmeding> do you mean a longitude offset, as in an Earth rotation angle?
2024-03-09 22:39:55 +0100 <geekosaur> "does annybody really know what time it is?"
2024-03-09 22:40:05 +0100 <tomsmeding> close enough to be in time for meetings
2024-03-09 22:40:20 +0100 <EvanR> ok, it's not literally LocalTime + longitude
2024-03-09 22:41:08 +0100 <tomsmeding> there's got to be a database of offsets somewhere in the process of computing a UniversalTim
2024-03-09 22:41:10 +0100 <tomsmeding> e
2024-03-09 22:41:11 +0100 <EvanR> it's calendar day plus a fraction
2024-03-09 22:41:36 +0100 <EvanR> you can convert LocalTime to a UniversalTime by giving the longitude
2024-03-09 22:41:39 +0100ski(~ski@ext-1-033.eduroam.chalmers.se) (Ping timeout: 260 seconds)
2024-03-09 22:41:51 +0100 <tomsmeding> EvanR: is that UT1?
2024-03-09 22:41:57 +0100 <tomsmeding> or some other thing called "universal time"
2024-03-09 22:42:26 +0100 <EvanR> UniversalTime is a type in the time library whose documentation says "used to represent UT1"
2024-03-09 22:42:32 +0100 <tomsmeding> right
2024-03-09 22:42:43 +0100ski(~ski@ext-1-033.eduroam.chalmers.se)
2024-03-09 22:42:53 +0100Joao[3](~Joao003@190.108.99.67)
2024-03-09 22:42:57 +0100 <tomsmeding> but NIST claims that UT1 differs from UTC by on the order of 50ms
2024-03-09 22:43:08 +0100 <tomsmeding> (at least somewhere in 2023)
2024-03-09 22:43:16 +0100 <EvanR> I'm not surprised by that
2024-03-09 22:43:29 +0100 <EvanR> LocalTime and UniversalTime have nothing to do with UTC
2024-03-09 22:43:41 +0100 <tomsmeding> well LocalTime is UTC + time zone, right?
2024-03-09 22:43:53 +0100 <tomsmeding> UT1 has nothing to do with time zones as far as I can tell
2024-03-09 22:44:05 +0100 <tomsmeding> so I don't see how LocalTime gets you closer to UT1 than UTC does
2024-03-09 22:44:27 +0100 <EvanR> UTC is its own thing, you can express it using a LocalTime with the understanding you're talking about UTC's timezone
2024-03-09 22:44:37 +0100 <tomsmeding> I guess "LocalTime is UTC + geographical/geopolitical info" is more accurate
2024-03-09 22:44:41 +0100 <EvanR> the TimeZone type is basically a shift in time, not much of a time zone (series)
2024-03-09 22:45:04 +0100 <EvanR> LocalTime is very dumb it is just YY-MM-DD HH:MM:SS:etc
2024-03-09 22:45:14 +0100 <EvanR> with no other information so you can interpret it how you want
2024-03-09 22:45:29 +0100 <EvanR> all these types are like islands of ontology
2024-03-09 22:45:43 +0100 <tomsmeding> right
2024-03-09 22:46:11 +0100 <tomsmeding> I was interpreting "LocalTime" as "the time in my current timezone" which is inaccurate
2024-03-09 22:46:18 +0100 <EvanR> it could be!
2024-03-09 22:46:23 +0100 <tomsmeding> yeah true
2024-03-09 22:46:30 +0100 <tomsmeding> but that's not the relevant interpretation in this conversation
2024-03-09 22:46:37 +0100 <EvanR> I missed the beginning
2024-03-09 22:46:52 +0100 <tomsmeding> the beginning was someone asking "how do I convert from UTCTime to UniversalTime"
2024-03-09 22:47:08 +0100 <Shaeto> if forget about conversion .. how to parse UT1 from string ?
2024-03-09 22:47:32 +0100 <tomsmeding> EvanR: and then the diagram on haskell wiki suggests that you can suffice with a TimeZone and a Longitude, which I found doubtful
2024-03-09 22:47:49 +0100 <EvanR> let me try to find the function that that Longitude arrow is implying
2024-03-09 22:48:02 +0100 <EvanR> localTimeToUT1 :: Rational -> LocalTime -> UniversalTime
2024-03-09 22:48:26 +0100 <geekosaur> ain't nothing rational about that 😛
2024-03-09 22:48:32 +0100 <EvanR> there's another straightforward function which renders UTCTime as a LocalTime in the UTC time zone
2024-03-09 22:48:45 +0100 <EvanR> so basically you have to pick the longitude
2024-03-09 22:48:54 +0100 <EvanR> "Get the UT1 time of a local time on a particular meridian (in degrees, positive is East)."
2024-03-09 22:49:28 +0100 <tomsmeding> _what_ hackage quick search is useless
2024-03-09 22:49:40 +0100 <tomsmeding> I was expecting to get all signatures involving UniversalTime by searching for "UniversalTime"
2024-03-09 22:49:42 +0100tomsmedingsad
2024-03-09 22:50:06 +0100dcoutts(~duncan@cpc69402-oxfd27-2-0-cust903.4-3.cable.virginm.net)
2024-03-09 22:50:36 +0100sudden(~cat@user/sudden) (Ping timeout: 256 seconds)
2024-03-09 22:51:03 +0100sudden(~cat@user/sudden)
2024-03-09 22:51:34 +0100 <EvanR> this is more complicated than it needs to be, since you have the time in UTC, you just use zero as the Rational
2024-03-09 22:51:45 +0100 <EvanR> since the time you had was in UTC
2024-03-09 22:51:57 +0100 <tomsmeding> my understanding is that UT1 is a global standard and is not dependent on location :p
2024-03-09 22:51:58 +0100 <EvanR> though, you say, it differs by 50ms for some reason
2024-03-09 22:52:26 +0100 <tomsmeding> it differs by a small <1s fraction because astronomical stuff is not as digital as we'd like
2024-03-09 22:52:28 +0100 <tomsmeding> UT1 != UTC
2024-03-09 22:52:28 +0100 <EvanR> the universal time doesn't depend on location, but that function takes LocalTime and can't know where that time came frmo
2024-03-09 22:52:45 +0100 <EvanR> the Rational is telling the function where the LocalTime is reported at
2024-03-09 22:52:52 +0100 <EvanR> in this case, zero degrees east
2024-03-09 22:52:55 +0100 <Joao[3]> why are we talking about time zones in a channel about haskell
2024-03-09 22:53:18 +0100 <EvanR> because haskell somehow ended up with one of the most correctish time libraries unfortunately for programmers
2024-03-09 22:53:23 +0100agrosant(~agrosant@188.4.221.80.dsl.dyn.forthnet.gr) (Ping timeout: 264 seconds)
2024-03-09 22:53:30 +0100 <Joao[3]> :/
2024-03-09 22:53:48 +0100 <tomsmeding> localTimeToUT1 sounds to me like if I start in Greenwich and move east very quickly (so that I can move around the world in a few minutes, say), UT1 will first decrease until I cross the time zone border into UTC+1 at which point it will jump ahead by an hour, after which it will decrease again, etc.
2024-03-09 22:53:50 +0100 <EvanR> you can identify subcomponents of the time package which other languages used as their basis, or have messed up
2024-03-09 22:53:56 +0100 <tomsmeding> that does _not_ sound proper :p
2024-03-09 22:54:57 +0100 <EvanR> tomsmeding, the argument pertains to the location you looked at the clock so it can get back to zero degrees, which is where the mod julian date is measured at
2024-03-09 22:55:03 +0100 <tomsmeding> in my few minutes of travelling around the world, UT1 should steadily increase by about the same number of minutes
2024-03-09 22:55:04 +0100komikat(~akshitkr@218.185.248.66)
2024-03-09 22:55:32 +0100 <EvanR> e.g. you have 90 degrees west and a local time, you can get the universal time now
2024-03-09 22:55:34 +0100 <tomsmeding> is that LocalTime argument to localTimeToUT1 supposed to be the geopolitical local time at that place on Earth?
2024-03-09 22:55:43 +0100 <EvanR> LocalTime is localtime yes
2024-03-09 22:55:47 +0100 <EvanR> just some time
2024-03-09 22:55:50 +0100 <EvanR> and date
2024-03-09 22:55:55 +0100 <tomsmeding> but then... my thought experiment?
2024-03-09 22:56:01 +0100 <tomsmeding> where does my reasoning go wrong
2024-03-09 22:56:36 +0100 <EvanR> you go west and your Rational decreases and your LocalTime increases, theoretically?
2024-03-09 22:56:57 +0100 <EvanR> we I got east and west backwards
2024-03-09 22:57:01 +0100 <EvanR> er
2024-03-09 22:57:07 +0100 <tomsmeding> yeah my point is not so much + vs - :p
2024-03-09 22:57:43 +0100 <EvanR> if you move across the globe at the same time, presumably your LocalTime changes as much as your longitude
2024-03-09 22:57:57 +0100 <EvanR> they should cancel out in localTimeToUT1
2024-03-09 22:58:02 +0100 <tomsmeding> it's that in my thought experiment, according to that function, in my travel around the world UT1 would apparently move non-monotonically in a sawtooth wave, where the speed of change in each diagonal part is proportional to my speed of motion
2024-03-09 22:58:14 +0100 <tomsmeding> where UT1 surely does not depend on how fast I'm moving around the Earth?!
2024-03-09 22:58:15 +0100 <EvanR> it shouldn't move at all right
2024-03-09 22:58:22 +0100 <EvanR> since it's the same everywhere
2024-03-09 22:58:27 +0100komikat_(~akshitkr@218.185.248.66) (Ping timeout: 272 seconds)
2024-03-09 22:58:27 +0100 <tomsmeding> yes
2024-03-09 22:58:31 +0100 <EvanR> it's the mod julian date
2024-03-09 22:58:35 +0100 <EvanR> in the definition
2024-03-09 22:58:42 +0100 <tomsmeding> but my Longitude is changing proportional to my speed of motion, and my LocalTime is changing... erratically
2024-03-09 22:59:02 +0100 <tomsmeding> their difference is erratic, surely not smooth and slow like UT1 is supposed to be
2024-03-09 22:59:35 +0100 <EvanR> yeah, so this function would only really work if you got LocalTime out of the reverse conversion
2024-03-09 22:59:45 +0100 <EvanR> ut1ToLocalTime :: Rational -> UniversalTime -> LocalTime
2024-03-09 22:59:58 +0100 <EvanR> the local time coming out of there has nothing to do with anything
2024-03-09 23:00:01 +0100 <tomsmeding> right
2024-03-09 23:00:08 +0100 <EvanR> sorted xD
2024-03-09 23:00:08 +0100 <tomsmeding> okay I'm with you there
2024-03-09 23:00:43 +0100 <tomsmeding> but then, like, ut1ToLocalTime gives a LocalTime that doesn't mean anything standard (though it does mean something well-defined -- UT1 + (some fraction) * longitude)
2024-03-09 23:00:53 +0100 <EvanR> anyway, since the Rational will equal zero, none of that matters
2024-03-09 23:01:02 +0100 <tomsmeding> and localTimeToUT1 needs a LocalTime according to that undocumented standard
2024-03-09 23:01:12 +0100 <tomsmeding> which you can only get if you had a UniversalTime in the first place
2024-03-09 23:01:20 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl)
2024-03-09 23:01:26 +0100 <tomsmeding> so you still can't compute a UniversalTime from anything else using the time library XD
2024-03-09 23:01:56 +0100 <tomsmeding> so, in my opinion, the LocalTime ---Longitude--> UniversalTime arrow is still wrong, or at best misleading
2024-03-09 23:02:14 +0100 <tomsmeding> yes, you can get something of type UniversalTime by putting in something of type LocalTime and a longitude value
2024-03-09 23:02:32 +0100 <tomsmeding> but that thing of type LocalTime is not anything that anyone has, normally
2024-03-09 23:02:46 +0100 <tomsmeding> it's not what you get by following the arrows from other places in that diagram
2024-03-09 23:02:53 +0100 <EvanR> if they have UTCTime it seems obvious what to do now
2024-03-09 23:03:00 +0100 <tomsmeding> no
2024-03-09 23:03:05 +0100noumenon(~noumenon@113.51-175-156.customer.lyse.net) (Quit: Leaving)
2024-03-09 23:03:07 +0100 <tomsmeding> because then they'll miss that variable ~50ms offset
2024-03-09 23:03:20 +0100 <tomsmeding> and if you don't care about that offset, you should be using UTCTime, not UniversalTime
2024-03-09 23:03:29 +0100 <tomsmeding> the whole _point_ of UT1 is that it has that ~50ms offset
2024-03-09 23:04:03 +0100 <EvanR> make sure to adjust the answer by 50ms xD
2024-03-09 23:04:16 +0100 <tomsmeding> where that 50ms depends on the date and time lol
2024-03-09 23:04:26 +0100 <tomsmeding> so you need a table derived from astronomical observations
2024-03-09 23:04:33 +0100a51(a51@gateway/vpn/protonvpn/a51)
2024-03-09 23:04:36 +0100 <tomsmeding> that NIST page I linked gives some entries
2024-03-09 23:05:01 +0100 <EvanR> I wonder if the need for UT1 was real
2024-03-09 23:05:05 +0100 <tomsmeding> I really appreciate that the 'time' library separates out all of these concepts
2024-03-09 23:05:19 +0100 <tomsmeding> I just think that some of the docs around UniversalTime can be significantly improved
2024-03-09 23:05:23 +0100 <EvanR> yes
2024-03-09 23:05:23 +0100 <tomsmeding> EvanR: it probably was not lol
2024-03-09 23:05:31 +0100 <geekosaur> astronomers use it
2024-03-09 23:05:35 +0100 <tomsmeding> for sure
2024-03-09 23:05:37 +0100 <geekosaur> I don't think anyone else cares
2024-03-09 23:05:39 +0100 <Shaeto> https://play.haskell.org/saved/oVpaI9xO
2024-03-09 23:05:40 +0100 <tomsmeding> it exists for a reason
2024-03-09 23:05:51 +0100 <EvanR> UniversalTime can be used to represent UT1, but the conversions to the other types need work it seems
2024-03-09 23:05:59 +0100 <Shaeto> why package doc says "The Modified Julian Day is a standard count of days, with zero being the day 1858-11-17."
2024-03-09 23:06:11 +0100 <tomsmeding> there _are_ no conversions to the other types without a regularly updated table of astronomical observations
2024-03-09 23:06:19 +0100 <tomsmeding> any conversion without such a table is misleading
2024-03-09 23:06:21 +0100 <EvanR> MJD is just JD shifted over to make that the zero day
2024-03-09 23:06:22 +0100 <Shaeto> but returns 60378 days for "today"
2024-03-09 23:06:31 +0100 <EvanR> it's an integer
2024-03-09 23:06:39 +0100 <EvanR> the count of days
2024-03-09 23:06:47 +0100 <EvanR> don't ask what a day is
2024-03-09 23:07:06 +0100 <tomsmeding> Shaeto: the Modified Julian Day for 1858-11-17 (why on earth that day, but whatever) is 0
2024-03-09 23:07:13 +0100 <tomsmeding> 1858-11-18 is 1, etc.
2024-03-09 23:07:17 +0100 <Joao[3]> why???
2024-03-09 23:07:17 +0100 <Shaeto> ahh sorry /365 :)
2024-03-09 23:07:18 +0100 <geekosaur> and really don't ask about days that went missing when various countries switched to Gregorian
2024-03-09 23:07:24 +0100 <tomsmeding> today is apparently 60378
2024-03-09 23:07:26 +0100 <EvanR> lol
2024-03-09 23:07:42 +0100 <EvanR> those days didn't go missing in the JD, MJD system
2024-03-09 23:07:48 +0100 <Joao[3]> Shaeto: /365.2425
2024-03-09 23:07:49 +0100 <tomsmeding> > 60378/365.2425
2024-03-09 23:07:51 +0100 <lambdabot> 165.30934926795211
2024-03-09 23:07:55 +0100 <EvanR> and the day of the week remained the same miraculously!
2024-03-09 23:07:58 +0100 <tomsmeding> 2024-165
2024-03-09 23:07:59 +0100 <geekosaur> right but they matter if you try to convert from/to YMD
2024-03-09 23:08:01 +0100 <tomsmeding> > 2024-165
2024-03-09 23:08:03 +0100 <lambdabot> 1859
2024-03-09 23:08:06 +0100 <tomsmeding> checks out
2024-03-09 23:08:32 +0100 <EvanR> yes YMD means you're now doing calendrical gymnastics
2024-03-09 23:09:07 +0100 <Joao[3]> > 2024.1883-165.30934926795211
2024-03-09 23:09:08 +0100 <lambdabot> 1858.878950732048
2024-03-09 23:09:55 +0100Joao[3](~Joao003@190.108.99.67) (Quit: Bye!)
2024-03-09 23:10:14 +0100 <EvanR> tomsmeding, at least, going from UniversalTime to a LocalTime at some longitude makes sense. Though it won't correspond to anyone's actual clock, not that LocalTime itself has any expectations
2024-03-09 23:10:46 +0100 <EvanR> what is shows on my microwave could be represented as LocalTime and means about as much
2024-03-09 23:10:52 +0100 <EvanR> no my microwave doesn't have internet
2024-03-09 23:11:11 +0100 <geekosaur> mine likes to run fast 😛
2024-03-09 23:11:28 +0100michalz(~michalz@185.246.207.222) (Quit: ZNC 1.8.2 - https://znc.in)
2024-03-09 23:16:28 +0100 <tomsmeding> EvanR: Sure, UniversalTime + Longitude -> LocalTime makes some sense, but then that function (ut1ToLocalTime) should have a big disclaimer that this LocalTime is not what every programmer ever will expect when seeing the name "LocalTime"
2024-03-09 23:16:59 +0100 <tomsmeding> _especially_ because LocalTime does not contain any information describing what it's local to
2024-03-09 23:17:15 +0100 <EvanR> LocalTime does have the same structure as DateTime or whatever in many languages, where I have no idea what programmers think that means
2024-03-09 23:17:23 +0100 <tomsmeding> for sure
2024-03-09 23:17:28 +0100 <tomsmeding> again, I appreciate the separation
2024-03-09 23:17:39 +0100 <EvanR> except for a time zone code or something that usually doesn't help
2024-03-09 23:18:03 +0100 <tomsmeding> and I now see that there _is_ a note about UT1 in the haddocks for LocalTime, but the 'time' documentation could make more use of its good separation of definitions and explain what it's doing :p
2024-03-09 23:18:51 +0100 <EvanR> I had a hard time finding the UniversalTime docs
2024-03-09 23:18:58 +0100 <EvanR> such as they are
2024-03-09 23:18:59 +0100 <tomsmeding> @hackage time
2024-03-09 23:18:59 +0100 <lambdabot> https://hackage.haskell.org/package/time
2024-03-09 23:19:05 +0100 <tomsmeding> <s> UniversalTime <enter>
2024-03-09 23:19:19 +0100 <EvanR> yeah I had that but it's not in the top level module listings
2024-03-09 23:19:20 +0100 <tomsmeding> haddocks quick search does work that far :p
2024-03-09 23:19:28 +0100 <tomsmeding> try the 's' key on your keyboard
2024-03-09 23:19:41 +0100 <tomsmeding> or the 'Quick Jump' link on the page, does the same thing
2024-03-09 23:20:54 +0100 <Shaeto> my current dirty replacement for UT is fromIntegral (diffDays (utctDay now) (fromGregorian 2000 1 1)) + (utctDayTime now) / 86401.0
2024-03-09 23:22:10 +0100 <EvanR> what dark incantation is that
2024-03-09 23:22:19 +0100 <tomsmeding> that would be since 2000-01-01, not since the actual UT1 epoch
2024-03-09 23:22:40 +0100 <EvanR> dividing by 86401 wtf xD
2024-03-09 23:22:52 +0100 <tomsmeding> that's just "number of seconds, as measured by UTC including leap second magic, since 2000-01-01 00:00:00"
2024-03-09 23:22:58 +0100 <tomsmeding> and also yes where does that 1 come from lol
2024-03-09 23:23:12 +0100 <tomsmeding> > 24*60*60
2024-03-09 23:23:13 +0100 <lambdabot> 86400
2024-03-09 23:23:16 +0100 <Shaeto> because of utctDayTime doc :)
2024-03-09 23:23:25 +0100 <EvanR> no...
2024-03-09 23:23:34 +0100 <tomsmeding> > Note that if a day has a leap second added to it, it will have 86401 seconds.
2024-03-09 23:23:39 +0100 <tomsmeding> if not, it will have 86400 seconds
2024-03-09 23:23:55 +0100 <tomsmeding> whether it has depends on some table you'll have to load from somewhere, it's unpredictable
2024-03-09 23:24:01 +0100 <tomsmeding> this is the whole debacle we've been talking about :p
2024-03-09 23:24:26 +0100 <tomsmeding> dividing by 86400 will give you something that's very close to UT1
2024-03-09 23:24:37 +0100 <tomsmeding> but not quite exactly the same, it will differ by up to 0.9 seconds
2024-03-09 23:24:42 +0100 <tomsmeding> in the worst case
2024-03-09 23:24:51 +0100takuan(~takuan@178-116-218-225.access.telenet.be) (Remote host closed the connection)
2024-03-09 23:24:58 +0100 <EvanR> 86401 would assume there's a leap second every day
2024-03-09 23:25:03 +0100 <EvanR> which there isn't
2024-03-09 23:25:26 +0100ski(~ski@ext-1-033.eduroam.chalmers.se) (Ping timeout: 252 seconds)
2024-03-09 23:25:31 +0100 <tomsmeding> you don't know whether I make a leap for a second every day
2024-03-09 23:31:08 +0100ski(~ski@ext-1-033.eduroam.chalmers.se)
2024-03-09 23:31:33 +0100tromp(~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…)
2024-03-09 23:52:26 +0100wootehfoot(~wootehfoo@user/wootehfoot) (Read error: Connection reset by peer)
2024-03-09 23:56:33 +0100pavonia(~user@user/siracusa)
2024-03-09 23:58:25 +0100Shaeto(~Shaeto@94.25.234.62) (Quit: WeeChat 4.2.1)