Newest at the top
| 2025-12-28 06:41:16 +0100 | rekahsoft | (~rekahsoft@70.51.99.245) rekahsoft |
| 2025-12-28 06:41:11 +0100 | <iqubic> | Yeah, I get what you mean. |
| 2025-12-28 06:40:46 +0100 | <ski> | btw, sometimes it makes sense to make a function from a record-of-operations, to another (possibly existential) record-of-operations. this being one way to do something similar to the parameterized modules in the module system of the MLs (SML,OCaml) (cf. Backpack) |
| 2025-12-28 06:40:43 +0100 | rekahsoft | (~rekahsoft@70.51.99.245) (Remote host closed the connection) |
| 2025-12-28 06:39:28 +0100 | <ski> | yea, sounds like record of operations is more sensible, then |
| 2025-12-28 06:39:17 +0100 | <iqubic> | Essentially, I'm trying to model simple combinatorial games like "nim" where I can write a function like "nextMoves :: a -> [a]", but then I realized that different games might have the type for the state variable. |
| 2025-12-28 06:37:35 +0100 | <haskellbridge> | <slack1256> Record of functions can be used everywhere else. Most importantly where the provenance is a deciding factor on what the functions should do, not just the type. This is a fine concept, these records of functions are modules as ocaml sense |
| 2025-12-28 06:37:15 +0100 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 240 seconds) |
| 2025-12-28 06:36:56 +0100 | <iqubic> | The more I actually think about this, the more it makes sense to use a record of functions. |
| 2025-12-28 06:36:37 +0100 | <iqubic> | In the thing that I'm modelling, the same type could very easily have different implementations. And I don't want to jump through newtype wrappers like Sum and Product for the two different Monoids over integers. |
| 2025-12-28 06:32:32 +0100 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn |
| 2025-12-28 06:32:22 +0100 | <ski> | yea, you also most likely should not be making a type class, unless you already have at least two different instances in mind |
| 2025-12-28 06:31:31 +0100 | <haskellbridge> | <slack1256> In summary, you had abstraction power via laws or you had a simple model ln the instances |
| 2025-12-28 06:31:18 +0100 | <ski> | does the type determine a canonical instance ? or would it make sense to want to pass different records, at different times, for the same type ? |
| 2025-12-28 06:30:52 +0100 | <haskellbridge> | <slack1256> The second case was that the class admitted obvious instances. For example show and read. Foldable was obvious even if kind of adhoc because `toList` was the only real method and everything else was a more efficient way to avoid the conversion to lists. |
| 2025-12-28 06:29:31 +0100 | spew | (~spew@user/spew) (Quit: nyaa~) |
| 2025-12-28 06:29:23 +0100 | <haskellbridge> | <slack1256> Iqubic: the standard answer some years ago was that if you could give "algebraic laws" relating the operations between themselves or super classes you were in the right path |
| 2025-12-28 06:05:55 +0100 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 246 seconds) |
| 2025-12-28 06:03:27 +0100 | <iqubic> | I have a Haskell design question. How do I decide if I should make a typeclass to describe a particular constraint or just use and pass around a record of functions. |
| 2025-12-28 06:01:20 +0100 | iqubic | (~sophia@2601:602:9203:1660:c40f:f996:91cc:d34) iqubic |
| 2025-12-28 06:01:16 +0100 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn |
| 2025-12-28 05:55:39 +0100 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 250 seconds) |
| 2025-12-28 05:51:08 +0100 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn |
| 2025-12-28 05:49:31 +0100 | Pozyomka | (~pyon@user/pyon) (Quit: bbl) |
| 2025-12-28 05:40:07 +0100 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 240 seconds) |
| 2025-12-28 05:35:22 +0100 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn |
| 2025-12-28 05:28:25 +0100 | Hafydd | (~Hafydd@user/hafydd) Hafydd |
| 2025-12-28 05:24:15 +0100 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 240 seconds) |
| 2025-12-28 05:19:35 +0100 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn |
| 2025-12-28 05:15:25 +0100 | <monochrom> | oh heh |
| 2025-12-28 05:14:21 +0100 | <Leary> | (turns out I'd forgotten to wait on forked threads, so criterion was measuring a load of nonsense) |
| 2025-12-28 05:08:19 +0100 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 260 seconds) |
| 2025-12-28 05:07:52 +0100 | <monochrom> | But if variance is negative, that's severely deflated or imploded, not inflated. >:) |
| 2025-12-28 05:06:37 +0100 | <Leary> | Or that. |
| 2025-12-28 05:06:30 +0100 | <lambdabot> | -9223372036854775808 |
| 2025-12-28 05:06:29 +0100 | <Leary> | > minBound :: Int |
| 2025-12-28 05:06:16 +0100 | <monochrom> | That. :) |
| 2025-12-28 05:06:12 +0100 | <lambdabot> | 9223372036854775808 |
| 2025-12-28 05:06:11 +0100 | <monochrom> | > 2^63 |
| 2025-12-28 05:04:27 +0100 | <monochrom> | That number looks awfully familar. |
| 2025-12-28 05:01:32 +0100 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn |
| 2025-12-28 04:50:46 +0100 | Hafydd | (~Hafydd@user/hafydd) (Quit: WeeChat 4.8.1) |
| 2025-12-28 04:50:15 +0100 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 240 seconds) |
| 2025-12-28 04:45:46 +0100 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn |
| 2025-12-28 04:40:19 +0100 | <Leary> | Thanks, criterion. |
| 2025-12-28 04:40:15 +0100 | <Leary> | "variance introduced by outliers: -9223372036854775808% (severely inflated)" |
| 2025-12-28 04:35:01 +0100 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 244 seconds) |
| 2025-12-28 04:29:57 +0100 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) merijn |
| 2025-12-28 04:22:03 +0100 | ttybitnik | (~ttybitnik@user/wolper) (Quit: Fading out...) |
| 2025-12-28 04:18:55 +0100 | merijn | (~merijn@host-cl.cgnat-g.v4.dfn.nl) (Ping timeout: 240 seconds) |