Home liberachat/#haskell: Logs Calendar

Logs: liberachat/#haskell

←Prev  Next→ 1,798,587 events total
2026-02-19 20:06:51 califax_ is now known as califax
2026-02-19 20:06:56 <tomsmeding> it works by setting the -interactive-print option in ghci so that values are printed with a custom function rather than Prelude.print
2026-02-19 20:07:08 <tomsmeding> you can trivially break it by doing
2026-02-19 20:07:08 <gentauro> % [[1..]]
2026-02-19 20:07:08 <yahb2> [[1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,...
2026-02-19 20:07:12 Googulator joins (~Googulato@2a01-036d-0106-499d-1c5a-0e4b-5795-d7e3.pool6.digikabel.hu)
2026-02-19 20:07:13 <tomsmeding> % print [1..]
2026-02-19 20:07:13 <yahb2> [1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,6...
2026-02-19 20:07:20 <gentauro> % [[1..]..]
2026-02-19 20:07:20 <yahb2> Oops, something went wrong
2026-02-19 20:07:20 <tomsmeding> oh?
2026-02-19 20:07:22 <tomsmeding> ah
2026-02-19 20:07:27 <tomsmeding> try again
2026-02-19 20:07:32 × newmind quits (~newmind@91-133-90-252.dyn.cablelink.at) (Quit: Client closed)
2026-02-19 20:07:43 <tomsmeding> % [[1..]..]
2026-02-19 20:07:43 <yahb2> <interactive>:5:1: error: [GHC-39999] ; • No instance for ‘Enum [Integer]’ arising from a use of ‘it’ ; • In the first argument of ‘Yahb2Defs.limitedPrint’, namely ‘it’ ; In a stmt of...
2026-02-19 20:07:51 <gentauro> :o
2026-02-19 20:08:15 <tomsmeding> the 'print [1..]' was truncated and posted, but the command continued running and no new prompt was found, but it realised that only on the next input (yours), which restarted ghci
2026-02-19 20:08:23 newmind joins (~newmind@91-133-90-252.dyn.cablelink.at)
2026-02-19 20:08:29 <tomsmeding> there's an infelicity here in that it could detect it earlier perhaps
2026-02-19 20:08:32 <tomsmeding> but it works well enough
2026-02-19 20:09:07 × target_i quits (~target_i@user/target-i/x-6023099) (Ping timeout: 268 seconds)
2026-02-19 20:09:24 target_i joins (~target_i@user/target-i/x-6023099)
2026-02-19 20:10:17 <tomsmeding> the print function is this one https://git.tomsmeding.com/yahb2/tree/bwrap-files/workdir/Yahb2Defs.hs ; you also get this for some reason https://git.tomsmeding.com/yahb2/tree/bwrap-files/workdir/initdefs.hs
2026-02-19 20:10:52 <newmind> yeah, already was looking at it :D though i can just see it in code, rather than peppering you with questions
2026-02-19 20:10:56 <tomsmeding> % 5 * 6 :: Nat
2026-02-19 20:10:56 <yahb2> S (S (S (S (S (S (S (S (S (S (S (S (S (S (S (S (S (S (S (S (S (S (S (S (S (S (S (S (S (S Z)))))))))))))))))))))))))))))
2026-02-19 20:11:01 <tomsmeding> very useful
2026-02-19 20:11:49 <gentauro> SKI :o
2026-02-19 20:11:58 <tomsmeding> no, Peano
2026-02-19 20:12:07 <gentauro> oh yeah, my bad
2026-02-19 20:12:36 <gentauro> tomsmeding: you need `RecursivelyRunLengthCompressedNaturalNumbers` as well :)
2026-02-19 20:12:48 <tomsmeding> (isn't that Natural)
2026-02-19 20:13:12 <gentauro> `data T = F [T] deriving (Eq,Show,Read)`
2026-02-19 20:13:14 <gentauro> :)
2026-02-19 20:13:30 <gentauro> let me see if I can find likn to slides
2026-02-19 20:14:21 <newmind> so can you :set -interactive-print to something else?
2026-02-19 20:14:35 <newmind> or unset it
2026-02-19 20:14:39 <tomsmeding> yes
2026-02-19 20:14:48 <tomsmeding> you can :set lots of things
2026-02-19 20:15:05 <gentauro> https://pdfs.semanticscholar.org/c42c/2dcd3ab811c85e3962c31fb5f12ee5965b63.pdf
2026-02-19 20:16:06 Frostillicus joins (~Frostilli@pool-71-174-119-69.bstnma.fios.verizon.net)
2026-02-19 20:16:26 <EvanR> infelicity infelicity. Wow this word is so underused now a days
2026-02-19 20:17:02 <tomsmeding> the GHC user's guide has a list of infelicities :)
2026-02-19 20:18:51 <EvanR> it conjures up problematic behaviors or lack of behaviors that have always been there
2026-02-19 20:19:18 <EvanR> while "enshittification" evokes a transition from "ok" to "no ok anymore"
2026-02-19 20:19:55 <newmind> or "inner rage" for me >.>
2026-02-19 20:20:00 <EvanR> vocabulary intensifies
2026-02-19 20:26:55 × Frostillicus quits (~Frostilli@pool-71-174-119-69.bstnma.fios.verizon.net) (Ping timeout: 276 seconds)
2026-02-19 20:28:26 × welterde quits (welterde@thinkbase.srv.welterde.de) (Server closed connection)
2026-02-19 20:29:05 welterde joins (welterde@thinkbase.srv.welterde.de)
2026-02-19 20:29:45 <EvanR> tomsmeding, btw there are 30 S in case you were wondering
2026-02-19 20:29:50 <EvanR> I counted
2026-02-19 20:29:57 <monochrom> heh
2026-02-19 20:30:30 <tomsmeding> I... would have been distraught hadn't there be
2026-02-19 20:30:50 <tomsmeding> EvanR: are there also 30 )
2026-02-19 20:31:07 <monochrom> haha
2026-02-19 20:31:29 × pinkc quits (~luke@user/pinkc) (Ping timeout: 252 seconds)
2026-02-19 20:31:35 <monochrom> should be 29 though
2026-02-19 20:31:39 tomsmeding . o O ( https://xkcd.com/217/ )
2026-02-19 20:31:42 <monochrom> > 2 :: Nat
2026-02-19 20:31:44 <lambdabot> Not in scope: type constructor or class ‘Nat’
2026-02-19 20:31:57 <monochrom> % 2 :: Nat
2026-02-19 20:31:57 <yahb2> S (S Z)
2026-02-19 20:32:36 <EvanR> yeah I count 29
2026-02-19 20:32:40 <EvanR> off by one error!
2026-02-19 20:32:49 <monochrom> > exp pi - pi
2026-02-19 20:32:51 <lambdabot> 19.999099979189474
2026-02-19 20:32:59 × rekahsoft quits (~rekahsoft@76.67.111.168) (Read error: Connection reset by peer)
2026-02-19 20:33:11 <tomsmeding> % fromIntegral (round (exp pi - pi)) :: Nat
2026-02-19 20:33:11 <yahb2> S (S (S (S (S (S (S (S (S (S (S (S (S (S (S (S (S (S (S (S Z)))))))))))))))))))
2026-02-19 20:33:47 <tomsmeding> (pi is for circles right? That's why you should round it here)
2026-02-19 20:34:28 <EvanR> .oO( does pi fall out of hyperbolic trig at all )
2026-02-19 20:34:40 <monochrom> I concur :)
2026-02-19 20:37:01 <c_wraith> circles are undeniably round
2026-02-19 20:37:13 <darkling> EvanR: Only if you throw imaginary numbers into the functions, I think.
2026-02-19 20:37:42 Sgeo joins (~Sgeo@user/sgeo)
2026-02-19 20:37:58 jayanth joins (~jayanth@pool-108-16-35-209.phlapa.fios.verizon.net)
2026-02-19 20:38:10 <tomsmeding> a real number will suffice, but not a nice one
2026-02-19 20:38:31 <darkling> :)
2026-02-19 20:38:46 <monochrom> Oh yeah, clearly, sinh (arcsinh pi) = pi
2026-02-19 20:38:54 jmcantrell_ joins (~weechat@user/jmcantrell)
2026-02-19 20:39:11 <c_wraith> ah yes. pi falling out of the identity function
2026-02-19 20:39:46 × ggVGc quits (~ggVGc@a.lowtech.earth) (Server closed connection)
2026-02-19 20:39:53 <monochrom> <-- tautology hacker
2026-02-19 20:40:09 ggVGc joins (~ggVGc@a.lowtech.earth)
2026-02-19 20:42:02 halloy7365 joins (~halloy736@2404:4400:a100:9177:29eb:6604:6ca8:ff8b)
2026-02-19 20:45:30 jmcantrell_ is now known as jmcantrell
2026-02-19 20:46:16 × mcfrdy quits (~mcfrdy@user/mcfrdy) (Server closed connection)
2026-02-19 20:46:36 mcfrdy joins (~mcfrdy@user/mcfrdy)
2026-02-19 20:48:42 oskarw parts (~user@user/oskarw) (ERC 5.6.1 (IRC client for GNU Emacs 30.2))
2026-02-19 20:53:46 × chexum quits (~quassel@gateway/tor-sasl/chexum) (Remote host closed the connection)
2026-02-19 20:55:20 pinkc joins (~luke@user/pinkc)
2026-02-19 20:55:30 humasect joins (~humasect@dyn-192-249-132-90.nexicom.net)
2026-02-19 20:58:24 Square3 joins (~Square@user/square)
2026-02-19 20:58:47 × pinkc quits (~luke@user/pinkc) (Client Quit)
2026-02-19 21:01:46 × pierrot quits (~pi@user/pierrot) (Server closed connection)
2026-02-19 21:02:03 pierrot joins (~pi@user/pierrot)
2026-02-19 21:02:15 × sixfourtwelve quits (~ethanmorg@static.82.129.225.46.clients.your-server.de) (Ping timeout: 272 seconds)
2026-02-19 21:02:16 × darkling quits (~darkling@2001-ba8-1f1-f0e6-0-0-0-2.autov6rev.bitfolk.space) (Server closed connection)

All times are in UTC.