2025-04-07 00:00:04 +0200 | gmg | (~user@user/gehmehgeh) (Remote host closed the connection) |
2025-04-07 00:00:46 +0200 | gmg | (~user@user/gehmehgeh) gehmehgeh |
2025-04-07 00:03:12 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) (Ping timeout: 252 seconds) |
2025-04-07 00:04:05 +0200 | ljdarj1 | (~Thunderbi@user/ljdarj) ljdarj |
2025-04-07 00:07:24 +0200 | ljdarj | (~Thunderbi@user/ljdarj) (Ping timeout: 260 seconds) |
2025-04-07 00:07:24 +0200 | ljdarj1 | ljdarj |
2025-04-07 00:11:02 +0200 | <hellwolf> | here you go: https://github.com/hellwolf/haskell-examples/blob/master/2025-04-07-nfa-unboxed-linearity/nfa-perf… will share to discourse tomorrow with a few more details. feedback welcome. |
2025-04-07 00:13:56 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) merijn |
2025-04-07 00:16:30 +0200 | target_i | (~target_i@user/target-i/x-6023099) (Quit: leaving) |
2025-04-07 00:18:20 +0200 | Guest90 | (~Guest90@76.78.179.109) (Quit: Client closed) |
2025-04-07 00:19:15 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) (Ping timeout: 268 seconds) |
2025-04-07 00:29:51 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) merijn |
2025-04-07 00:39:01 +0200 | <|cos|> | koala_man: understandable! i wasn't really expecting it to be possible. the wine-idea is a creative approach! |
2025-04-07 00:39:07 +0200 | jacopovalanzano | (~jacopoval@cpc151911-cove17-2-0-cust105.3-1.cable.virginm.net) (Quit: Client closed) |
2025-04-07 00:45:12 +0200 | inca | (~inca@pool-96-255-212-224.washdc.fios.verizon.net) (Ping timeout: 272 seconds) |
2025-04-07 00:52:52 +0200 | inca | (~inca@pool-96-255-212-224.washdc.fios.verizon.net) |
2025-04-07 00:57:29 +0200 | inca | (~inca@pool-96-255-212-224.washdc.fios.verizon.net) (Ping timeout: 268 seconds) |
2025-04-07 00:58:30 +0200 | <|cos|> | koala_man: unless there are other ways to run wine on haiku than winebox, i guess that's a non-starter. it sure looks like a cool project, but it appears to be fully graphical with no concept of a console. it would be tricky to connect shellcheck to vim through such a component. |
2025-04-07 01:00:07 +0200 | <EvanR> | what appears to be fully graphical wit hno concept of a console? winebox? spellcheck? |
2025-04-07 01:02:28 +0200 | jespada | (~jespada@r179-25-205-222.dialup.adsl.anteldata.net.uy) (Ping timeout: 245 seconds) |
2025-04-07 01:03:13 +0200 | <|cos|> | i see nothing in the documentation of winebox to connect a console |
2025-04-07 01:05:34 +0200 | machinedgod | (~machinedg@d108-173-18-100.abhsia.telus.net) machinedgod |
2025-04-07 01:06:19 +0200 | jespada | (~jespada@r179-25-210-114.dialup.adsl.anteldata.net.uy) jespada |
2025-04-07 01:11:37 +0200 | emmanuelux | (~emmanuelu@user/emmanuelux) emmanuelux |
2025-04-07 01:13:20 +0200 | sprotte24 | (~sprotte24@p200300d16f28a1000c1aac2cfe7f30d8.dip0.t-ipconnect.de) (Quit: Leaving) |
2025-04-07 01:15:08 +0200 | <geekosaur> | windows doesn't have the concept of connecting an external console, so I wouldn't expect one |
2025-04-07 01:16:36 +0200 | <geekosaur> | the closest you get is RDP, which would be running as a service inside of winebox (and would only be available if you were running actual windows inside of it, which is possible with linux wine but I have no idea about winebox) |
2025-04-07 01:18:09 +0200 | <EvanR> | wine ought to be able to run a console only windows program |
2025-04-07 01:18:20 +0200 | <EvanR> | dunno about winebox |
2025-04-07 01:19:45 +0200 | <geekosaur> | well, wine doesn't come with a console, but you can install windows inside of it and use cmd.exe and probably powershell |
2025-04-07 01:20:07 +0200 | <geekosaur> | or install msys2 and use mintty |
2025-04-07 01:22:41 +0200 | <geekosaur> | but "winebox" suggests to me it's more complex than that (wine on most platforms translates win32 calls to native ones, but this sounds like it runs them in a separate environment of some kind) |
2025-04-07 01:22:59 +0200 | <geekosaur> | so a lot will depend on the nature of that environment |
2025-04-07 01:23:49 +0200 | amadaluzia | (~amadaluzi@user/amadaluzia) (Ping timeout: 260 seconds) |
2025-04-07 01:25:08 +0200 | <EvanR> | what is this program "wineconsole" |
2025-04-07 01:29:57 +0200 | <monochrom> | Yikes, installing windows inside wine... That breaks my mind. :) |
2025-04-07 01:30:25 +0200 | <monochrom> | I need more wine to understand that. >:) |
2025-04-07 01:30:34 +0200 | <geekosaur> | it shouldn't. wine just emulates the win32 api, it provides none of the commands or services |
2025-04-07 01:30:49 +0200 | <geekosaur> | so for many things you need to install windows in it to get them |
2025-04-07 01:33:46 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) (Ping timeout: 252 seconds) |
2025-04-07 01:34:24 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) merijn |
2025-04-07 01:34:50 +0200 | inca | (~inca@pool-96-255-212-224.washdc.fios.verizon.net) |
2025-04-07 01:35:11 +0200 | <EvanR> | wouldn't a windows program that writes to stdout, suitably "translated", be outputting to your terminal as normal |
2025-04-07 01:36:13 +0200 | <EvanR> | I could try it using a random EXE from the internet but I might get hacked! |
2025-04-07 01:37:29 +0200 | <geekosaur> | oddly enough, that "suitably translated" turns out to be surprisingly hard under windows |
2025-04-07 01:38:37 +0200 | <geekosaur> | the runtime "manufactures" a cmd.exe and hooks it somehow to your program. I'm a bit weak on the details |
2025-04-07 01:39:13 +0200 | <geekosaur> | and when it does so it usually turns off gui calls for some reason |
2025-04-07 01:39:54 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) (Ping timeout: 276 seconds) |
2025-04-07 01:41:12 +0200 | inca | (~inca@pool-96-255-212-224.washdc.fios.verizon.net) (Ping timeout: 276 seconds) |
2025-04-07 01:42:25 +0200 | sh1n | (~sh1n@2800:2134:583f:e223:7b49:e90d:6522:419d) (Remote host closed the connection) |
2025-04-07 01:43:35 +0200 | inca | (~inca@pool-96-255-212-224.washdc.fios.verizon.net) |
2025-04-07 01:44:29 +0200 | hgolden_ | (~hgolden@2603:8000:9d00:3ed1:d319:57ed:d2cb:68a5) hgolden |
2025-04-07 01:45:08 +0200 | remexre | (~remexre@user/remexre) remexre |
2025-04-07 01:47:09 +0200 | hgolden | (~hgolden@2603:8000:9d00:3ed1:1b03:b08c:d961:6530) (Ping timeout: 260 seconds) |
2025-04-07 01:48:31 +0200 | sprotte24 | (~sprotte24@p200300d16f28a1000c1aac2cfe7f30d8.dip0.t-ipconnect.de) |
2025-04-07 01:48:34 +0200 | sprotte24 | (~sprotte24@p200300d16f28a1000c1aac2cfe7f30d8.dip0.t-ipconnect.de) (Remote host closed the connection) |
2025-04-07 01:50:26 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) merijn |
2025-04-07 01:55:21 +0200 | msa | (msa@msa.planetofnix.com) (Quit: Still trying to figure out how bouncers work.) |
2025-04-07 01:57:39 +0200 | JuanDaugherty | (~juan@user/JuanDaugherty) (Quit: praxis.meansofproduction.biz (juan@acm.org)) |
2025-04-07 02:01:06 +0200 | <EvanR> | sometimes the lack of "apply f n number of times" function comes up, since it's missing from the standard library. So I came across this thing in a paper |
2025-04-07 02:01:11 +0200 | <EvanR> | :t let num 0 = \f -> \x -> x; num n = \f -> \x -> f (num (n - 1) f x) in num |
2025-04-07 02:01:11 +0200 | <lambdabot> | (Eq t1, Num t1) => t1 -> (t2 -> t2) -> t2 -> t2 |
2025-04-07 02:01:40 +0200 | <EvanR> | which produces church numerals from a number |
2025-04-07 02:02:44 +0200 | jespada | (~jespada@r179-25-210-114.dialup.adsl.anteldata.net.uy) (Ping timeout: 252 seconds) |
2025-04-07 02:03:31 +0200 | <EvanR> | that the type is that simple was apparently an achievement (at some point in history) because church's own type system rendered the numerals all in different bigger and bigger types |
2025-04-07 02:06:44 +0200 | <EvanR> | I'm not sure if using this thing literally for "apply f n number of times" in haskell would be smart or dumb |
2025-04-07 02:17:06 +0200 | Tuplanolla | (~Tuplanoll@91-159-69-59.elisa-laajakaista.fi) (Quit: Leaving.) |
2025-04-07 02:17:50 +0200 | <EvanR> | > let num 0 = \f -> \x -> x; num n = \f -> \x -> f (num (n - 1) f x) in num 10.0 "" ("Ha"++) |
2025-04-07 02:17:51 +0200 | <lambdabot> | error: |
2025-04-07 02:17:51 +0200 | <lambdabot> | • Couldn't match expected type ‘([Char] -> [Char]) |
2025-04-07 02:17:51 +0200 | <lambdabot> | -> [Char] -> [Char]’ |
2025-04-07 02:18:17 +0200 | <EvanR> | > let num 0 = \f -> \x -> x; num n = \f -> \x -> f (num (n - 1) f x) in num 10.0 ("Ha"++) "" |
2025-04-07 02:18:19 +0200 | <lambdabot> | "HaHaHaHaHaHaHaHaHaHa" |
2025-04-07 02:18:48 +0200 | <EvanR> | that was lucky |
2025-04-07 02:19:20 +0200 | <haskellbridge> | <Bowuigi> Any way to call mkfifo without the FFI? Can't find it on hoogle |
2025-04-07 02:23:59 +0200 | acidjnk_new3 | (~acidjnk@p200300d6e71c4f1484a8b96e5b185115.dip0.t-ipconnect.de) (Ping timeout: 252 seconds) |
2025-04-07 02:25:09 +0200 | <haskellbridge> | <Bowuigi> Found it, it's "createNamedPipe" on System.Posix.Files on the unix package |
2025-04-07 02:34:31 +0200 | msa | (msa@msa.planetofnix.com) |
2025-04-07 02:36:26 +0200 | <monochrom> | EvanR: Would you accept "num n f x = appEndo (stimesMonoid n (Endo f)) x" ? |
2025-04-07 02:39:51 +0200 | dontdieych2 | (~quassel@user/dontdieych2) dontdieych2 |
2025-04-07 02:42:46 +0200 | <monochrom> | Oh! Now I see why they called it "num". What you said. :) |
2025-04-07 02:43:24 +0200 | <monochrom> | instance Num (Endo a) where bwhahahaha |
2025-04-07 02:43:54 +0200 | <monochrom> | Oooohhhh I can put that for a tutorial exercise! |
2025-04-07 02:53:30 +0200 | xff0x | (~xff0x@2405:6580:b080:900:2d8c:c4f2:3458:8ce1) (Ping timeout: 246 seconds) |
2025-04-07 02:57:26 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) (Ping timeout: 244 seconds) |
2025-04-07 03:01:09 +0200 | otto_s | (~user@p5de2fb60.dip0.t-ipconnect.de) (Ping timeout: 248 seconds) |
2025-04-07 03:02:55 +0200 | otto_s | (~user@p5de2f09d.dip0.t-ipconnect.de) |
2025-04-07 03:04:09 +0200 | <EvanR> | yeah going through Endo is a bit verbose |
2025-04-07 03:05:26 +0200 | toby-bro | (~toby-bro@user/toby-bro) (Ping timeout: 252 seconds) |
2025-04-07 03:08:23 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) merijn |
2025-04-07 03:12:46 +0200 | hgolden_ | (~hgolden@2603:8000:9d00:3ed1:d319:57ed:d2cb:68a5) (Ping timeout: 272 seconds) |
2025-04-07 03:13:08 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) (Ping timeout: 252 seconds) |
2025-04-07 03:24:10 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) merijn |
2025-04-07 03:32:56 +0200 | machinedgod | (~machinedg@d108-173-18-100.abhsia.telus.net) (Ping timeout: 252 seconds) |
2025-04-07 03:39:38 +0200 | xff0x | (~xff0x@fsb6a9491c.tkyc517.ap.nuro.jp) |
2025-04-07 03:40:10 +0200 | <EvanR> | hindley 1969 contains two interpretations of applying types to combinators, the second of which "the alternative system" makes it easier to give a set theoretic interpretation to the combinators. Saying in the first system it's not so clear what the set theoretic meaning of applying K combinator to itself is |
2025-04-07 03:41:21 +0200 | <EvanR> | The Principal Type-Scheme of an Object in Combinatory Logic |
2025-04-07 03:42:24 +0200 | tremon | (~tremon@83.80.159.219) (Quit: getting boxed in) |
2025-04-07 03:54:34 +0200 | dontdieych2 | (~quassel@user/dontdieych2) (Ping timeout: 252 seconds) |
2025-04-07 04:05:09 +0200 | Square | (~Square@user/square) (Ping timeout: 248 seconds) |
2025-04-07 04:09:08 +0200 | dontdieych2 | (~quassel@user/dontdieych2) dontdieych2 |
2025-04-07 04:13:39 +0200 | igemnace | (~igemnace@user/igemnace) (Quit: ZNC 1.9.0+deb2build3 - https://znc.in) |
2025-04-07 04:16:26 +0200 | dontdieych2 | (~quassel@user/dontdieych2) (Quit: https://quassel-irc.org - Chat comfortably. Anywhere.) |
2025-04-07 04:18:05 +0200 | igemnace | (~igemnace@user/igemnace) igemnace |
2025-04-07 04:18:38 +0200 | <haskellbridge> | <thirdofmay18081814goya> when people talk about phantom types, they're talking exactly about GADTs right? |
2025-04-07 04:19:34 +0200 | <monochrom> | Does "data Proxy a = Proxy" count as phantom type? Does it count as GADTs? |
2025-04-07 04:20:28 +0200 | <Leary> | monochrom: I think you want `Endo (Endo a)`, though that's still not polymorphic enough for some operations. |
2025-04-07 04:22:34 +0200 | <haskellbridge> | <dmjio> thirdofmay18081814goya: No |
2025-04-07 04:22:50 +0200 | <monochrom> | Oh! |
2025-04-07 04:24:08 +0200 | <haskellbridge> | <thirdofmay18081814goya> hm ok right ty all for comments, and strictly speaking, a type being a phantom type is not a type-theoretical property but an implementation detail of how syntax gets typechecked, right? |
2025-04-07 04:24:44 +0200 | <haskellbridge> | <thirdofmay18081814goya> or how a type gets inferred for a piece of syntax |
2025-04-07 04:26:37 +0200 | <geekosaur> | no. a phantom type is one that doesn't occur in the value |
2025-04-07 04:26:47 +0200 | <geekosaur> | it only affects typing |
2025-04-07 04:27:52 +0200 | <geekosaur> | so in `data Maybe a = Nothing | Just a`, `a` is phantom in `Nothing` |
2025-04-07 04:28:15 +0200 | <haskellbridge> | <thirdofmay18081814goya> ok I see that makes sense, ty! |
2025-04-07 04:31:09 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) (Ping timeout: 252 seconds) |
2025-04-07 04:37:20 +0200 | hgolden | (~hgolden@2603:8000:9d00:3ed1:d5a9:8f67:3cb9:6399) hgolden |
2025-04-07 04:42:03 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) merijn |
2025-04-07 04:46:19 +0200 | peterbecich | (~Thunderbi@syn-047-229-123-186.res.spectrum.com) peterbecich |
2025-04-07 04:46:54 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) (Ping timeout: 246 seconds) |
2025-04-07 04:57:42 +0200 | peterbecich | (~Thunderbi@syn-047-229-123-186.res.spectrum.com) (Quit: peterbecich) |
2025-04-07 04:58:05 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) merijn |
2025-04-07 05:10:04 +0200 | emmanuelux | (~emmanuelu@user/emmanuelux) (Quit: au revoir) |
2025-04-07 05:12:24 +0200 | amadaluzia_ | (~amadaluzi@user/amadaluzia) (Ping timeout: 252 seconds) |
2025-04-07 05:43:16 +0200 | michalz | (~michalz@185.246.207.222) |
2025-04-07 05:46:58 +0200 | dutchie | (~dutchie@user/dutchie) (Remote host closed the connection) |
2025-04-07 05:48:02 +0200 | dutchie | (~dutchie@user/dutchie) dutchie |
2025-04-07 06:05:41 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) (Ping timeout: 248 seconds) |
2025-04-07 06:11:50 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) merijn |
2025-04-07 06:14:55 +0200 | peterbecich | (~Thunderbi@syn-047-229-123-186.res.spectrum.com) peterbecich |
2025-04-07 06:17:32 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) (Ping timeout: 268 seconds) |
2025-04-07 06:27:46 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) merijn |
2025-04-07 06:32:42 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) (Ping timeout: 252 seconds) |
2025-04-07 06:42:03 +0200 | peterbecich | (~Thunderbi@syn-047-229-123-186.res.spectrum.com) (Ping timeout: 246 seconds) |
2025-04-07 06:43:32 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) merijn |
2025-04-07 06:43:41 +0200 | <Axman6> | thirdofmay18081814goya: newtype Tagged t a = Tagged a -- t is a phantom type, there are no values of type t in a value of type Tagged t a, but the types Tagged Bool Int and Tagged String Int are different (so you couldn't use Eq to check if the a values were the same, for example). |
2025-04-07 06:44:37 +0200 | <Axman6> | they allow you to add some extra type information for the compiler to check for you but it won't exist at runtime. |
2025-04-07 06:45:33 +0200 | j1n37- | (~j1n37@user/j1n37) (Ping timeout: 265 seconds) |
2025-04-07 06:48:57 +0200 | j1n37 | (~j1n37@user/j1n37) j1n37 |
2025-04-07 06:50:27 +0200 | adamCS | (~adamCS@pool-100-33-104-162.nycmny.fios.verizon.net) (Ping timeout: 244 seconds) |
2025-04-07 06:50:31 +0200 | Guest2 | (~Guest2@2406:b400:b4:1391:acdf:3bba:fba7:e00a) |
2025-04-07 06:50:53 +0200 | adamCS | (~adamCS@pool-100-33-104-162.nycmny.fios.verizon.net) adamCS |
2025-04-07 06:57:06 +0200 | Guest2 | (~Guest2@2406:b400:b4:1391:acdf:3bba:fba7:e00a) (Quit: Client closed) |
2025-04-07 07:10:24 +0200 | machinedgod | (~machinedg@d108-173-18-100.abhsia.telus.net) machinedgod |
2025-04-07 07:12:04 +0200 | tabaqui | (~tabaqui@167.71.80.236) tabaqui |
2025-04-07 07:30:23 +0200 | m5zs7k | (aquares@web10.mydevil.net) (Ping timeout: 245 seconds) |
2025-04-07 07:35:04 +0200 | m5zs7k | (aquares@web10.mydevil.net) m5zs7k |
2025-04-07 07:43:49 +0200 | jmcantrell | (~weechat@user/jmcantrell) (Quit: WeeChat 4.6.0) |
2025-04-07 07:43:49 +0200 | jmcantrell_ | jmcantrell |
2025-04-07 07:47:39 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) (Ping timeout: 260 seconds) |
2025-04-07 07:53:28 +0200 | aljazmc | (~aljazmc@user/aljazmc) aljazmc |
2025-04-07 07:59:59 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) merijn |
2025-04-07 08:01:05 +0200 | Guest2 | (~Guest2@49.204.7.12) |
2025-04-07 08:01:51 +0200 | Guest2 | (~Guest2@49.204.7.12) (Client Quit) |
2025-04-07 08:06:55 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) (Ping timeout: 244 seconds) |
2025-04-07 08:07:16 +0200 | inca | (~inca@pool-96-255-212-224.washdc.fios.verizon.net) (Ping timeout: 272 seconds) |
2025-04-07 08:09:59 +0200 | sord937 | (~sord937@gateway/tor-sasl/sord937) sord937 |
2025-04-07 08:18:03 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) merijn |
2025-04-07 08:19:27 +0200 | inca | (~inca@pool-96-255-212-224.washdc.fios.verizon.net) |
2025-04-07 08:30:48 +0200 | inca | (~inca@pool-96-255-212-224.washdc.fios.verizon.net) (Ping timeout: 245 seconds) |
2025-04-07 08:32:38 +0200 | Sgeo | (~Sgeo@user/sgeo) (Read error: Connection reset by peer) |
2025-04-07 08:33:36 +0200 | inca | (~inca@pool-96-255-212-224.washdc.fios.verizon.net) |
2025-04-07 08:40:12 +0200 | inca | (~inca@pool-96-255-212-224.washdc.fios.verizon.net) (Ping timeout: 272 seconds) |
2025-04-07 08:46:13 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) (Ping timeout: 248 seconds) |
2025-04-07 08:49:47 +0200 | ft | (~ft@p508db463.dip0.t-ipconnect.de) (Quit: leaving) |
2025-04-07 08:57:10 +0200 | |cos| | (~libera@loza.netizen.se) (WeeChat 4.4.2) |
2025-04-07 08:58:16 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) merijn |
2025-04-07 09:00:01 +0200 | caconym | (~caconym@user/caconym) (Quit: bye) |
2025-04-07 09:00:46 +0200 | acidjnk_new3 | (~acidjnk@p200300d6e71c4f1484a8b96e5b185115.dip0.t-ipconnect.de) |
2025-04-07 09:01:29 +0200 | caconym | (~caconym@user/caconym) caconym |
2025-04-07 09:05:35 +0200 | tromp | (~textual@2001:1c00:3487:1b00:1419:ab0:498a:2d0c) |
2025-04-07 09:06:32 +0200 | inca | (~inca@pool-96-255-212-224.washdc.fios.verizon.net) |
2025-04-07 09:07:48 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) (Ping timeout: 252 seconds) |
2025-04-07 09:11:03 +0200 | vidisha | (~vidisha@117.222.95.178) |
2025-04-07 09:13:18 +0200 | inca | (~inca@pool-96-255-212-224.washdc.fios.verizon.net) (Ping timeout: 252 seconds) |
2025-04-07 09:13:32 +0200 | lortabac | (~lortabac@2a01:e0a:541:b8f0:55ab:e185:7f81:54a4) lortabac |
2025-04-07 09:17:19 +0200 | Lord_of_Life_ | (~Lord@user/lord-of-life/x-2819915) Lord_of_Life |
2025-04-07 09:17:53 +0200 | Lord_of_Life | (~Lord@user/lord-of-life/x-2819915) (Ping timeout: 245 seconds) |
2025-04-07 09:18:40 +0200 | Lord_of_Life_ | Lord_of_Life |
2025-04-07 09:21:18 +0200 | adamCS | (~adamCS@pool-100-33-104-162.nycmny.fios.verizon.net) (Ping timeout: 268 seconds) |
2025-04-07 09:22:47 +0200 | sord937 | (~sord937@gateway/tor-sasl/sord937) (Remote host closed the connection) |
2025-04-07 09:23:07 +0200 | sord937 | (~sord937@gateway/tor-sasl/sord937) sord937 |
2025-04-07 09:25:11 +0200 | inca | (~inca@pool-96-255-212-224.washdc.fios.verizon.net) |
2025-04-07 09:25:59 +0200 | vidisha | (~vidisha@117.222.95.178) (Quit: Client closed) |
2025-04-07 09:27:30 +0200 | rawles | (~rawles@user/rawles) (Quit: -) |
2025-04-07 09:29:42 +0200 | inca | (~inca@pool-96-255-212-224.washdc.fios.verizon.net) (Ping timeout: 246 seconds) |
2025-04-07 09:30:37 +0200 | tzh | (~tzh@c-76-115-131-146.hsd1.or.comcast.net) (Quit: zzz) |
2025-04-07 09:37:04 +0200 | fp | (~Thunderbi@2001:708:20:1406::1370) fp |
2025-04-07 09:38:34 +0200 | tavare | (~tavare@user/tavare) tavare |
2025-04-07 09:42:56 +0200 | lxsameer | (~lxsameer@Serene/lxsameer) lxsameer |
2025-04-07 09:47:59 +0200 | inca | (~inca@pool-96-255-212-224.washdc.fios.verizon.net) |
2025-04-07 09:54:19 +0200 | merijn | (~merijn@77.242.116.146) merijn |
2025-04-07 09:58:50 +0200 | XZDX | (~xzdx@user/XZDX) (Remote host closed the connection) |
2025-04-07 09:59:07 +0200 | <haskellbridge> | <thirdofmay18081814goya> ah helpful example, ty! |
2025-04-07 10:20:13 +0200 | XZDX | (~xzdx@2601:404:ce00:4e51:214:51ff:fe2b:e82e) |
2025-04-07 10:20:18 +0200 | werneta | (~werneta@syn-071-083-160-242.res.spectrum.com) (Ping timeout: 252 seconds) |
2025-04-07 10:20:35 +0200 | chele | (~chele@user/chele) chele |
2025-04-07 10:21:12 +0200 | comerijn | (~merijn@77.242.116.146) merijn |
2025-04-07 10:21:57 +0200 | XZDX | (~xzdx@2601:404:ce00:4e51:214:51ff:fe2b:e82e) (Changing host) |
2025-04-07 10:21:57 +0200 | XZDX | (~xzdx@user/XZDX) XZDX |
2025-04-07 10:23:36 +0200 | merijn | (~merijn@77.242.116.146) (Ping timeout: 252 seconds) |
2025-04-07 10:27:17 +0200 | fp | (~Thunderbi@2001:708:20:1406::1370) (Ping timeout: 268 seconds) |
2025-04-07 10:32:16 +0200 | AlexNoo_ | (~AlexNoo@178.34.162.245) |
2025-04-07 10:32:16 +0200 | AlexNoo | (~AlexNoo@178.34.162.245) (Read error: Connection reset by peer) |
2025-04-07 10:35:15 +0200 | mceresa | (~mceresa@user/mceresa) (Ping timeout: 252 seconds) |
2025-04-07 10:46:50 +0200 | polyphem | (~rod@pd9fbf91a.dip0.t-ipconnect.de) polyphem |
2025-04-07 10:49:32 +0200 | mceresa | (~mceresa@user/mceresa) mceresa |
2025-04-07 10:51:16 +0200 | <kqr> | I have a Conduit stream that yields one line of ByteString at a time. I want to write a step that consumes these lines and produces a derived value every few lines. What would be the best way to do this? I have currently written one to be tail recursive, and it works, but I suspect it leads to a space leak due to introducing a new thunk for every recursive call, which is every line emitted by the |
2025-04-07 10:51:18 +0200 | <kqr> | stream. |
2025-04-07 10:51:27 +0200 | <kqr> | By tail recursive, I mean that it gradually populates a sequence of Maybe arguments, and once all are filled, it yields the derived object and calls itself with all Nothing arguments again. Every time it encounters a line that contains a value that should go in the derived object, it calls itself with that argument filled with a Just value. |
2025-04-07 10:57:25 +0200 | lortabac | (~lortabac@2a01:e0a:541:b8f0:55ab:e185:7f81:54a4) (Ping timeout: 248 seconds) |
2025-04-07 11:00:18 +0200 | econo_ | (uid147250@id-147250.tinside.irccloud.com) (Quit: Connection closed for inactivity) |
2025-04-07 11:01:39 +0200 | __monty__ | (~toonn@user/toonn) toonn |
2025-04-07 11:04:29 +0200 | forell | (~forell@user/forell) forell |
2025-04-07 11:04:55 +0200 | lortabac | (~lortabac@2a01:e0a:541:b8f0:55ab:e185:7f81:54a4) |
2025-04-07 11:18:54 +0200 | rit | (~rit@2409:40e0:a:1a99:c94b:aeae:2b1a:e2c4) |
2025-04-07 11:19:11 +0200 | fp | (~Thunderbi@2001:708:20:1406::1370) fp |
2025-04-07 11:30:15 +0200 | <kqr> | Maybe something like concatMapAccumC would do the trick... |
2025-04-07 11:30:57 +0200 | <kqr> | Except that is still expected to produce an output each iteration. Though I suppose that output could be Nothing which would then be catMaybe'd out of the stream |
2025-04-07 11:33:06 +0200 | XZDX | (~xzdx@user/XZDX) (Read error: Connection reset by peer) |
2025-04-07 11:33:29 +0200 | XZDX | (~xzdx@2601:404:ce00:4e51:214:51ff:fe2b:e82e) |
2025-04-07 11:35:32 +0200 | <kqr> | (or I suppose the more plain mapAccum in this case) |
2025-04-07 11:59:36 +0200 | weary-traveler | (~user@user/user363627) (Remote host closed the connection) |
2025-04-07 12:09:27 +0200 | XZDX | (~xzdx@2601:404:ce00:4e51:214:51ff:fe2b:e82e) (Remote host closed the connection) |
2025-04-07 12:11:23 +0200 | <kqr> | Maybe it's not a space leak after all. According to https://github.com/haskell-perf/dictionaries?tab=readme-ov-file#pure-maps-fromlist-space-use maybe I should not be surprised if the map consumes orders of magnitude more memory when created than when queried... |
2025-04-07 12:13:36 +0200 | xff0x | (~xff0x@fsb6a9491c.tkyc517.ap.nuro.jp) (Ping timeout: 252 seconds) |
2025-04-07 12:14:51 +0200 | <kqr> | Although in my case it happens with a CuckooHashTable based implementation too. Strange. |
2025-04-07 12:15:12 +0200 | comerijn | (~merijn@77.242.116.146) (Ping timeout: 268 seconds) |
2025-04-07 12:16:26 +0200 | rit | (~rit@2409:40e0:a:1a99:c94b:aeae:2b1a:e2c4) (Remote host closed the connection) |
2025-04-07 12:16:56 +0200 | merijn | (~merijn@77.242.116.146) merijn |
2025-04-07 12:19:58 +0200 | lortabac | (~lortabac@2a01:e0a:541:b8f0:55ab:e185:7f81:54a4) (Ping timeout: 245 seconds) |
2025-04-07 12:20:38 +0200 | rit | (~rit@2409:40e0:a:1a99:c94b:aeae:2b1a:e2c4) |
2025-04-07 12:21:13 +0200 | dhil | (~dhil@2a0c:b381:52e:3600:7599:e3a2:8d31:477d) dhil |
2025-04-07 12:21:33 +0200 | merijn | (~merijn@77.242.116.146) (Ping timeout: 246 seconds) |
2025-04-07 12:32:42 +0200 | merijn | (~merijn@77.242.116.146) merijn |
2025-04-07 12:33:03 +0200 | aljazmc | (~aljazmc@user/aljazmc) (Quit: Leaving) |
2025-04-07 12:45:43 +0200 | <Digit> | smart people, help my brain stop exploding... i've just seen someone assert that 2 is the smallest prime number. not 1. how can 1 not be prime? divisable by itself, and 1, whole integer result... it's THE prime number, the primest prime number, right? |
2025-04-07 12:46:13 +0200 | <__monty__> | It only has one divisor, not exactly two. |
2025-04-07 12:46:15 +0200 | XZDX | (~xzdx@2601:404:ce00:4e51:214:51ff:fe2b:e82e) |
2025-04-07 12:51:01 +0200 | <Digit> | hrmm. i've been running on some crude incomplete definition of prime then. ... reading "integers greater than 1, with exactly 2 positive divisors: 1 and itself.", sounds contrived to me, so long thinking it was just " divisable by itself, and 1, whole integer result"... defining it specifically as "greater than 1", smells. |
2025-04-07 12:51:55 +0200 | Digit | carries on with life |
2025-04-07 12:53:48 +0200 | <enikar> | Digit: The problem with 1 is that it divides all the numbers, so including it in the prime numbers requires an exception to be made in the statement of theorems. So for simplicity's sake we've excluded 1 from the prime numbers. |
2025-04-07 12:57:05 +0200 | <Digit> | ah, that makes sense why, seeing it from that side. |
2025-04-07 12:58:04 +0200 | <Digit> | anyways, didnt mean to disrupt the chan with that silly aside. just enjoying notions around infinite lists (and wondering how applies in haskell), while watching https://www.youtube.com/watch?v=_cr46G2K5Fo |
2025-04-07 13:01:04 +0200 | ethantwardy | (user@user/ethantwardy) (Quit: WeeChat 4.4.2) |
2025-04-07 13:02:05 +0200 | jespada | (~jespada@r179-25-210-114.dialup.adsl.anteldata.net.uy) jespada |
2025-04-07 13:02:46 +0200 | ethantwardy | (user@user/ethantwardy) ethantwardy |
2025-04-07 13:02:59 +0200 | adamCS | (~adamCS@98.113.183.73) adamCS |
2025-04-07 13:07:31 +0200 | lortabac | (~lortabac@2a01:e0a:541:b8f0:55ab:e185:7f81:54a4) lortabac |
2025-04-07 13:10:42 +0200 | hellwolf | (~user@d446-ae4d-8e8d-4d2f-0f00-4d40-07d0-2001.sta.estpak.ee) (Ping timeout: 268 seconds) |
2025-04-07 13:13:13 +0200 | hellwolf | (~user@39b5-985a-dddf-4331-0f00-4d40-07d0-2001.sta.estpak.ee) hellwolf |
2025-04-07 13:14:05 +0200 | xff0x | (~xff0x@ai066236.d.east.v6connect.net) |
2025-04-07 13:21:13 +0200 | secular91 | (~secular@155.93.244.228) |
2025-04-07 13:21:31 +0200 | tromp | (~textual@2001:1c00:3487:1b00:1419:ab0:498a:2d0c) (Quit: My iMac has gone to sleep. ZZZzzz…) |
2025-04-07 13:27:27 +0200 | secular91 | (~secular@155.93.244.228) (Quit: Client closed) |
2025-04-07 13:28:15 +0200 | <__monty__> | Digit: You don't need the "greater than 1" part of that definition though. The set containing 1 and 1 is of size 1, so 1 does *not* have *exactly two* divisors. |
2025-04-07 13:32:15 +0200 | ubert | (~Thunderbi@2a02:8109:ab8a:5a00:508f:565:5e73:917) ubert |
2025-04-07 13:41:40 +0200 | Pozyomka | (~pyon@user/pyon) (Quit: brb) |
2025-04-07 13:42:49 +0200 | Pozyomka | (~pyon@user/pyon) pyon |
2025-04-07 13:51:36 +0200 | <Digit> | i think the wording's clearer with the greater than 1, as there's a hint of ambiguity as phrased there, not specifying they're distinct. at first glance, that's like, they two could be the same. |
2025-04-07 13:54:28 +0200 | <__monty__> | No, because then you only have one divisor. Or would you say all primes actually have infinite divisors? Themselves, and an infinite series of 1's. |
2025-04-07 14:02:32 +0200 | tremon | (~tremon@83.80.159.219) tremon |
2025-04-07 14:09:28 +0200 | <Digit> | no. |
2025-04-07 14:10:34 +0200 | toby-bro | (~toby-bro@user/toby-bro) toby-bro |
2025-04-07 14:14:24 +0200 | polyphem | (~rod@pd9fbf91a.dip0.t-ipconnect.de) (Ping timeout: 260 seconds) |
2025-04-07 14:14:49 +0200 | Square | (~Square4@user/square) Square |
2025-04-07 14:40:06 +0200 | pointlessslippe1 | (~pointless@62.106.85.17) (Ping timeout: 244 seconds) |
2025-04-07 14:50:49 +0200 | pointlessslippe1 | (~pointless@62.106.85.17) pointlessslippe1 |
2025-04-07 15:06:50 +0200 | tromp | (~textual@2001:1c00:3487:1b00:1419:ab0:498a:2d0c) |
2025-04-07 15:16:01 +0200 | <haskellbridge> | <Liamzee> i should feel embarrassed |
2025-04-07 15:16:30 +0200 | <haskellbridge> | <Liamzee> i streamed an intro showing off gabriella gonzalez's simple twitter, but the code broke and i ended up demonstrating simple twitter that couldn't ttweet :( |
2025-04-07 15:24:48 +0200 | bitdex | (~bitdex@gateway/tor-sasl/bitdex) (Quit: = "") |
2025-04-07 15:25:40 +0200 | amadaluzia | (~amadaluzi@2a00:23c7:ed8b:6701:fca7:4ddf:16d4:e0c7) |
2025-04-07 15:27:36 +0200 | JuanDaugherty | (~juan@user/JuanDaugherty) JuanDaugherty |
2025-04-07 15:31:38 +0200 | weary-traveler | (~user@user/user363627) user363627 |
2025-04-07 15:33:08 +0200 | tavare | (~tavare@user/tavare) (Remote host closed the connection) |
2025-04-07 15:57:44 +0200 | Unicorn_Princess | (~Unicorn_P@user/Unicorn-Princess/x-3540542) Unicorn_Princess |
2025-04-07 16:00:53 +0200 | pavonia | (~user@user/siracusa) (Quit: Bye!) |
2025-04-07 16:04:36 +0200 | JuanDaugherty | (~juan@user/JuanDaugherty) (Quit: praxis.meansofproduction.biz (juan@acm.org)) |
2025-04-07 16:10:30 +0200 | lortabac | (~lortabac@2a01:e0a:541:b8f0:55ab:e185:7f81:54a4) (Ping timeout: 272 seconds) |
2025-04-07 16:11:56 +0200 | sabino | (~sabino@user/sabino) sabino |
2025-04-07 16:13:34 +0200 | remexre | (~remexre@user/remexre) (Remote host closed the connection) |
2025-04-07 16:26:16 +0200 | rekahsoft | (~rekahsoft@bras-base-orllon1103w-grc-15-174-95-4-83.dsl.bell.ca) rekahsoft |
2025-04-07 16:30:54 +0200 | rit | (~rit@2409:40e0:a:1a99:c94b:aeae:2b1a:e2c4) (Ping timeout: 240 seconds) |
2025-04-07 16:36:09 +0200 | acidjnk_new3 | (~acidjnk@p200300d6e71c4f1484a8b96e5b185115.dip0.t-ipconnect.de) (Ping timeout: 260 seconds) |
2025-04-07 16:36:32 +0200 | AlexNoo_ | AlexNoo |
2025-04-07 16:40:35 +0200 | tromp | (~textual@2001:1c00:3487:1b00:1419:ab0:498a:2d0c) (Quit: My iMac has gone to sleep. ZZZzzz…) |
2025-04-07 16:45:44 +0200 | alx741 | (~alx741@186.33.188.229) |
2025-04-07 16:47:01 +0200 | alx741 | (~alx741@186.33.188.229) (Client Quit) |
2025-04-07 16:53:04 +0200 | lortabac | (~lortabac@2a01:e0a:541:b8f0:55ab:e185:7f81:54a4) |
2025-04-07 17:01:45 +0200 | __jmcantrell__ | (~weechat@user/jmcantrell) jmcantrell |
2025-04-07 17:02:04 +0200 | tromp | (~textual@2001:1c00:3487:1b00:1419:ab0:498a:2d0c) |
2025-04-07 17:02:20 +0200 | <SrPx> | hello, I think I'm reinventing the wheel here, so, let me ask to avoid that. suppose you have a tree of ints, defined as `data Tree = Node Tree Tree | Leaf Int`. let X be a source tree, and Y be a target tree, which is has the same node count and members as X (i.e., Y is a permutation of X) |
2025-04-07 17:03:09 +0200 | gorignak | (~gorignak@user/gorignak) (Quit: quit) |
2025-04-07 17:03:20 +0200 | jmcantrell | (644f1bed9a@user/jmcantrell) (Killed (zinc.libera.chat (Nickname regained by services))) |
2025-04-07 17:03:20 +0200 | __jmcantrell__ | jmcantrell |
2025-04-07 17:03:28 +0200 | jmcantrell_ | (644f1bed9a@user/jmcantrell) jmcantrell |
2025-04-07 17:04:28 +0200 | <SrPx> | our goal is to create a function `F : Tree → Tree` that transforms X into Y, except that a function is only allowed to 1. match and call an aux fn (as in: F (C a b) → (C (P a) (Q b)), 2. call a pre-determined combinator. |
2025-04-07 17:05:31 +0200 | remexre | (~remexre@user/remexre) remexre |
2025-04-07 17:06:47 +0200 | <SrPx> | so, for example, `((1 2) (3 4))` could be transformed into `((4 3) (1 2))` by the following F: |
2025-04-07 17:06:58 +0200 | <SrPx> | F(xs) = map A B (swap xs) where A(xs) = swap xs ; B(xs) = xs |
2025-04-07 17:07:13 +0200 | <SrPx> | it would work as follows: |
2025-04-07 17:07:26 +0200 | polyphem | (~rod@pd9fbf91a.dip0.t-ipconnect.de) polyphem |
2025-04-07 17:07:51 +0200 | <SrPx> | F ((1,2),(3,4)) → (A(3,4),B(1,2)) → ((4,3),(1,2)) |
2025-04-07 17:08:55 +0200 | <SrPx> | okay, that works. now, in this case, we used only one combinator: `swap`. my question is: what is the minimal set of combinators, that is expressive enough to perform any permutation, by constructing a suitable `F`? |
2025-04-07 17:09:29 +0200 | <SrPx> | obviously `swap` isn't enough, because we can't transform `((1,2),(3,4))` into `(1,(2,(3,4)))`. so we need more combinators, like comm-L, assoc-L... |
2025-04-07 17:10:36 +0200 | <SrPx> | I'm interested specifically in the minimal set of combinators. also remember that the "cursor" (i.e., the function we're calling) can only ever go down, so, just swap/comm/assoc isn't enough. counterexample: (((a b) c) d) → (c (b d)) |
2025-04-07 17:10:50 +0200 | <SrPx> | and also, `((a b) (c d)) → ((a c) (b d))` |
2025-04-07 17:11:22 +0200 | <SrPx> | so is this an existing / known problem, and, if so, is there a minimal set of axioms / operations capable of expressing any permutation when composed? |
2025-04-07 17:15:14 +0200 | acidjnk_new3 | (~acidjnk@p200300d6e71c4f1839a5a90aae0b2850.dip0.t-ipconnect.de) |
2025-04-07 17:16:57 +0200 | <SrPx> | since this is a long question, I've also posted it on SE: https://cs.stackexchange.com/questions/171677/what-is-a-minimal-set-of-combinators-capable-of-perf… |
2025-04-07 17:17:58 +0200 | jespada | (~jespada@r179-25-210-114.dialup.adsl.anteldata.net.uy) (Quit: My Mac has gone to sleep. ZZZzzz…) |
2025-04-07 17:19:23 +0200 | fr33domlover | (~fr33domlo@towards.vision) fr33domlover |
2025-04-07 17:20:34 +0200 | jespada | (~jespada@r179-25-210-114.dialup.adsl.anteldata.net.uy) jespada |
2025-04-07 17:35:59 +0200 | <EvanR> | a foot note in the SICP section on logic programming points out a "flaw" in their query language, where repeated substitution sometimes gets the correct result and sometimes not |
2025-04-07 17:37:34 +0200 | <EvanR> | y = 1 - 2y has the solution 1/3, which is what you get after infinitely substituting the right side for y on the right side, if you add the infinite series normally |
2025-04-07 17:38:15 +0200 | <EvanR> | y = 1 + 2y has the solution -1, but if you tried substituting infinitely you'd get -1 = 1 + 2 + 4 + 8 + ... which it points out is wrong |
2025-04-07 17:38:26 +0200 | <EvanR> | another great idea goes out the window! |
2025-04-07 17:38:32 +0200 | <EvanR> | they discovered the negative unit type |
2025-04-07 17:44:30 +0200 | <EvanR> | data Y = Leaf | Branch Y Y |
2025-04-07 17:45:14 +0200 | lortabac | (~lortabac@2a01:e0a:541:b8f0:55ab:e185:7f81:54a4) (Quit: WeeChat 4.5.2) |
2025-04-07 17:49:43 +0200 | jrm | (~jrm@user/jrm) (Ping timeout: 244 seconds) |
2025-04-07 17:51:03 +0200 | <haskellbridge> | <Bowuigi> SrPx do these combinators have to specify exactly the permutations or can they be more powerful? |
2025-04-07 17:56:03 +0200 | peterbecich | (~Thunderbi@syn-047-229-123-186.res.spectrum.com) peterbecich |
2025-04-07 18:10:00 +0200 | machinedgod | (~machinedg@d108-173-18-100.abhsia.telus.net) (Ping timeout: 252 seconds) |
2025-04-07 18:14:33 +0200 | sabathan | (~sabathan@amarseille-159-1-12-107.w86-203.abo.wanadoo.fr) (Quit: yolo) |
2025-04-07 18:17:12 +0200 | ubert | (~Thunderbi@2a02:8109:ab8a:5a00:508f:565:5e73:917) (Remote host closed the connection) |
2025-04-07 18:17:22 +0200 | j1n37- | (~j1n37@user/j1n37) j1n37 |
2025-04-07 18:17:39 +0200 | merijn | (~merijn@77.242.116.146) (Ping timeout: 260 seconds) |
2025-04-07 18:18:26 +0200 | j1n37 | (~j1n37@user/j1n37) (Ping timeout: 252 seconds) |
2025-04-07 18:19:36 +0200 | sabathan2 | (~sabathan@amarseille-159-1-12-107.w86-203.abo.wanadoo.fr) |
2025-04-07 18:22:24 +0200 | <haskellbridge> | <Bowuigi> Also can swapping "a" and "b" in a tree like "((((a ...) ...) ...) b)" be written without accumulating parameters? |
2025-04-07 18:23:27 +0200 | peterbecich | (~Thunderbi@syn-047-229-123-186.res.spectrum.com) (Ping timeout: 246 seconds) |
2025-04-07 18:24:16 +0200 | ft | (~ft@p508db463.dip0.t-ipconnect.de) ft |
2025-04-07 18:25:33 +0200 | tzh | (~tzh@c-76-115-131-146.hsd1.or.comcast.net) |
2025-04-07 18:26:56 +0200 | ph88 | (~ph88@2a02:8109:9e26:c800:7176:23ec:c36b:f7da) |
2025-04-07 18:28:07 +0200 | <haskellbridge> | <Bowuigi> If you restrict everything to be used linearly, the number of nodes stays the same |
2025-04-07 18:30:35 +0200 | <SrPx> | Bowuigi: I've edited the SO question with an example. I think it will make it more clear |
2025-04-07 18:34:31 +0200 | <haskellbridge> | <Bowuigi> "(((i p) xs) ys) -> (xs (p ys))" is not a permutation tho, the "i" is removed |
2025-04-07 18:36:44 +0200 | <haskellbridge> | <Bowuigi> That's one less branch, not even the same number of constructors (4 leaves + 3 branches vs 3 leaves + 2 branches) |
2025-04-07 18:36:54 +0200 | acidjnk_new3 | (~acidjnk@p200300d6e71c4f1839a5a90aae0b2850.dip0.t-ipconnect.de) (Ping timeout: 260 seconds) |
2025-04-07 18:40:02 +0200 | <haskellbridge> | <Bowuigi> If you want to consider deletions and duplications too, having "map" pass the two branches and using fst and snd should replace at least both drops, copying left, copying right and swap |
2025-04-07 18:40:36 +0200 | lxsameer | (~lxsameer@Serene/lxsameer) (Ping timeout: 272 seconds) |
2025-04-07 18:40:42 +0200 | <haskellbridge> | <Bowuigi> Where copying left is "(a b) -> (a a)" and copying right is "(a b) -> (b b)" |
2025-04-07 18:43:06 +0200 | guest4952 | (~guest4952@94.7.208.44) |
2025-04-07 18:44:10 +0200 | sprotte24 | (~sprotte24@p200300d16f30f50054794865c50a74ee.dip0.t-ipconnect.de) |
2025-04-07 18:47:13 +0200 | peterbecich | (~Thunderbi@syn-047-229-123-186.res.spectrum.com) peterbecich |
2025-04-07 18:51:42 +0200 | chele | (~chele@user/chele) (Remote host closed the connection) |
2025-04-07 18:53:30 +0200 | <ski> | Digit : any natural number (non-negative / unsigned integer) can be written additively, as a sum of additive units (`1's), e.g. `3 = 1 + 1 + 1',`10 = 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1' (note that this also holds for `0', which is a sum of zero `1's) |
2025-04-07 18:56:10 +0200 | <ski> | Digit : otoh, `1' itself can not (talking only about natural numbers) be divided up further, any time we try, we get things like `1 = 0 + 0 + 1 + 0', where all but one term is `0', the neutral element of addition, which can always be added as another term to a sum, so we decide that this "doesn't count" (it's not interesting). so. regarding summing, `1' acts as an "atom", it's the smallest unit of addition, |
2025-04-07 18:56:16 +0200 | <ski> | which can't be further subdivided, apart from trivially (with the `0's), and every natural number is a sum of such units |
2025-04-07 18:57:34 +0200 | <EvanR> | 1 = -1 + 2 |
2025-04-07 18:57:52 +0200 | <ski> | "talking only about natural numbers" |
2025-04-07 19:00:00 +0200 | <ski> | Digit : now, the question is what happens with multiplication (considering, say, positive integers, for the time being). well, we have things like `18 = 2 * 3 * 3', dividing up positive integers into prime numbers (and, again, `1' is the product of zero such primes, it is the "empty product"), but, just as we before could add any number of `0' terms to a sum, here we can add any number of `1' factors to a |
2025-04-07 19:00:06 +0200 | <ski> | product. `5 = 1 * 1 * 5 * 1' is not an interesting multiplicative decomposition of the prime `5', so "doesn't count". (this is, again, because `1' is the multiplicative neutral element, multiplying with it doesn't change the result, just as adding a `0' doesn't change the result of a sum, which is why `0' didn't "count" above) |
2025-04-07 19:00:27 +0200 | <EvanR> | oh, Digit is a user you're responding to |
2025-04-07 19:00:33 +0200 | <ski> | yes |
2025-04-07 19:00:58 +0200 | guest4952 | (~guest4952@94.7.208.44) (Remote host closed the connection) |
2025-04-07 19:01:30 +0200 | Square2 | (~Square@user/square) Square |
2025-04-07 19:01:40 +0200 | <ski> | btw, it so happens that there's only way to additively decompose a natural number into `1's, you always get the same number of `1'. similarly, there's only one way to multiplicatively decompose a positive integer into prime numbers, if we disregard the ordering, we always get the same number of each constituent prime |
2025-04-07 19:04:58 +0200 | Square | (~Square4@user/square) (Ping timeout: 245 seconds) |
2025-04-07 19:05:06 +0200 | <ski> | Digit : here's another way to think of it, related to divisibility (a number is a divisor of another number, if and only if the second number is a multiple of the first, is some integer times the first one). note that `5' divides `60 = 6 * 10', but `5' already divides one of the factors here (namely `10'). this is because `5' is "indivisible", we can't have one factor of `5' dividing `6' and the remaining |
2025-04-07 19:05:12 +0200 | <ski> | factor dividing `10' (apart from the trivial way `5 = 1 * 5', where `1' divides `6' and `5' divides `10' in `60 = 6 * 10', which "doesn't count", because this always holds) |
2025-04-07 19:07:59 +0200 | <ski> | Digit : otoh, `15' divides `60 = 6 * 10', but `15' doesn't divide either of `6' and `10', because `15 = 3 * 5', andd we have the first factor part, `3', dividing `6', and the second, `5', dividing `10'. because `6' is not a prime, if it divides a product, one factor part of it could divide one factor in the overall product, while another factor part of the non-prime could divide another factor of the overall |
2025-04-07 19:08:05 +0200 | <ski> | product |
2025-04-07 19:09:49 +0200 | <ski> | Digit : but this doesn't happen with primes. if `p' is a prime number, and it divides a product `a * b', then `p' has got to divide either `a', or `b'. you can easily see that this generalizes to a prime `p' dividing a product with any number of factors, `a * b * c * d' say, `p' must divide one of `a',`b',`c',`d' |
2025-04-07 19:11:42 +0200 | <ski> | Digit : now, the question is what happens for "degenerate products". what if we have a "product" of just one factor, so just `a'. if `p' divides this product, then it divides the (only) factor `a', so this works out fine. then, the "empty product", the product of a collection of zero factors, which is `1'. if `p' divides `1', then, if this above rule is to hold in this case, `p' has got to divide one of the |
2025-04-07 19:11:48 +0200 | <ski> | factors in this empty collection of factors .. which is impossible, it is empty ! |
2025-04-07 19:12:28 +0200 | peterbecich | (~Thunderbi@syn-047-229-123-186.res.spectrum.com) (Ping timeout: 245 seconds) |
2025-04-07 19:12:48 +0200 | <ski> | Digit : so .. if this rule "if a prime divides a product of factors, then it must divide one of the factors" is to hold in this "empty" product case, it must be that no prime `p' can divide the empty product, `1'. and because `1' divides itself, `1' can then not be a prime number |
2025-04-07 19:14:44 +0200 | <ski> | in the additive case, `5' can be further subdivided, as in e.g. `5 = 2 + 3'. and then `2 = 1 + 1' and `3 = 1 + 1 + 1', giving `5 = (1 + 1) + (1 + 1 + 1) = 1 + 1 + 1 + 1 + 1', going down to the "minimal units", the `1's. but `0' here is "nothing", it's the "empty sum", it's too small to be a unit to additively built numbers out of |
2025-04-07 19:15:40 +0200 | <ski> | similarly, in the multiplicative case, the prime numbers are the "units" which we can build up positive integers from, and `1' is "too small", is "nothing", is the "empty product", so it doesn't count |
2025-04-07 19:15:46 +0200 | <ski> | Digit : does this help ? |
2025-04-07 19:16:54 +0200 | acidjnk_new3 | (~acidjnk@p200300d6e71c4f1839a5a90aae0b2850.dip0.t-ipconnect.de) acidjnk |
2025-04-07 19:17:57 +0200 | ski | idly ponders a formulation of group set theory, where `{1} = {}', `1' being the neutral element of the group in question |
2025-04-07 19:21:10 +0200 | <EvanR> | "group set theory" |
2025-04-07 19:21:34 +0200 | tromp | (~textual@2001:1c00:3487:1b00:1419:ab0:498a:2d0c) (Quit: My iMac has gone to sleep. ZZZzzz…) |
2025-04-07 19:21:55 +0200 | <EvanR> | where sets are groups or groups are sets or |
2025-04-07 19:23:16 +0200 | <EvanR> | also good job proving that 1 is not prime via pure logic |
2025-04-07 19:23:27 +0200 | toby-bro | (~toby-bro@user/toby-bro) (Quit: WeeChat 3.8) |
2025-04-07 19:30:08 +0200 | wootehfoot | (~wootehfoo@user/wootehfoot) wootehfoot |
2025-04-07 19:36:18 +0200 | <ski> | no, a kind of set theory specialized to talk about subgroups of groups. where union of two subgroups is automatically the closure of the union of their respective underlying subsets |
2025-04-07 19:36:44 +0200 | <ski> | well, it was more like motivation, than proof .. |
2025-04-07 19:38:14 +0200 | fp | (~Thunderbi@2001:708:20:1406::1370) (Ping timeout: 272 seconds) |
2025-04-07 19:40:41 +0200 | tromp | (~textual@2001:1c00:3487:1b00:1419:ab0:498a:2d0c) |
2025-04-07 19:40:47 +0200 | peterbecich | (~Thunderbi@syn-047-229-123-186.res.spectrum.com) peterbecich |
2025-04-07 19:42:02 +0200 | <EvanR> | cool |
2025-04-07 19:46:03 +0200 | <kqr> | I have a pet project where I |
2025-04-07 19:46:08 +0200 | <kqr> | Oops, pressed return too soon. |
2025-04-07 19:49:41 +0200 | <kqr> | I have a pet project where I'm trying to make a term–document index in Haskell. I.e. I'm building a map/dictionary from tokens to indices. I'm testing this out on a 250 MB subset of the real data, and the map needs a resident 1.5 GB while it's being built. I've spent a lot of time trying to optimise this but now I'm running out of ideas. Is this 6× overhead within the range of reasonable |
2025-04-07 19:49:43 +0200 | <kqr> | overhead I should expect? |
2025-04-07 19:50:08 +0200 | lxsameer | (~lxsameer@Serene/lxsameer) lxsameer |
2025-04-07 19:52:22 +0200 | <geekosaur> | depends. iif you're using `String` then quite possibly yes. with `Text` you also need to use some care to avoid duplicating the entire input, I think (see https://downloads.haskell.org/ghc/latest/docs/libraries/text-2.1.2-84f9/Data-Text.html#v:copy) |
2025-04-07 19:53:20 +0200 | <geekosaur> | mm, no, that wouldn't cause extra copies of the backing `Text`, but it would keep the entire input alive unnecessarily |
2025-04-07 19:55:00 +0200 | tromp | (~textual@2001:1c00:3487:1b00:1419:ab0:498a:2d0c) (Quit: My iMac has gone to sleep. ZZZzzz…) |
2025-04-07 19:55:33 +0200 | peterbecich | (~Thunderbi@syn-047-229-123-186.res.spectrum.com) (Ping timeout: 248 seconds) |
2025-04-07 19:57:12 +0200 | <kqr> | I'm reading ByteStrings into (Document Int Text Text Text) values with Conduit. I /think/ that process is fairly efficient and constant in memory. |
2025-04-07 19:57:14 +0200 | tromp | (~textual@2001:1c00:3487:1b00:1419:ab0:498a:2d0c) |
2025-04-07 20:10:24 +0200 | jrm | (~jrm@user/jrm) jrm |
2025-04-07 20:11:39 +0200 | shane | (~shane@ana.rch.ist) (Ping timeout: 252 seconds) |
2025-04-07 20:13:07 +0200 | lxsameer | (~lxsameer@Serene/lxsameer) (Ping timeout: 268 seconds) |
2025-04-07 20:17:12 +0200 | acidjnk_new3 | (~acidjnk@p200300d6e71c4f1839a5a90aae0b2850.dip0.t-ipconnect.de) (Ping timeout: 246 seconds) |
2025-04-07 20:18:52 +0200 | <EvanR> | how many token keys do you end up with out of 250 MB |
2025-04-07 20:19:20 +0200 | <EvanR> | if it's order of 250 million, I say you got out luck with only 1.5 G |
2025-04-07 20:19:25 +0200 | <EvanR> | lucky |
2025-04-07 20:32:44 +0200 | amadaluzia | (~amadaluzi@2a00:23c7:ed8b:6701:fca7:4ddf:16d4:e0c7) (Quit: Hi, this is Paul Allen. I'm being called away to London for a few days. Meredith, I'll call you when I get back. Hasta la vista, baby.) |
2025-04-07 20:33:44 +0200 | amadaluzia | (~amadaluzi@2a00:23c7:ed8b:6701:3858:3fc1:f625:edbc) |
2025-04-07 20:34:25 +0200 | acidjnk_new3 | (~acidjnk@p200300d6e71c4f1839a5a90aae0b2850.dip0.t-ipconnect.de) acidjnk |
2025-04-07 20:35:25 +0200 | Tuplanolla | (~Tuplanoll@91-159-69-59.elisa-laajakaista.fi) Tuplanolla |
2025-04-07 20:35:57 +0200 | <kqr> | EvanR, I don't know exactly, but I |
2025-04-07 20:36:01 +0200 | <kqr> | again! |
2025-04-07 20:36:13 +0200 | amadaluzia | (~amadaluzi@2a00:23c7:ed8b:6701:3858:3fc1:f625:edbc) (Client Quit) |
2025-04-07 20:36:19 +0200 | <kqr> | EvanR, I don't know exactly, but I'm fairly certain it's less than 2.5 million |
2025-04-07 20:36:31 +0200 | <EvanR> | well if you print out the count in the end |
2025-04-07 20:36:33 +0200 | <EvanR> | you would know |
2025-04-07 20:37:08 +0200 | <EvanR> | a Map with 2 million keys would have a known lowerbound on memory |
2025-04-07 20:37:10 +0200 | amadaluzia | (~amadaluzi@host81-159-254-182.range81-159.btcentralplus.com) |
2025-04-07 20:37:16 +0200 | <EvanR> | 2 million times the heap size of a key |
2025-04-07 20:37:27 +0200 | <EvanR> | which will be several words |
2025-04-07 20:39:15 +0200 | <kqr> | Constructing the map from those 250 MB takes well over 30 minutes! So I'd rather not do that. But from a smaller subset (1/100th of that) I get 25 thousand, and a medium subset (1/10th) I get 95 thousand. so somewhere in the area of 1–2 million seems reasonable for the 250 MB |
2025-04-07 20:39:58 +0200 | <EvanR> | 30 minutes sounds like a bug |
2025-04-07 20:40:18 +0200 | <EvanR> | are you using strict Map |
2025-04-07 20:40:41 +0200 | <EvanR> | and forcing the evaluation of the latest Map at each step |
2025-04-07 20:41:42 +0200 | <kqr> | Strict map, yes. Forcing the evaluation, I think so. |
2025-04-07 20:42:08 +0200 | amadaluzia | (~amadaluzi@host81-159-254-182.range81-159.btcentralplus.com) (Quit: Hi, this is Paul Allen. I'm being called away to London for a few days. Meredith, I'll call you when I get back. Hasta la vista, baby.) |
2025-04-07 20:42:55 +0200 | <EvanR> | there's probably ways to optimize your thing, but I don't want to suggest any until the base performance from doing it "the dumbest possible way" is under control |
2025-04-07 20:43:04 +0200 | <EvanR> | otherwise you're optimizing the wrong thing |
2025-04-07 20:43:37 +0200 | amadaluzia | (~amadaluzi@2a00:23c7:ed8b:6701:a768:391e:7525:9f74) |
2025-04-07 20:44:47 +0200 | <kqr> | https://entropicthoughts.com/pastes/Index-3fa9c2.hs.html |
2025-04-07 20:45:08 +0200 | <kqr> | That's the dumest possible implementation of the index that I've come up with. |
2025-04-07 20:45:33 +0200 | pavonia | (~user@user/siracusa) siracusa |
2025-04-07 20:46:07 +0200 | <kqr> | So it's converting each document to its own index and then foldMaps together them into one index, mainly resting on the monoid instances of Map, IntMap, and IntSet. |
2025-04-07 20:46:14 +0200 | <kqr> | The data types are strict, the maps are strict, and the folds are strict. |
2025-04-07 20:49:31 +0200 | <EvanR> | I see addTerm is inserting 1 term |
2025-04-07 20:49:55 +0200 | <EvanR> | but are you iterating the <> operation between Indexes anywhere |
2025-04-07 20:50:31 +0200 | <kqr> | I'm not sure I understand the question. |
2025-04-07 20:50:53 +0200 | <EvanR> | are you using the <> operation anywhere at all |
2025-04-07 20:51:38 +0200 | <EvanR> | ok |
2025-04-07 20:51:44 +0200 | <EvanR> | foldlC (<>) mempty |
2025-04-07 20:52:15 +0200 | <kqr> | Yes, which is supposed to be a strict fold. And then later on I'm looking up terms in the termdoc map, and getting the corresponding document indices back |
2025-04-07 20:52:33 +0200 | <EvanR> | so you're relying on the union of all these maps being efficient enough to glom on millions of entries |
2025-04-07 20:52:45 +0200 | <EvanR> | instead of iterating the insertion of 1 at a time |
2025-04-07 20:53:26 +0200 | <EvanR> | in the case of list, [x] ++ biglist would be ok, while biglist ++ [x] would be bad |
2025-04-07 20:53:47 +0200 | <EvanR> | union of Maps and IntSets ... |
2025-04-07 20:54:35 +0200 | <EvanR> | looks like the listed cost is also asymmetric there |
2025-04-07 20:54:43 +0200 | <EvanR> | so you'd at least want to make sure you're doing them in the right order |
2025-04-07 20:55:24 +0200 | <EvanR> | oh, no in this case it's symmetric |
2025-04-07 20:55:40 +0200 | <kqr> | Yeah, it's the min of two numbers, where they are swapped depending on size |
2025-04-07 20:55:51 +0200 | <EvanR> | but inserting 1 at a time rather than unioning a singleton is probably a better idea |
2025-04-07 20:56:05 +0200 | <kqr> | I have tried that, but it didn't change anything about space or time characteristics |
2025-04-07 20:56:25 +0200 | <EvanR> | well |
2025-04-07 20:57:05 +0200 | <EvanR> | did you profile to see where the time is being spent |
2025-04-07 20:57:12 +0200 | <EvanR> | is it the index itself, or the analysis or |
2025-04-07 21:00:01 +0200 | caconym | (~caconym@user/caconym) (Quit: bye) |
2025-04-07 21:00:43 +0200 | caconym | (~caconym@user/caconym) caconym |
2025-04-07 21:00:50 +0200 | <kqr> | I have tried, but I'm having trouble interpreting the profiling data. I'll generate a fresh profile and see if I can get something out of it with fresh eyes. |
2025-04-07 21:04:46 +0200 | <kqr> | The cost centre <> on lines 21–22 in Index.hs (this is the TermDoc monoid implementation) costs 22 % of the time. Analysis 20 %. Those are the two major costs. (Then comes single-digit percents for UTF coding, un-gzipping the source data, etc. But that happens before index building) |
2025-04-07 21:07:25 +0200 | <kqr> | Though some of the latest changes I've made seem like they've made a difference. I could now build an index for the 250 MB of data in just two minutes. This is such a large difference that I'm half-expecting I've done something wrong at this point. |
2025-04-07 21:07:57 +0200 | JuanDaugherty | (~juan@user/JuanDaugherty) JuanDaugherty |
2025-04-07 21:08:49 +0200 | <kqr> | This is done with a resident set of 1.4 GB, which is certainly acceptable. I'm going to be brave and just try running it on the full 1.5 GB of data. |
2025-04-07 21:17:21 +0200 | m5zs7k | (aquares@web10.mydevil.net) (Ping timeout: 252 seconds) |
2025-04-07 21:20:47 +0200 | m5zs7k | (aquares@web10.mydevil.net) m5zs7k |
2025-04-07 21:24:21 +0200 | <EvanR> | dumb idea, do the indexing in stages by reading in 1.5 gigs, writing out a file of intermediate data, taking very little working memory to do so, repeat next stage, etc until you can read in the index itself |
2025-04-07 21:27:05 +0200 | <EvanR> | the less live memory the faster the ghc program runs |
2025-04-07 21:36:48 +0200 | target_i | (~target_i@user/target-i/x-6023099) target_i |
2025-04-07 21:38:57 +0200 | machinedgod | (~machinedg@d108-173-18-100.abhsia.telus.net) machinedgod |
2025-04-07 21:39:14 +0200 | m5zs7k | (aquares@web10.mydevil.net) (Ping timeout: 265 seconds) |
2025-04-07 21:42:02 +0200 | wootehfoot | (~wootehfoo@user/wootehfoot) (Read error: Connection reset by peer) |
2025-04-07 21:42:16 +0200 | m5zs7k | (aquares@web10.mydevil.net) m5zs7k |
2025-04-07 21:45:07 +0200 | ljdarj1 | (~Thunderbi@user/ljdarj) ljdarj |
2025-04-07 21:47:04 +0200 | rvalue- | (~rvalue@user/rvalue) rvalue |
2025-04-07 21:47:23 +0200 | ljdarj | (~Thunderbi@user/ljdarj) (Ping timeout: 244 seconds) |
2025-04-07 21:47:23 +0200 | ljdarj1 | ljdarj |
2025-04-07 21:47:33 +0200 | rvalue | (~rvalue@user/rvalue) (Ping timeout: 248 seconds) |
2025-04-07 21:48:04 +0200 | <[exa]> | kqr: what's the type of the Map exactly? It really sounds a lot like a data retrieval approach could work, so that you'd have mergeable index segments like Lucene does. That doesn't cost any internal memory at all and gets stupidly fast. |
2025-04-07 21:50:09 +0200 | <[exa]> | kqr: btw check what happens if you compile with `-O2 -fspecialise-aggressively -fexpose-all-unfoldings`, it might be the case that the polymorphism is hurting your performance there. |
2025-04-07 21:50:27 +0200 | <[exa]> | (in my case this made like 20x speed difference) |
2025-04-07 21:53:35 +0200 | <[exa]> | (nvm, /me found the type of the Map |
2025-04-07 21:53:37 +0200 | <[exa]> | ) |
2025-04-07 21:53:57 +0200 | rvalue- | rvalue |
2025-04-07 22:03:37 +0200 | Square | (~Square4@user/square) Square |
2025-04-07 22:06:36 +0200 | Square2 | (~Square@user/square) (Ping timeout: 252 seconds) |
2025-04-07 22:07:58 +0200 | sabino | (~sabino@user/sabino) (Quit: Lambda _ -> x) |
2025-04-07 22:19:59 +0200 | michalz | (~michalz@185.246.207.222) (Remote host closed the connection) |
2025-04-07 22:20:23 +0200 | tabaqui | (~tabaqui@167.71.80.236) (Ping timeout: 245 seconds) |
2025-04-07 22:28:06 +0200 | JuanDaugherty | (~juan@user/JuanDaugherty) (Quit: praxis.meansofproduction.biz (juan@acm.org)) |
2025-04-07 22:29:50 +0200 | sord937 | (~sord937@gateway/tor-sasl/sord937) (Quit: sord937) |
2025-04-07 22:31:53 +0200 | Unicorn_Princess | (~Unicorn_P@user/Unicorn-Princess/x-3540542) (Remote host closed the connection) |
2025-04-07 22:49:12 +0200 | <chiselfuse> | is `-5` a literal? |
2025-04-07 22:49:49 +0200 | <EvanR> | if you enable NegativeLiterals extension |
2025-04-07 22:50:12 +0200 | <EvanR> | otherwise it's negate 5 |
2025-04-07 22:52:51 +0200 | <haskellbridge> | <ozkutuk> though if you consider enabling it, LexicalNegation is more generally applicable compared to NegativeLiterals if you are on GHC >9 |
2025-04-07 22:57:51 +0200 | dhil | (~dhil@2a0c:b381:52e:3600:7599:e3a2:8d31:477d) (Ping timeout: 246 seconds) |
2025-04-07 22:59:57 +0200 | <EvanR> | > 1 -5 |
2025-04-07 22:59:58 +0200 | <lambdabot> | -4 |
2025-04-07 23:00:01 +0200 | <EvanR> | I lied |
2025-04-07 23:03:33 +0200 | target_i | (~target_i@user/target-i/x-6023099) (Quit: leaving) |
2025-04-07 23:13:36 +0200 | hiredman | (~hiredman@frontier1.downey.family) hiredman |
2025-04-07 23:15:12 +0200 | <chiselfuse> | So it's by default a unary function? if so then how can i check it's type? i tried `:t (-)` but it shows me the type of the binary function |
2025-04-07 23:17:22 +0200 | <chiselfuse> | does this mean that i can have two `foo`s? one defined as a binary function and another defined as a unary function. with the right one used depending on context? |
2025-04-07 23:17:34 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) merijn |
2025-04-07 23:17:44 +0200 | <chiselfuse> | so like i `x = foo 5` would use the unary definition and `foo 3 5` would use the binary one? |
2025-04-07 23:18:16 +0200 | <chiselfuse> | hmm wait. `foo 5` should be partial application |
2025-04-07 23:21:25 +0200 | amadaluzia_ | (~amadaluzi@2a00:23c7:ed8b:6701:e287:4eed:50df:f686) |
2025-04-07 23:21:25 +0200 | amadaluzia | (~amadaluzi@2a00:23c7:ed8b:6701:a768:391e:7525:9f74) (Ping timeout: 248 seconds) |
2025-04-07 23:22:04 +0200 | <geekosaur> | unary minus is a parser hack |
2025-04-07 23:22:13 +0200 | gorignak | (~gorignak@user/gorignak) gorignak |
2025-04-07 23:22:21 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) (Ping timeout: 246 seconds) |
2025-04-07 23:33:21 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) merijn |
2025-04-07 23:33:49 +0200 | peterbecich | (~Thunderbi@syn-047-229-123-186.res.spectrum.com) peterbecich |
2025-04-07 23:37:01 +0200 | <EvanR> | chiselfuse, we don't have binary functions |
2025-04-07 23:38:54 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) (Ping timeout: 272 seconds) |
2025-04-07 23:39:53 +0200 | <chiselfuse> | oh yea it's all lambdas i forgot |
2025-04-07 23:43:24 +0200 | <EvanR> | > 5-----5 |
2025-04-07 23:43:26 +0200 | <lambdabot> | 5 |
2025-04-07 23:44:33 +0200 | <mauke> | is that a comment? |
2025-04-07 23:44:38 +0200 | <yin> | yes |
2025-04-07 23:44:45 +0200 | <EvanR> | lol |
2025-04-07 23:48:18 +0200 | peterbecich | (~Thunderbi@syn-047-229-123-186.res.spectrum.com) (Ping timeout: 245 seconds) |
2025-04-07 23:49:08 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) merijn |
2025-04-07 23:49:47 +0200 | <yin> | chiselfuse: there's Prelude.subtract if you want to disambiguate |
2025-04-07 23:49:52 +0200 | <yin> | :t subtract |
2025-04-07 23:49:53 +0200 | <lambdabot> | Num a => a -> a -> a |
2025-04-07 23:50:03 +0200 | <EvanR> | @src subtract |
2025-04-07 23:50:03 +0200 | <lambdabot> | subtract x y = y - x |
2025-04-07 23:50:31 +0200 | <haskellbridge> | <Profpatsch> Haskal amirite |
2025-04-07 23:50:55 +0200 | <int-e> | > (-1+) 4 |
2025-04-07 23:50:56 +0200 | <lambdabot> | 3 |
2025-04-07 23:51:24 +0200 | <EvanR> | wot |
2025-04-07 23:51:47 +0200 | <yin> | int-e: damn this reminds me of lisp |
2025-04-07 23:51:55 +0200 | <geekosaur> | heh |
2025-04-07 23:51:58 +0200 | <haskellbridge> | <Profpatsch> ((-1)+) |
2025-04-07 23:52:03 +0200 | <haskellbridge> | <Profpatsch> operator sections |
2025-04-07 23:52:21 +0200 | <haskellbridge> | <Profpatsch> at least not Scala postfix operators |
2025-04-07 23:52:40 +0200 | <chiselfuse> | yin: so by default (no extensions etc) `-` means either `negate` or `subtract` depending on context? |
2025-04-07 23:52:56 +0200 | <chiselfuse> | i guess i can do :t negate then |
2025-04-07 23:53:25 +0200 | <int-e> | the best part about this is that hugs and ghc disagree on which one of (-1+) or (+ -1) is valid. |
2025-04-07 23:54:30 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) (Ping timeout: 268 seconds) |
2025-04-07 23:54:44 +0200 | <chiselfuse> | what is (-1+)? is it `+` partially applied on `-1`? |
2025-04-07 23:55:35 +0200 | <geekosaur> | yes |
2025-04-07 23:57:35 +0200 | <EvanR> | > 5 - -5 |
2025-04-07 23:57:36 +0200 | <lambdabot> | error: |
2025-04-07 23:57:36 +0200 | <lambdabot> | Precedence parsing error |
2025-04-07 23:57:36 +0200 | <lambdabot> | cannot mix ‘-’ [infixl 6] and prefix `-' [infixl 6] in the same infi... |
2025-04-07 23:57:52 +0200 | <EvanR> | chiselfuse, if it means anything |
2025-04-07 23:58:00 +0200 | tuxillo | (~Thunderbi@131.pool85-57-245.dynamic.orange.es) tuxillo |
2025-04-07 23:58:04 +0200 | <tuxillo> | hiyo |
2025-04-07 23:58:38 +0200 | <tuxillo> | in DragonFly BSD we have a program that reports this? https://termbin.com/ybc7 |
2025-04-07 23:58:48 +0200 | <tuxillo> | how do I debug if it's a ghc problem in this platform? |