Newest at the top
2025-04-28 23:31:43 +0200 | <darkling> | (There's an entire plot thread in a couple of Trollope's books about that, 120 years before they actually did it). |
2025-04-28 23:31:43 +0200 | <EvanR> | use unary floating point |
2025-04-28 23:31:07 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) (Ping timeout: 265 seconds) |
2025-04-28 23:30:56 +0200 | <darkling> | For extra fun, consider pre-decimalisation British coinage (240 pence / pound; fractions down to 1/4p, so 960 farthings to the pound)... and then the transition to decimalised currency. :) |
2025-04-28 23:27:53 +0200 | <monochrom> | I don't know. But I start with: How do I express one half in unary? |
2025-04-28 23:27:02 +0200 | <davean> | monochrom: wouldn't unary be better? |
2025-04-28 23:26:11 +0200 | <c_wraith> | I suppose given that context, USD uses 1000ths of a dollar in order to make a ha'penny an actual value they can issue. |
2025-04-28 23:25:28 +0200 | tromp | (~textual@2001:1c00:3487:1b00:b5bd:9efd:97f5:64ad) (Quit: My iMac has gone to sleep. ZZZzzz…) |
2025-04-28 23:25:25 +0200 | justsomeguy | (~justsomeg@user/justsomeguy) justsomeguy |
2025-04-28 23:23:40 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) merijn |
2025-04-28 23:23:21 +0200 | <monochrom> | (I don't mean the law were written in the 17th century. But the law just codifies a long tradition that began back then.) |
2025-04-28 23:22:08 +0200 | <monochrom> | s/written is/written into/ |
2025-04-28 23:21:53 +0200 | <monochrom> | The financial sector uses base 10 for fractions, and it is written is the law and too late to change. (You need to go back to say the 17th century to change it.) However, for all other purposes, Knuth proved that rounding errors are less bad iff the base is smaller, therefore base 2 is the least bad. |
2025-04-28 23:20:24 +0200 | <haskellbridge> | <Liamzee> https://hackage-content.haskell.org/package/inline-python-0.1.1.1 |
2025-04-28 23:18:48 +0200 | <EvanR> | inline python it is |
2025-04-28 23:17:28 +0200 | <c_wraith> | good. that's the best lesson here. :) |
2025-04-28 23:16:45 +0200 | <Square2> | c_wraith, EvanR thanks. You convinced me I should just try avoid this situation =D |
2025-04-28 23:15:13 +0200 | tolgo | (~Thunderbi@199.115.144.130) (Ping timeout: 276 seconds) |
2025-04-28 23:15:10 +0200 | ljdarj1 | (~Thunderbi@user/ljdarj) (Ping timeout: 265 seconds) |
2025-04-28 23:14:06 +0200 | ljdarj | (~Thunderbi@user/ljdarj) ljdarj |
2025-04-28 23:13:44 +0200 | ljdarj | (~Thunderbi@user/ljdarj) (Ping timeout: 245 seconds) |
2025-04-28 23:12:58 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) (Ping timeout: 252 seconds) |
2025-04-28 23:10:38 +0200 | ljdarj1 | (~Thunderbi@user/ljdarj) ljdarj |
2025-04-28 23:08:53 +0200 | justsomeguy | (~justsomeg@user/justsomeguy) (Ping timeout: 265 seconds) |
2025-04-28 23:08:28 +0200 | shapr | (~user@2600:4040:5c49:5600:dfc0:98d5:78c7:1853) shapr |
2025-04-28 23:08:08 +0200 | m5zs7k | (aquares@web10.mydevil.net) m5zs7k |
2025-04-28 23:08:01 +0200 | tolgo | (~Thunderbi@199.115.144.130) |
2025-04-28 23:07:53 +0200 | merijn | (~merijn@host-vr.cgnat-g.v4.dfn.nl) merijn |
2025-04-28 23:07:33 +0200 | <c_wraith> | But yeah, the whole thing is... Really hoping there's a better way. |
2025-04-28 23:06:51 +0200 | <c_wraith> | In generaly, you'd probably want (:~:) so you could actually write code that knows the types are the same by matching on Refl |
2025-04-28 23:06:16 +0200 | <EvanR> | gross |
2025-04-28 23:06:02 +0200 | <lambdabot> | (Typeable a1, Typeable a2) => a1 -> a2 -> Bool |
2025-04-28 23:06:01 +0200 | <c_wraith> | :t \x y -> typeOf x == typeOf y -- this just isn't the same thing as a MPTC |
2025-04-28 23:05:49 +0200 | <EvanR> | there's that type equality test class |
2025-04-28 23:05:38 +0200 | m5zs7k | (aquares@web10.mydevil.net) (Ping timeout: 252 seconds) |
2025-04-28 23:05:24 +0200 | <c_wraith> | But it isn't quite the same thing as giving you a *value* |
2025-04-28 23:05:12 +0200 | <EvanR> | there you go |
2025-04-28 23:05:06 +0200 | <c_wraith> | EvanR: That class already exists and is named (~) |
2025-04-28 23:04:43 +0200 | <EvanR> | but a multiparameter type class |
2025-04-28 23:04:42 +0200 | <c_wraith> | Yeah, in general seeing Typeable should make you go "is there a better way?" |
2025-04-28 23:04:24 +0200 | <EvanR> | if you aren't comparing the values then it doesn't need to be a function |
2025-04-28 23:04:10 +0200 | dhil | (~dhil@5.151.29.138) (Ping timeout: 252 seconds) |
2025-04-28 23:03:42 +0200 | <EvanR> | er |
2025-04-28 23:03:42 +0200 | <Square2> | ah ok. I feel I'm out in the hack suburb, may need to rethink stuff. |
2025-04-28 23:03:31 +0200 | j1n37 | (~j1n37@user/j1n37) j1n37 |
2025-04-28 23:03:25 +0200 | <haskellbridge> | <Liamzee> you don't actually need an Eq instance if they're... oh wait, that's manual implementation of Eq |
2025-04-28 23:03:19 +0200 | j1n37- | (~j1n37@user/j1n37) (Ping timeout: 260 seconds) |
2025-04-28 23:03:17 +0200 | <c_wraith> | EvanR: I read the question as being about "if the types are the same", not "if the values are the same" |
2025-04-28 23:02:43 +0200 | <EvanR> | that has an Eq instance |
2025-04-28 23:02:39 +0200 | <EvanR> | or if they were coercible to a common type |