2024-12-21 00:00:34 +0100 | Smiles | (uid551636@id-551636.lymington.irccloud.com) (Quit: Connection closed for inactivity) |
2024-12-21 00:05:55 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 00:10:42 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 265 seconds) |
2024-12-21 00:11:12 +0100 | remexre | (~remexre@user/remexre) (Remote host closed the connection) |
2024-12-21 00:13:32 +0100 | machinedgod | (~machinedg@d108-173-18-100.abhsia.telus.net) machinedgod |
2024-12-21 00:16:46 +0100 | fmira | (~user@user/fmira) (Quit: fmira) |
2024-12-21 00:18:26 +0100 | <jle`> | has anyone noticed that the Quick Jump on haddocks hasn't seem to worked for like a year or something |
2024-12-21 00:18:35 +0100 | <jle`> | on hackage |
2024-12-21 00:19:59 +0100 | <jackdk> | For some strange reason, it continues to work once you're inside a module's documentation. |
2024-12-21 00:21:17 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 00:21:51 +0100 | <glguy> | jle`: I find it doesn't work on packages that haven't been updated |
2024-12-21 00:22:01 +0100 | <glguy> | but otherwise I use it whenever I'm on hackage |
2024-12-21 00:25:46 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 252 seconds) |
2024-12-21 00:26:49 +0100 | <jle`> | oh i didn't even realize you could access it from module documentation |
2024-12-21 00:27:03 +0100 | <jle`> | that's a nice workaround at least |
2024-12-21 00:29:37 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 00:32:02 +0100 | ash3en | (~Thunderbi@2a03:7846:b6eb:101:93ac:a90a:da67:f207) (Quit: ash3en) |
2024-12-21 00:34:09 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 248 seconds) |
2024-12-21 00:39:06 +0100 | wootehfoot | (~wootehfoo@user/wootehfoot) (Read error: Connection reset by peer) |
2024-12-21 00:45:49 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 00:53:43 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 265 seconds) |
2024-12-21 00:55:00 +0100 | alexherbo2 | (~alexherbo@2a02-8440-3502-b49c-c41e-bf6a-4195-2af5.rev.sfr.net) (Remote host closed the connection) |
2024-12-21 00:55:21 +0100 | alexherbo2 | (~alexherbo@2a02-8440-3502-b49c-c1d1-ea55-d74a-1dc7.rev.sfr.net) alexherbo2 |
2024-12-21 00:59:00 +0100 | alexherbo2 | (~alexherbo@2a02-8440-3502-b49c-c1d1-ea55-d74a-1dc7.rev.sfr.net) (Remote host closed the connection) |
2024-12-21 01:00:54 +0100 | <hellwolf> | fmap fromJust (filter isJust (fmap ifunc_name sfns)) <-- can it be simplified |
2024-12-21 01:02:40 +0100 | <jackdk> | :t Data.Maybe.mapMaybe -- generalised by package `witherable` |
2024-12-21 01:02:41 +0100 | <lambdabot> | (a -> Maybe b) -> [a] -> [b] |
2024-12-21 01:02:45 +0100 | <Leary> | hellwolf: `mapMaybe ifunc_name sfns`? Even if `mapMaybe` didn't exist, you should invent it before you throw `fromJust` at your problem. |
2024-12-21 01:03:33 +0100 | <probie> | :t \ifunc_name sfns -> [x | Just x <- map ifunc_name sfns] |
2024-12-21 01:03:40 +0100 | <lambdabot> | (a1 -> Maybe a2) -> [a1] -> [a2] |
2024-12-21 01:04:37 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 01:04:37 +0100 | <hellwolf> | catMaybes |
2024-12-21 01:04:38 +0100 | <probie> | > let halfEven x = if even x then Just (x `div` 2) else Nothing in [x | Just x <- map halfEven [1..10]] |
2024-12-21 01:04:39 +0100 | <hellwolf> | :t catMaybes |
2024-12-21 01:04:41 +0100 | <lambdabot> | [1,2,3,4,5] |
2024-12-21 01:04:41 +0100 | <lambdabot> | [Maybe a] -> [a] |
2024-12-21 01:04:54 +0100 | <hellwolf> | that's the one |
2024-12-21 01:05:49 +0100 | <probie> | > let halfEven x = if even x then Just (x `div` 2) else Nothing in catMaybes (map halfEven [1..10]) |
2024-12-21 01:05:50 +0100 | <lambdabot> | [1,2,3,4,5] |
2024-12-21 01:07:19 +0100 | <jackdk> | fromJust is way less useful than it seems, once you get used to using Functor/Applicative and sometimes Monad operations over Maybes. |
2024-12-21 01:09:15 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 246 seconds) |
2024-12-21 01:12:49 +0100 | sawilagar | (~sawilagar@user/sawilagar) (Ping timeout: 252 seconds) |
2024-12-21 01:17:31 +0100 | L29Ah | (~L29Ah@wikipedia/L29Ah) L29Ah |
2024-12-21 01:20:21 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 01:24:51 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 244 seconds) |
2024-12-21 01:35:45 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 01:36:25 +0100 | Smiles | (uid551636@id-551636.lymington.irccloud.com) Smiles |
2024-12-21 01:37:08 +0100 | peterbecich | (~Thunderbi@syn-047-229-123-186.res.spectrum.com) peterbecich |
2024-12-21 01:40:17 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 248 seconds) |
2024-12-21 01:41:06 +0100 | weary-traveler | (~user@user/user363627) user363627 |
2024-12-21 01:42:32 +0100 | weary-traveler | (~user@user/user363627) (Remote host closed the connection) |
2024-12-21 01:44:37 +0100 | weary-traveler | (~user@user/user363627) user363627 |
2024-12-21 01:45:11 +0100 | CrunchyFlakes | (~CrunchyFl@31.19.233.78) (Read error: Connection reset by peer) |
2024-12-21 01:46:55 +0100 | CrunchyFlakes | (~CrunchyFl@31.19.233.78) |
2024-12-21 01:46:55 +0100 | <jle`> | yeah the "point" of Maybe is that you don't have to use fromJust, you would always be able to pattern match |
2024-12-21 01:48:46 +0100 | <monochrom> | @quote monochrom safeFromJust |
2024-12-21 01:48:47 +0100 | <lambdabot> | monochrom says: I use safeFromJust :: Maybe a -> Maybe a |
2024-12-21 01:49:06 +0100 | cheater | (~Username@user/cheater) (Quit: Going offline, see ya! (www.adiirc.com)) |
2024-12-21 01:49:19 +0100 | <jle`> | safeHead . maybeToList |
2024-12-21 01:51:19 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 01:52:27 +0100 | <hellwolf> | project_preamble_template :: T.Text |
2024-12-21 01:52:27 +0100 | <hellwolf> | project_preamble_template = [fmt'| |
2024-12-21 01:52:27 +0100 | <hellwolf> | #include "../../../templates/Preamble.sol" |
2024-12-21 01:52:27 +0100 | <hellwolf> | |] |
2024-12-21 01:52:44 +0100 | <hellwolf> | I use CPP extension, but it filters out all my "/* comments */" in the included file |
2024-12-21 01:52:49 +0100 | <hellwolf> | sad |
2024-12-21 01:54:10 +0100 | <geekosaur> | mm, I thought the way we invoke cpp disables that because it's inapplicable to Haskell code. clang, perhaps? |
2024-12-21 01:54:40 +0100 | <ski> | > (\f xs -> [y | my <- map f xs,y <- maybeToList my]) (\n -> guard (even n) >> Just (n `div` 2)) [0,1,2,3,4] |
2024-12-21 01:54:41 +0100 | <hellwolf> | maybe I am using it in a inconventional way |
2024-12-21 01:54:42 +0100 | <lambdabot> | [0,1,2] |
2024-12-21 01:54:45 +0100 | <ski> | @type \f xs -> [y | my <- map f xs,y <- maybeToList my] |
2024-12-21 01:54:46 +0100 | <lambdabot> | (a1 -> Maybe a2) -> [a1] -> [a2] |
2024-12-21 01:55:06 +0100 | <geekosaur> | if you're using it the default way, it strips comments |
2024-12-21 01:55:16 +0100 | <hellwolf> | I include a chunk of file into a QQ. |
2024-12-21 01:55:30 +0100 | <hellwolf> | actually I would like it to keep the comments |
2024-12-21 01:55:42 +0100 | <geekosaur> | if you're using it as ghc configures it via the CPP extension and you're not on a Mac, it should use `-traditional` and disable comment stripping |
2024-12-21 01:55:46 +0100 | <hellwolf> | what is my alternative, that can include such a template file in a distribution. |
2024-12-21 01:55:48 +0100 | housemate | (~housemate@ppp203-122-213-191.static.internode.on.net) housemate |
2024-12-21 01:55:57 +0100 | housemate | (~housemate@ppp203-122-213-191.static.internode.on.net) (Remote host closed the connection) |
2024-12-21 01:55:59 +0100 | <hellwolf> | oh? how to enable -traditional |
2024-12-21 01:56:08 +0100 | <geekosaur> | if you're on a Mac, you're getting clang instead of gcc and your cpp will strip things and can't be told not to |
2024-12-21 01:56:20 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 252 seconds) |
2024-12-21 01:56:24 +0100 | <geekosaur> | gcc -E -traditional |
2024-12-21 01:56:29 +0100 | <hellwolf> | platform dependent... hmm, better not |
2024-12-21 01:56:53 +0100 | <hellwolf> | alternative is that I should not use CPP, but create QQ in a normal hs file |
2024-12-21 01:56:59 +0100 | <hellwolf> | I think I should do that |
2024-12-21 01:57:06 +0100 | <hellwolf> | this CPP usage is too weird. |
2024-12-21 01:57:16 +0100 | <hellwolf> | probably will bring distribution problem later. |
2024-12-21 01:57:23 +0100 | <hellwolf> | (need to set Cabal extra files) |
2024-12-21 01:58:57 +0100 | machinedgod | (~machinedg@d108-173-18-100.abhsia.telus.net) (Ping timeout: 244 seconds) |
2024-12-21 02:01:59 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 02:03:54 +0100 | <monochrom> | I'm also very naughty and known to say: |
2024-12-21 02:04:01 +0100 | <monochrom> | @quote monochrom unsafeCoerce |
2024-12-21 02:04:01 +0100 | <lambdabot> | monochrom says: isTrue = (unsafeCoerce :: Either a b -> Bool) . (unsafeCoerce :: Maybe c -> Either a b) . (unsafeCoerce :: Bool -> Maybe c) |
2024-12-21 02:04:05 +0100 | <monochrom> | >:) |
2024-12-21 02:06:42 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 265 seconds) |
2024-12-21 02:08:49 +0100 | <jle`> | monochrom: hm, why do you need all three? |
2024-12-21 02:10:17 +0100 | <monochrom> | To flex. >:) |
2024-12-21 02:11:21 +0100 | <monochrom> | The chain enjoys round-trip pointer tagging invariance. >:) |
2024-12-21 02:11:51 +0100 | sprotte24 | (~sprotte24@p200300d16f0b5c0044534d8048ff44db.dip0.t-ipconnect.de) (Read error: Connection reset by peer) |
2024-12-21 02:12:45 +0100 | harveypwca | (~harveypwc@2601:246:d080:b40:1889:d9bf:2dd8:b288) HarveyPwca |
2024-12-21 02:13:37 +0100 | <jle`> | ah of course |
2024-12-21 02:14:17 +0100 | acidjnk_new | (~acidjnk@p200300d6e7283f13051c8d0c2a2bb459.dip0.t-ipconnect.de) (Ping timeout: 252 seconds) |
2024-12-21 02:17:22 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 02:19:15 +0100 | <geekosaur> | hellwolf, there is also the possibility of a build-depends: cpphs, but I would avoid cpp's cursedness if possible |
2024-12-21 02:19:20 +0100 | machinedgod | (~machinedg@d108-173-18-100.abhsia.telus.net) machinedgod |
2024-12-21 02:21:59 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 252 seconds) |
2024-12-21 02:27:04 +0100 | housemate | (~housemate@ppp203-122-213-191.static.internode.on.net) housemate |
2024-12-21 02:29:01 +0100 | housemate | (~housemate@ppp203-122-213-191.static.internode.on.net) (Remote host closed the connection) |
2024-12-21 02:32:44 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 02:35:06 +0100 | alp | (~alp@2001:861:8ca0:4940:bd95:640a:d817:df55) |
2024-12-21 02:35:57 +0100 | Tuplanolla | (~Tuplanoll@91-159-69-59.elisa-laajakaista.fi) (Quit: Leaving.) |
2024-12-21 02:37:21 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 248 seconds) |
2024-12-21 02:48:07 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 02:51:15 +0100 | kimiamania | (~65804703@user/kimiamania) (Quit: PegeLinux) |
2024-12-21 02:52:28 +0100 | kimiamania | (~65804703@user/kimiamania) kimiamania |
2024-12-21 02:54:46 +0100 | OftenFaded | (~OftenFade@user/tisktisk) OftenFaded |
2024-12-21 02:55:00 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 252 seconds) |
2024-12-21 03:05:02 +0100 | harveypwca | (~harveypwc@2601:246:d080:b40:1889:d9bf:2dd8:b288) (Quit: Leaving) |
2024-12-21 03:05:04 +0100 | housemate | (~housemate@1.125.109.132) housemate |
2024-12-21 03:10:48 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 03:12:26 +0100 | haritz | (~hrtz@2a02:8010:65b5:0:5d9a:9bab:ee5e:b737) |
2024-12-21 03:12:28 +0100 | haritz | (~hrtz@2a02:8010:65b5:0:5d9a:9bab:ee5e:b737) (Changing host) |
2024-12-21 03:12:28 +0100 | haritz | (~hrtz@user/haritz) haritz |
2024-12-21 03:15:10 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 252 seconds) |
2024-12-21 03:17:34 +0100 | rekahsoft | (~rekahsoft@76.69.85.220) (Remote host closed the connection) |
2024-12-21 03:18:54 +0100 | krei-se- | (~krei-se@p5085d4a6.dip0.t-ipconnect.de) krei-se |
2024-12-21 03:19:56 +0100 | krei-se | (~krei-se@p5085d4fd.dip0.t-ipconnect.de) (Ping timeout: 252 seconds) |
2024-12-21 03:26:11 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 03:30:48 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 265 seconds) |
2024-12-21 03:32:22 +0100 | rekahsoft | (~rekahsoft@76.69.85.220) rekahsoft |
2024-12-21 03:32:33 +0100 | anpad | (~pandeyan@user/anpad) (Quit: ZNC 1.8.2 - https://znc.in) |
2024-12-21 03:32:54 +0100 | prasad | (~Thunderbi@c-73-75-25-251.hsd1.in.comcast.net) (Ping timeout: 276 seconds) |
2024-12-21 03:38:31 +0100 | anpad | (~pandeyan@user/anpad) anpad |
2024-12-21 03:41:33 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 03:43:51 +0100 | housemate | (~housemate@1.125.109.132) (Ping timeout: 265 seconds) |
2024-12-21 03:45:29 +0100 | Smiles | (uid551636@id-551636.lymington.irccloud.com) (Quit: Connection closed for inactivity) |
2024-12-21 03:45:58 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 252 seconds) |
2024-12-21 03:50:31 +0100 | peterbecich | (~Thunderbi@syn-047-229-123-186.res.spectrum.com) (Ping timeout: 264 seconds) |
2024-12-21 03:51:51 +0100 | housemate | (~housemate@246.224.218.139.sta.wbroadband.net.au) housemate |
2024-12-21 03:56:55 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 03:57:48 +0100 | housemate_ | (~housemate@ppp203-122-213-191.static.internode.on.net) housemate |
2024-12-21 03:57:52 +0100 | housemate | (~housemate@246.224.218.139.sta.wbroadband.net.au) (Ping timeout: 265 seconds) |
2024-12-21 03:59:27 +0100 | housemate_ | (~housemate@ppp203-122-213-191.static.internode.on.net) (Remote host closed the connection) |
2024-12-21 04:01:55 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 244 seconds) |
2024-12-21 04:07:58 +0100 | bitdex | (~bitdex@gateway/tor-sasl/bitdex) bitdex |
2024-12-21 04:12:56 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 04:17:41 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 265 seconds) |
2024-12-21 04:18:25 +0100 | dsrt^ | (~dsrt@c-98-242-74-66.hsd1.ga.comcast.net) |
2024-12-21 04:21:06 +0100 | Enviosity_ | (~Enviosity@2.219.56.221) |
2024-12-21 04:22:31 +0100 | machinedgod | (~machinedg@d108-173-18-100.abhsia.telus.net) (Ping timeout: 265 seconds) |
2024-12-21 04:23:05 +0100 | Guest88 | (~Guest88@syn-097-097-077-167.biz.spectrum.com) |
2024-12-21 04:23:36 +0100 | haver | (~Enviosity@2.219.56.221) (Ping timeout: 276 seconds) |
2024-12-21 04:26:11 +0100 | Guest88 | (~Guest88@syn-097-097-077-167.biz.spectrum.com) () |
2024-12-21 04:27:30 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 04:31:26 +0100 | fmira | (~user@user/fmira) fmira |
2024-12-21 04:31:52 +0100 | fmira | (~user@user/fmira) (Client Quit) |
2024-12-21 04:33:09 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 265 seconds) |
2024-12-21 04:38:39 +0100 | housemate | (~housemate@ppp203-122-213-191.static.internode.on.net) housemate |
2024-12-21 04:43:56 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 04:45:14 +0100 | td_ | (~td@i53870935.versanet.de) (Ping timeout: 265 seconds) |
2024-12-21 04:46:13 +0100 | fun-safe-math | (~fun-safe-@24.21.106.247) () |
2024-12-21 04:46:56 +0100 | td_ | (~td@i53870903.versanet.de) td_ |
2024-12-21 04:47:39 +0100 | housemate | (~housemate@ppp203-122-213-191.static.internode.on.net) (Ping timeout: 276 seconds) |
2024-12-21 04:50:30 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 252 seconds) |
2024-12-21 04:58:21 +0100 | itscaleb | (~itscaleb@user/itscaleb) itscaleb |
2024-12-21 05:01:58 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 05:06:30 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 244 seconds) |
2024-12-21 05:17:19 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 05:21:58 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 265 seconds) |
2024-12-21 05:23:11 +0100 | talismanick | (~user@2601:644:937c:ed10::ae5) (Remote host closed the connection) |
2024-12-21 05:24:56 +0100 | pavonia | (~user@user/siracusa) (Quit: Bye!) |
2024-12-21 05:27:53 +0100 | orangeflu | (~flu@240-100-179-143.ftth.glasoperator.nl) orangeFlu |
2024-12-21 05:28:15 +0100 | <orangeflu> | hello, i am losing my mind |
2024-12-21 05:28:44 +0100 | aforemny_ | (~aforemny@2001:9e8:6cd7:4a00:42f0:f044:3052:a50d) (Ping timeout: 265 seconds) |
2024-12-21 05:28:57 +0100 | aforemny | (~aforemny@2001:9e8:6cf6:8000:f088:f772:a53:8f63) aforemny |
2024-12-21 05:30:16 +0100 | fun-safe-math | (~fun-safe-@2601:1c2:1b7f:801f:a762:20cf:f426:d497) fun-safe-math |
2024-12-21 05:30:21 +0100 | <orangeflu> | what i'm about to ask may be more of a ghc question than anything else, so feel free to point me in the right direction if this is not the place. i have a cabal app, in it there used to be a big file (like 2000 files long). Being a responsible programmer, i split it up into multiple files. Since then, the performance of my app degraded considerably, even with -O2 |
2024-12-21 05:30:38 +0100 | <orangeflu> | is there a way of fixing this without moving everything again in one file? |
2024-12-21 05:32:42 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 05:33:46 +0100 | <Leary> | orangeflu: Presumably the issue is a lack of cross-module inlining and specialisation. You can rectify it with manual use of `INLINE`/`INLINABLE`/`SPECIALISE` pragmata, or with flags such as `-fexpose-overloaded-unfoldings`. |
2024-12-21 05:35:32 +0100 | <orangeflu> | i tried -fexpose-overloaded-unfoldings, and it doesn't seem to make a difference. As for INLINE/INLINEABLE, i did happen upon those pragmas in the docs, but it seems i have to put them for every function in my files.. which there are hundreds of. Surely there's a better way |
2024-12-21 05:36:31 +0100 | <orangeflu> | Correction, this is the flag i tried: -fexpose-all-unfoldings |
2024-12-21 05:37:26 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 265 seconds) |
2024-12-21 05:38:33 +0100 | fun-safe-math | (~fun-safe-@2601:1c2:1b7f:801f:a762:20cf:f426:d497) () |
2024-12-21 05:39:26 +0100 | <Leary> | orangeflu: It's strange for that not to have an effect. Perhaps you also need `-fspecialise-aggressively`. |
2024-12-21 05:41:27 +0100 | <orangeflu> | I am going to try with that one too. Until it compiles, just to be sure, where do i need to put those flags? I put them in ghc-options in my library component, should i put them in ghc-options for the executable as well? |
2024-12-21 05:41:57 +0100 | <Leary> | Probably. |
2024-12-21 05:42:50 +0100 | <Leary> | These flags are big hammers though, so while it's more tedious, you can get better results by identifying which exact functions want which pragmata. |
2024-12-21 05:45:12 +0100 | <orangeflu> | Well, they don't seem to be making a difference either way unfortunately |
2024-12-21 05:45:15 +0100 | fun-safe-math | (~fun-safe-@2601:1c2:1b7f:801f:83ce:3f54:3f3c:7c89) fun-safe-math |
2024-12-21 05:45:18 +0100 | <orangeflu> | No change in behaviour |
2024-12-21 05:45:29 +0100 | <orangeflu> | My program still eats 10 GB of RAM casually |
2024-12-21 05:48:04 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 05:50:57 +0100 | alp | (~alp@2001:861:8ca0:4940:bd95:640a:d817:df55) (Ping timeout: 248 seconds) |
2024-12-21 05:50:58 +0100 | ljdarj | (~Thunderbi@user/ljdarj) (Ping timeout: 265 seconds) |
2024-12-21 05:52:45 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 252 seconds) |
2024-12-21 05:53:28 +0100 | peterbecich | (~Thunderbi@syn-047-229-123-186.res.spectrum.com) peterbecich |
2024-12-21 05:55:08 +0100 | <orangeflu> | Fuck it, i'm going to put the file back together and then remove groups of functions until i find the culprits, and that will be that |
2024-12-21 05:55:25 +0100 | <haskellbridge> | <Bowuigi> Did you have to refactor some functions in order to split the file? Losing sharing on a big data structure can cause those problems |
2024-12-21 05:57:38 +0100 | <Leary> | Cross-module optimisation issues often have a big effect on time costs, but I haven't seen them ruin space usage before. I don't have enough information or expertise to say what the issue is, but if you can share the source then someone may be able to help. |
2024-12-21 05:59:36 +0100 | <orangeflu> | Bowuigi: no, I didn't refactor anything. The code is exactly the same before and after |
2024-12-21 06:00:25 +0100 | <haskellbridge> | <Bowuigi> Any large globals mentioned in one module and used in another? |
2024-12-21 06:00:34 +0100 | <orangeflu> | Leary: I mean, it does both. Things that used to take 100ms now take minutes, and instead f using neglijable RAM, it takes all of it |
2024-12-21 06:01:11 +0100 | <orangeflu> | Bowuigi: define globals please, not sure what you are reffering to |
2024-12-21 06:01:34 +0100 | <haskellbridge> | <Bowuigi> Maybe strictness analysis made something too lazy? Looking at the core of a file so large seems annoying though |
2024-12-21 06:01:49 +0100 | <Leary> | Sure sounds like you lost streaming somewhere. |
2024-12-21 06:02:07 +0100 | <orangeflu> | I can give you the source if it helps |
2024-12-21 06:02:23 +0100 | <orangeflu> | https://github.com/Flu/avr-emulator |
2024-12-21 06:02:32 +0100 | <orangeflu> | the file in question is src/Emulator.hs |
2024-12-21 06:02:38 +0100 | <haskellbridge> | <Bowuigi> "Large globals" as in variables that are not functions, but very large values |
2024-12-21 06:03:10 +0100 | <orangeflu> | I don't think i have any global variables |
2024-12-21 06:03:27 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 06:04:39 +0100 | <haskellbridge> | <Bowuigi> You don't, just checked |
2024-12-21 06:06:16 +0100 | <haskellbridge> | <Bowuigi> The only "large" stuff I can see is the memory and the Instruction enum (not too large tho, its representation should be fairly small) |
2024-12-21 06:06:32 +0100 | <orangeflu> | like, i have a program loop (runProgram function, bottom of file). I know that it may be responsible because the program only starts taking up a lot of space when i have long assemb;y files, that do a lot of jumps and continue for many cycles |
2024-12-21 06:07:11 +0100 | <orangeflu> | if i do something like 'JMP -1' it starts taking a lot of space when emulating that |
2024-12-21 06:08:13 +0100 | <haskellbridge> | <Bowuigi> Oh you have a list of instructions |
2024-12-21 06:08:22 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 265 seconds) |
2024-12-21 06:08:46 +0100 | <orangeflu> | yeah, the "program" is [Instruction] |
2024-12-21 06:09:24 +0100 | <haskellbridge> | <Bowuigi> So it's either losing streaming on the instruction list (which is likely very large because it's a whole program) or losing sharing (or similar) in memory |
2024-12-21 06:11:03 +0100 | <haskellbridge> | <Bowuigi> You also seem to be evaluating the entire spine of the instructions list on every iteration of runProgram, unless GHC optimizes that |
2024-12-21 06:11:48 +0100 | <haskellbridge> | <Bowuigi> Hmmm try switching from an instruction list to an instruction array |
2024-12-21 06:11:53 +0100 | <Leary> | It's probably best to investigate with profiling, but I've never done much of that myself. Personally, I'd strictify `go` and your custom data types first. |
2024-12-21 06:12:05 +0100 | <haskellbridge> | <Bowuigi> You are treating it like one as far as I can see |
2024-12-21 06:12:18 +0100 | <Leary> | And yeah, either an array or a list zipper for the instructions. |
2024-12-21 06:12:36 +0100 | <haskellbridge> | <Bowuigi> Profiling is crucial here indeed |
2024-12-21 06:13:07 +0100 | <orangeflu> | that's just it though, the instruction list doesn't have to be very big, it could just be [(ADD R1, R1), (JMP -1)], thus looping endlessly |
2024-12-21 06:13:20 +0100 | <orangeflu> | and it would still cause this problem |
2024-12-21 06:13:27 +0100 | <orangeflu> | i am going to try profiling |
2024-12-21 06:14:21 +0100 | <haskellbridge> | <Bowuigi> Oh then it's probably the memory, but yeah profiling will show the true cause |
2024-12-21 06:14:40 +0100 | <orangeflu> | Also, the split-up version is on branch 'feature/18-add-step-by-step-emulation' |
2024-12-21 06:18:17 +0100 | <haskellbridge> | <Bowuigi> Oh you didn't separate the functions from each instruction, I thought that was the main idea |
2024-12-21 06:18:51 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 06:19:21 +0100 | <orangeflu> | What do you mean |
2024-12-21 06:19:41 +0100 | rekahsoft | (~rekahsoft@76.69.85.220) (Remote host closed the connection) |
2024-12-21 06:21:58 +0100 | rekahsoft | (~rekahsoft@bras-base-orllon1103w-grc-06-76-69-85-220.dsl.bell.ca) rekahsoft |
2024-12-21 06:23:36 +0100 | remexre | (~remexre@user/remexre) remexre |
2024-12-21 06:25:46 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 265 seconds) |
2024-12-21 06:28:35 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 06:30:51 +0100 | housemate | (~housemate@1.147.119.169) housemate |
2024-12-21 06:36:46 +0100 | <orangeflu> | for whatever reason, the --enable-profiling flag has made ghc just hang.. |
2024-12-21 06:36:50 +0100 | <orangeflu> | i am so done |
2024-12-21 06:36:55 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 244 seconds) |
2024-12-21 06:37:26 +0100 | <orangeflu> | I am going to try and replace the list with an array and see what happens then |
2024-12-21 06:37:43 +0100 | <orangeflu> | if that doesn't work, i am reverting back to the old way |
2024-12-21 06:38:12 +0100 | housemate | (~housemate@1.147.119.169) (Read error: Connection reset by peer) |
2024-12-21 06:44:53 +0100 | <orangeflu> | Bowuigi: converted to array, still same behaviour |
2024-12-21 06:47:15 +0100 | <haskellbridge> | <Bowuigi> Hmmm, so it wasn't that |
2024-12-21 06:47:52 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 06:49:13 +0100 | housemate | (~housemate@ppp203-122-213-191.static.internode.on.net) housemate |
2024-12-21 06:49:25 +0100 | <haskellbridge> | <Bowuigi> Every way of checking will take some time because it involves either checking Core or comparing the results of strictness analysis (the easiest way to do this for datatypes is deriving generic and using the "from" function on them IIRC) |
2024-12-21 06:51:00 +0100 | <haskellbridge> | <Bowuigi> If it is the memory not being shared/streamed or something like that, trying to isolate it on a function level won't help much |
2024-12-21 06:51:31 +0100 | codaraxis__ | (~codaraxis@user/codaraxis) (Quit: Leaving) |
2024-12-21 06:52:25 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 244 seconds) |
2024-12-21 06:52:35 +0100 | <haskellbridge> | <Bowuigi> Also does the problem persist if you enable Strict mode? It doesn't make everything strict but it may minimize the memory issue if it has to do with strictness |
2024-12-21 06:52:47 +0100 | <orangeflu> | how do you enable strict mode |
2024-12-21 06:53:06 +0100 | <haskellbridge> | <Bowuigi> It's a language extension |
2024-12-21 06:53:57 +0100 | <haskellbridge> | <Bowuigi> So either {-# LANGUAGE Strict #-} or the equivalent in the Cabal/Stack file |
2024-12-21 06:54:58 +0100 | <haskellbridge> | <Bowuigi> It probably won't fix the issue entirely (no idea how does streaming interact with strictness analysis or if they are actually different on the two versions) |
2024-12-21 06:55:08 +0100 | <haskellbridge> | <Bowuigi> But it will give you a clue |
2024-12-21 06:55:14 +0100 | <orangeflu> | So just put {-# LANGUAGE Strict #-} in all files that used to be part of Emulator.hs |
2024-12-21 06:55:17 +0100 | <orangeflu> | ? |
2024-12-21 06:55:41 +0100 | <haskellbridge> | <Bowuigi> Yeah that should work |
2024-12-21 06:56:05 +0100 | tnt2 | (~Thunderbi@user/tnt1) tnt1 |
2024-12-21 06:56:11 +0100 | CrunchyFlakes | (~CrunchyFl@31.19.233.78) (Read error: Connection reset by peer) |
2024-12-21 06:57:00 +0100 | tnt1 | (~Thunderbi@user/tnt1) (Ping timeout: 276 seconds) |
2024-12-21 06:57:00 +0100 | tnt2 | tnt1 |
2024-12-21 06:57:32 +0100 | <haskellbridge> | <Bowuigi> If that doesn't work, just revert, unless someone else here has another idea |
2024-12-21 06:58:52 +0100 | CrunchyFlakes | (~CrunchyFl@31.19.233.78) |
2024-12-21 06:59:07 +0100 | <orangeflu> | hmm, that's the first time the behaviour changed |
2024-12-21 07:00:05 +0100 | <orangeflu> | Like, if I run bubblesort.asm, it just prints 'avr-emulator: <<loop>>', which i have no idea what it means cause i am pretty sure i never programmed that behaviour, nor do i have any idea what it means |
2024-12-21 07:00:35 +0100 | <haskellbridge> | <Bowuigi> Oh that's a bit too strict lmao |
2024-12-21 07:01:04 +0100 | <haskellbridge> | <Bowuigi> Enough to make GHC notice it loops forever |
2024-12-21 07:01:22 +0100 | <orangeflu> | If i run test.asm, the one that ate all the RAM, now it doesn't, but it also doesn't seem to do anything? Like, it should have finished by now, but it doesn't seem to consume ANY resources |
2024-12-21 07:01:36 +0100 | <orangeflu> | Yeah, but bubblesort.asm doesn't loop forever though |
2024-12-21 07:01:58 +0100 | <haskellbridge> | <Bowuigi> https://stackoverflow.com/questions/21505192/haskell-program-outputs-loop#21554398 |
2024-12-21 07:02:25 +0100 | <haskellbridge> | <Bowuigi> It probably loops with strictness turned on, which can happen if you generate an infinite data structure somewhere |
2024-12-21 07:03:13 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 07:03:26 +0100 | <orangeflu> | this is so weird |
2024-12-21 07:03:34 +0100 | <haskellbridge> | <Bowuigi> Your other test has been turned into a noop loop, GHC probably understood that it doesn't need anything from there |
2024-12-21 07:03:59 +0100 | <orangeflu> | why do i always feel like i am making haskell bend in ways it was never supposed to, haha |
2024-12-21 07:04:22 +0100 | <orangeflu> | also, on another note, can't ctrl-c it now |
2024-12-21 07:04:25 +0100 | <orangeflu> | so that's fun |
2024-12-21 07:04:36 +0100 | <haskellbridge> | <Bowuigi> The SO page also tells you how to profile to detect where it happened too, nice |
2024-12-21 07:04:41 +0100 | <c_wraith> | Yeah, this is why I think Language Strict is usually a bad idea. |
2024-12-21 07:04:52 +0100 | <c_wraith> | It turns out lots of correct Haskell code breaks when you turn it on |
2024-12-21 07:05:08 +0100 | <orangeflu> | well, it did fix my issue to be fair |
2024-12-21 07:05:10 +0100 | <haskellbridge> | <Bowuigi> Hmmm is StrictData also a bad idea? |
2024-12-21 07:05:15 +0100 | <orangeflu> | but it also lobotomized my program |
2024-12-21 07:05:45 +0100 | <c_wraith> | StrictData is not nearly as bad, but also not nearly as useful. You don't need *any* extensions to add a few !s to your data types. |
2024-12-21 07:05:53 +0100 | <haskellbridge> | <Bowuigi> The RTS literally decided to ignore SIGINT, wonderful |
2024-12-21 07:06:21 +0100 | <orangeflu> | it can't ignore me killing the terminal, so its fine |
2024-12-21 07:06:22 +0100 | housemate | (~housemate@ppp203-122-213-191.static.internode.on.net) (Ping timeout: 265 seconds) |
2024-12-21 07:06:50 +0100 | <orangeflu> | yeah, so guess i am going back to the monolithic file from before |
2024-12-21 07:06:52 +0100 | <haskellbridge> | <Bowuigi> Ok, let's go with something less extreme, locate every data type that mentions the memory and make that strict only |
2024-12-21 07:07:21 +0100 | weary-traveler | (~user@user/user363627) (Remote host closed the connection) |
2024-12-21 07:07:41 +0100 | <orangeflu> | Something like `memory :: !Array Int Word8`, you mean? |
2024-12-21 07:07:49 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 248 seconds) |
2024-12-21 07:07:53 +0100 | <haskellbridge> | <Bowuigi> Yeah I think |
2024-12-21 07:08:38 +0100 | <haskellbridge> | <Bowuigi> StrictData is technically faster to test but still seems like too much lol |
2024-12-21 07:08:44 +0100 | <orangeflu> | that doesn't inspire confidence, to be fair |
2024-12-21 07:09:50 +0100 | xal | (~xal@mx1.xal.systems) (Quit: No Ping reply in 180 seconds.) |
2024-12-21 07:10:29 +0100 | <haskellbridge> | <Bowuigi> Oh it's just that Strict adds too many !s (on functions and data types, maybe lets too but I don't remember), StrictData only adds !s on the ADTs you define |
2024-12-21 07:11:04 +0100 | xal | (~xal@mx1.xal.systems) xal |
2024-12-21 07:12:39 +0100 | <orangeflu> | Well, I mean, bubblesort.asm is definitely faster and takes neglijible ram, but test.asm still takes some gigabytes, can't tell if less than before |
2024-12-21 07:13:00 +0100 | <orangeflu> | i call this an improvement |
2024-12-21 07:13:26 +0100 | <haskellbridge> | <Bowuigi> Also note that ! makes strict only the thing you refer to directly, so ! on a List parameter means that the value itself is strict, not that the whole list gets fully evaluated ASAP |
2024-12-21 07:14:17 +0100 | <haskellbridge> | <Bowuigi> Try profiling now, it might help with test.asm |
2024-12-21 07:14:21 +0100 | <orangeflu> | I ran the whole test suite, and it actually made it through this time |
2024-12-21 07:14:27 +0100 | <orangeflu> | including test.asm |
2024-12-21 07:14:45 +0100 | <orangeflu> | it took like 9 gigs |
2024-12-21 07:14:58 +0100 | <haskellbridge> | <Bowuigi> That's one less than before |
2024-12-21 07:15:05 +0100 | <orangeflu> | but at least it finished in like 30 seconds |
2024-12-21 07:15:11 +0100 | <orangeflu> | as opposed to not at all |
2024-12-21 07:15:23 +0100 | <orangeflu> | but still 25 seconds slower than before i did this split |
2024-12-21 07:15:30 +0100 | <[exa]> | orangeflu: the -fexpose-all-unfoldings is not sufficient by itself, you also need something like -finline-aggressively (not very sure about the name but it sounded this way) |
2024-12-21 07:16:12 +0100 | <[exa]> | btw what's the program? the loopy situation and sigint ignore sounds wild |
2024-12-21 07:16:22 +0100 | <haskellbridge> | <Bowuigi> Aggressive inlining should help too yeah |
2024-12-21 07:16:32 +0100 | <orangeflu> | i think i tried that about 8 hours ago |
2024-12-21 07:16:35 +0100 | <orangeflu> | can't remember |
2024-12-21 07:16:36 +0100 | <haskellbridge> | <Bowuigi> [exa] https://github.com/Flu/avr-emulator |
2024-12-21 07:16:49 +0100 | <[exa]> | I'm using these 2 for everything that goes to production |
2024-12-21 07:17:01 +0100 | <orangeflu> | well, the loopy thing and ignoring sigint was when we tried {-# LANGUAGE Strict #-} |
2024-12-21 07:17:10 +0100 | <orangeflu> | that doesn't happen normally |
2024-12-21 07:17:22 +0100 | <haskellbridge> | <Bowuigi> [exa] The split-up version is on branch feature/18-add-step-by-step-emulation |
2024-12-21 07:18:02 +0100 | <orangeflu> | ok, i am going to remove the strict data things, and try again with -finline-aggressively |
2024-12-21 07:18:17 +0100 | rekahsoft | (~rekahsoft@bras-base-orllon1103w-grc-06-76-69-85-220.dsl.bell.ca) (Remote host closed the connection) |
2024-12-21 07:18:24 +0100 | <orangeflu> | haskell has taken years off my life at this point |
2024-12-21 07:18:36 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 07:18:38 +0100 | JuanDaugherty | (~juan@user/JuanDaugherty) JuanDaugherty |
2024-12-21 07:19:00 +0100 | <haskellbridge> | <Bowuigi> No no keep strictness, those are supposed to mix together |
2024-12-21 07:19:45 +0100 | <haskellbridge> | <Bowuigi> Or well, try both if you have some time, going blind here is not that fun lol |
2024-12-21 07:19:51 +0100 | <[exa]> | I'd say trying without strictness should be a safe bet. Strictness changes semantics, aggressive inlining only changes weird corner cases |
2024-12-21 07:20:31 +0100 | <orangeflu> | -finline-generics-aggressively |
2024-12-21 07:20:36 +0100 | <orangeflu> | is this the one you meant? |
2024-12-21 07:21:01 +0100 | <[exa]> | no thats generics only (not a bad choice either if you use generics) |
2024-12-21 07:21:10 +0100 | <haskellbridge> | <Bowuigi> Put everything that has "aggressively" on your flags |
2024-12-21 07:21:36 +0100 | <haskellbridge> | <Bowuigi> Probably a good idea for production stuff lol |
2024-12-21 07:21:44 +0100 | <[exa]> | oh wait it is -fspecialize-aggressively |
2024-12-21 07:22:09 +0100 | <orangeflu> | i already have that one then |
2024-12-21 07:22:17 +0100 | <[exa]> | ah okay nvm then :( |
2024-12-21 07:22:58 +0100 | <orangeflu> | let me go back to main to see how it compares to test.asm before all of this, maybe i am wrong and it used to be this way before as well |
2024-12-21 07:23:02 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 252 seconds) |
2024-12-21 07:23:17 +0100 | <[exa]> | but you have a space leak there right? suggest doing an allocation profile to see what's happening |
2024-12-21 07:23:26 +0100 | <haskellbridge> | <Bowuigi> Yes, also try to profile the run on test.asm on both |
2024-12-21 07:23:41 +0100 | <haskellbridge> | <Bowuigi> Both main and the memory-strict version |
2024-12-21 07:24:16 +0100 | <orangeflu> | profiling doesn't seem to work for some reason |
2024-12-21 07:24:21 +0100 | <orangeflu> | idk why |
2024-12-21 07:24:26 +0100 | <orangeflu> | ghc just hangs |
2024-12-21 07:24:30 +0100 | <orangeflu> | it says ' |
2024-12-21 07:24:42 +0100 | <orangeflu> | Building vector-0.4.2 |
2024-12-21 07:24:46 +0100 | <orangeflu> | and then stops there |
2024-12-21 07:25:10 +0100 | <orangeflu> | waited 10 minutes for it to compile that |
2024-12-21 07:25:23 +0100 | <haskellbridge> | <Bowuigi> I don't know much about profiling, [exa] any ideas? |
2024-12-21 07:26:47 +0100 | <haskellbridge> | <Bowuigi> On the meantime, how good is the performance if you use StrictData on the split up version? It should be close to the memory-strict one, maybe faster |
2024-12-21 07:27:19 +0100 | <mauke> | https://infosec.exchange/@barubary/111126546998839428 |
2024-12-21 07:28:17 +0100 | billchenchina | (~billchenc@183.95.251.11) billchenchina |
2024-12-21 07:29:14 +0100 | <orangeflu> | Ok, so went back to main |
2024-12-21 07:29:29 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 07:29:34 +0100 | euphores | (~SASL_euph@user/euphores) (Quit: Leaving.) |
2024-12-21 07:29:34 +0100 | <orangeflu> | test.asm performance is comparable to what it is now with the strict stuff |
2024-12-21 07:30:09 +0100 | <orangeflu> | Idk what you mean by StrictData, I just put ! in front of some types |
2024-12-21 07:30:17 +0100 | <orangeflu> | Still don't understand what it doese |
2024-12-21 07:30:43 +0100 | <orangeflu> | But now it's comparable to what it was before the split |
2024-12-21 07:30:57 +0100 | <orangeflu> | So I am happy, even if it feels a little bit hacky |
2024-12-21 07:31:10 +0100 | <haskellbridge> | <Bowuigi> It disallows GHC from making a thunk in that position |
2024-12-21 07:31:33 +0100 | <orangeflu> | Still don't know why test.asm takes gigabytes of memory.. that seems to have been a problem for some time, but never noticed |
2024-12-21 07:32:00 +0100 | <orangeflu> | but after the split, it got much much worse, that's why i noticed |
2024-12-21 07:32:06 +0100 | <orangeflu> | interesting |
2024-12-21 07:32:08 +0100 | <[exa]> | ok I had a bit of a look at the code, you certainly want the stuff in your State struct strict, and on top of that I'd vote running that in a strict State monad so that you're sure the program isn't keeping one million versions of this state by accident |
2024-12-21 07:32:12 +0100 | <haskellbridge> | <Bowuigi> What apparently happened is that you had a space leak, multiple copies of the entire emulator's memory were floating around at the same time, being left as thunks |
2024-12-21 07:32:21 +0100 | <[exa]> | 2nd suggestion: MVector |
2024-12-21 07:32:50 +0100 | <[exa]> | you have plain arrays there right? if so that one _is_ the source of insane allocationery |
2024-12-21 07:32:52 +0100 | billchenchina | (~billchenc@183.95.251.11) (Ping timeout: 252 seconds) |
2024-12-21 07:33:16 +0100 | <orangeflu> | [exa]: yes, now everything in EmulatorState is strict |
2024-12-21 07:33:47 +0100 | <orangeflu> | What's a strict state monad? is it different from a normal State monad? |
2024-12-21 07:34:02 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 252 seconds) |
2024-12-21 07:34:11 +0100 | <[exa]> | yeah, the other question is how to make sure you're not keeping some of the states by accident together with some other unevaluated data |
2024-12-21 07:34:53 +0100 | <orangeflu> | me personally, still wrapping my head around the whole monad thing. I did use some monads here and there, but made them work just by trying shit until the compiler accepted it, can't say i understand it |
2024-12-21 07:34:54 +0100 | <[exa]> | State monad does not prevent this but since you never touch&hold the state explicitly, leak probability gets lower |
2024-12-21 07:35:06 +0100 | <[exa]> | ah well |
2024-12-21 07:35:16 +0100 | <haskellbridge> | <Bowuigi> Oh wait you are still learning monads? |
2024-12-21 07:35:19 +0100 | JuanDaugherty | (~juan@user/JuanDaugherty) (Quit: JuanDaugherty) |
2024-12-21 07:35:20 +0100 | <[exa]> | try parser combinators, these usually demystify it |
2024-12-21 07:35:37 +0100 | <orangeflu> | You mean the ones I have in Parser.hs? |
2024-12-21 07:36:22 +0100 | <haskellbridge> | <Bowuigi> Strictness is definitely not a begginner's topic, it's ok if you don't understand it yet |
2024-12-21 07:36:41 +0100 | <orangeflu> | Bowuigi: yeah, shit, it's hard to wrap my head around them. I understand them somewhat. I read the chapters in Learn you a haskell a bunch of times |
2024-12-21 07:36:47 +0100 | <orangeflu> | Conceptually, i think i understand it |
2024-12-21 07:36:54 +0100 | <orangeflu> | But to actually use them? |
2024-12-21 07:37:22 +0100 | <haskellbridge> | <Bowuigi> Essentially, when Haskell says it evaluates stuff only when needed it really means that. The only primitive that evaluates anything is "case" (IIRC) |
2024-12-21 07:37:57 +0100 | <orangeflu> | i've been wanting to use State monad instead of whatever the fuck i created here, but could never make it work, it always gives me some error i don't understand how to fix |
2024-12-21 07:38:29 +0100 | <orangeflu> | Although to be fair, i wrote most of the code in Emulator.hs before i read up on monads |
2024-12-21 07:38:36 +0100 | <orangeflu> | maybe if i try now, it will be easier |
2024-12-21 07:38:53 +0100 | <orangeflu> | But state monads are harder to understand than something like Maybe |
2024-12-21 07:38:56 +0100 | <orangeflu> | That one I get |
2024-12-21 07:38:59 +0100 | <haskellbridge> | <Bowuigi> ! automatically inserts one of those "case"s when using those values so you have at least one layer of evaluation now |
2024-12-21 07:39:14 +0100 | euphores | (~SASL_euph@user/euphores) euphores |
2024-12-21 07:39:48 +0100 | <orangeflu> | [exa]: what's MVector and why should i use it instead of arrays? |
2024-12-21 07:40:11 +0100 | <haskellbridge> | <Bowuigi> MVector is fairly similar to a C array |
2024-12-21 07:40:33 +0100 | <orangeflu> | i thought an array is similar to a c array.. because of the name |
2024-12-21 07:40:37 +0100 | <orangeflu> | that's why i used it |
2024-12-21 07:41:01 +0100 | <haskellbridge> | <Bowuigi> MVector is mutable, gets nice support for compiler magic and goes fast if you use it properly |
2024-12-21 07:41:19 +0100 | <orangeflu> | am i going to have to use monads with it? |
2024-12-21 07:41:49 +0100 | <orangeflu> | so its not going to be a drop-in replacement then |
2024-12-21 07:42:01 +0100 | <haskellbridge> | <Bowuigi> Array is not a C array, but more like a functional array (not to be confused with a List zipper, which is a tree) that gets copied around |
2024-12-21 07:42:45 +0100 | <orangeflu> | i am getting code-reviewed here, i love it |
2024-12-21 07:43:12 +0100 | <haskellbridge> | <Bowuigi> https://hackage.haskell.org/package/vector-0.13.2.0/docs/Data-Vector-Mutable.html this should make some things clearer |
2024-12-21 07:43:49 +0100 | <orangeflu> | i was actually kinda scared while writing this emulator that it would be a terrible misuse of haskell, but it seems to be alright, you guys didn't complain too much about it |
2024-12-21 07:45:03 +0100 | <haskellbridge> | <Bowuigi> Haskell has some fancy optimization tricks that make low level-ish projects like yours feasible |
2024-12-21 07:45:36 +0100 | JuanDaugherty | (~juan@user/JuanDaugherty) JuanDaugherty |
2024-12-21 07:45:37 +0100 | <orangeflu> | ok, i get it. it would still require me to go and replace a lot of stuff in the instruction implementations, but it seems doable |
2024-12-21 07:46:29 +0100 | <haskellbridge> | <Bowuigi> Those tricks include inlining, strictness, mutable data and fusion (we haven't mentioned it explicitly but it's the magic that makes mapping multiple times fast by mapping once, and similar) |
2024-12-21 07:46:58 +0100 | <haskellbridge> | <Bowuigi> Vector takes care of the fusion, strictness and mutability for you when you use the containers it provides |
2024-12-21 07:48:50 +0100 | <orangeflu> | But would i not still need to return EmulatorState each time i execute an instruction? Therefore the MVector will be copied, so what's the difference between this and an array then? What issue did i solve? |
2024-12-21 07:50:17 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 07:50:20 +0100 | <haskellbridge> | <Bowuigi> Here's a very comprehensive guide to GHC optimization for later. Note that those topics are advanced (tho explained clearly there) https://www.stackbuilders.com/insights/ghc-optimization-and-fusion/#specializing |
2024-12-21 07:50:46 +0100 | <haskellbridge> | <Bowuigi> You don't copy an MVector unless you call clone on it |
2024-12-21 07:51:01 +0100 | <haskellbridge> | <Bowuigi> Modifying it doesn't copy it |
2024-12-21 07:52:15 +0100 | <orangeflu> | i really need to understand monads properly.. |
2024-12-21 07:53:06 +0100 | <haskellbridge> | <Bowuigi> Hmmm, if parser combinators didn't help, maybe playing with the free monad will? |
2024-12-21 07:53:23 +0100 | <orangeflu> | They did help, don't get me wrong |
2024-12-21 07:53:27 +0100 | <orangeflu> | Problem is |
2024-12-21 07:53:32 +0100 | <orangeflu> | I go mostly by intuition |
2024-12-21 07:53:54 +0100 | <orangeflu> | But if i think hard about it, my brain doesn't feel like it understands them |
2024-12-21 07:54:18 +0100 | <orangeflu> | Like, if somebody asked me how they work, i don't know that i could explain |
2024-12-21 07:54:51 +0100 | <orangeflu> | i just need to use them some more, go back, re-read the chapter about it in Learn you a haskell, rinse and repeat |
2024-12-21 07:54:58 +0100 | <orangeflu> | And each time I will get it a bit more |
2024-12-21 07:55:30 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 276 seconds) |
2024-12-21 07:55:50 +0100 | <orangeflu> | But right now, I want to implement a REPL and step by step emulation, which was the point of all this headache to begin with |
2024-12-21 07:56:05 +0100 | <orangeflu> | And there's a lot of monads there |
2024-12-21 07:56:29 +0100 | <orangeflu> | src/Repl.hs on my branch |
2024-12-21 07:57:30 +0100 | <haskellbridge> | <Bowuigi> A nice explanation of free monads https://www.haskellforall.com/2012/06/you-could-have-invented-free-monads.html?m=1 |
2024-12-21 07:59:32 +0100 | JuanDaugherty | (~juan@user/JuanDaugherty) (Quit: JuanDaugherty) |
2024-12-21 07:59:40 +0100 | <haskellbridge> | <Bowuigi> As for the emulator, just going with MVector, messing around with strictness and adding the "aggressively" flags to the Cabal file will fix 70%-75% of your performance/space issues, the rest are fixed by even deeper magic which would not help now |
2024-12-21 08:00:06 +0100 | manwithluck | (~manwithlu@194.177.28.164) (Ping timeout: 244 seconds) |
2024-12-21 08:00:10 +0100 | <orangeflu> | Ok, bookmarked the links you gave me |
2024-12-21 08:00:17 +0100 | JamesMowery439 | (~JamesMowe@ip68-228-212-232.ph.ph.cox.net) (Quit: Goodbye) |
2024-12-21 08:00:29 +0100 | <orangeflu> | also, thank you for everything |
2024-12-21 08:00:34 +0100 | JamesMowery439 | (~JamesMowe@ip68-228-212-232.ph.ph.cox.net) JamesMowery |
2024-12-21 08:00:45 +0100 | <orangeflu> | been at this for 12 hours now, and my brain is mush |
2024-12-21 08:00:51 +0100 | <orangeflu> | you really helped |
2024-12-21 08:01:08 +0100 | tnt1 | (~Thunderbi@user/tnt1) (Ping timeout: 244 seconds) |
2024-12-21 08:01:20 +0100 | <haskellbridge> | <Bowuigi> Step by step emulation shouldn't be painful at all, you structured this nicely with the instruction list |
2024-12-21 08:01:33 +0100 | <haskellbridge> | <Bowuigi> Good luck and glad to help! |
2024-12-21 08:01:49 +0100 | tnt1 | (~Thunderbi@user/tnt1) tnt1 |
2024-12-21 08:03:10 +0100 | <orangeflu> | well, it is painful |
2024-12-21 08:03:45 +0100 | <orangeflu> | cause look how many monads are involved in this: InputT, IO, Parser, Either, Maybe |
2024-12-21 08:04:15 +0100 | <orangeflu> | I am actually surprised that what i wrote so far compiles even |
2024-12-21 08:04:36 +0100 | <orangeflu> | even if it looks... questionable |
2024-12-21 08:05:42 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 08:06:43 +0100 | peterbecich | (~Thunderbi@syn-047-229-123-186.res.spectrum.com) (Quit: peterbecich) |
2024-12-21 08:07:10 +0100 | peterbecich | (~Thunderbi@syn-047-229-123-186.res.spectrum.com) peterbecich |
2024-12-21 08:10:35 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 260 seconds) |
2024-12-21 08:11:47 +0100 | manwithluck | (~manwithlu@194.177.28.164) manwithluck |
2024-12-21 08:12:14 +0100 | manwithluck | (~manwithlu@194.177.28.164) (Read error: Connection reset by peer) |
2024-12-21 08:14:56 +0100 | takuan | (~takuan@178-116-218-225.access.telenet.be) |
2024-12-21 08:16:21 +0100 | manwithluck | (~manwithlu@194.177.28.164) manwithluck |
2024-12-21 08:21:24 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 08:25:42 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 246 seconds) |
2024-12-21 08:30:34 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 08:32:43 +0100 | Digitteknohippie | Digit |
2024-12-21 08:33:25 +0100 | CrunchyFlakes | (~CrunchyFl@31.19.233.78) (Read error: Connection reset by peer) |
2024-12-21 08:34:53 +0100 | Sgeo_ | (~Sgeo@user/sgeo) Sgeo |
2024-12-21 08:35:13 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 248 seconds) |
2024-12-21 08:36:01 +0100 | CrunchyFlakes | (~CrunchyFl@31.19.233.78) |
2024-12-21 08:38:12 +0100 | Sgeo | (~Sgeo@user/sgeo) (Ping timeout: 252 seconds) |
2024-12-21 08:48:42 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 08:50:56 +0100 | j1n37 | (~j1n37@user/j1n37) (Read error: Connection reset by peer) |
2024-12-21 08:51:04 +0100 | <haskellbridge> | <magic_rb> Bowuigi what cabal flags are you referring to? |
2024-12-21 08:52:38 +0100 | <[exa]> | orangeflu: the change to State won't be completely plug-in but you somewhat implicitly do the State there already so I'd say lots of code would just disappear |
2024-12-21 08:53:01 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 244 seconds) |
2024-12-21 08:54:01 +0100 | <[exa]> | change from arrays to mvectors after that should be quite painless (you change State to StateT IO or ST or so to get the sequenced operations, and then just adjust the memory-changing operation) |
2024-12-21 08:54:03 +0100 | j1n37 | (~j1n37@user/j1n37) j1n37 |
2024-12-21 08:54:17 +0100 | <haskellbridge> | <Bowuigi> magic_rb the GHC flags -fspecialize-aggressively, -fexpose-all-unfoldings and -O2, maybe other stuff too idk |
2024-12-21 08:54:29 +0100 | <[exa]> | orangeflu: btw highly recommend playing with a tiny prototype of each, helps a lot. |
2024-12-21 08:54:49 +0100 | <haskellbridge> | <magic_rb> Ill try those for my little game engine, last time i profiled it, 40% of the time was >>= |
2024-12-21 08:55:32 +0100 | <haskellbridge> | <Bowuigi> If that's due to an associativity issue try Codensity too |
2024-12-21 08:57:36 +0100 | <haskellbridge> | <Bowuigi> Tangentially related, is smalltt a strict language? It seems to have quite a bit of focus on strictness optimization |
2024-12-21 09:00:00 +0100 | caconym | (~caconym@user/caconym) (Quit: bye) |
2024-12-21 09:00:40 +0100 | caconym | (~caconym@user/caconym) caconym |
2024-12-21 09:02:20 +0100 | <haskellbridge> | <Bowuigi> Implementation-wise, it kinda switches between lazy and eager depending on what needs to be done (for performance reasons), but I'm not sure about its semantics in the usual tasks |
2024-12-21 09:04:05 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 09:04:20 +0100 | peterbecich | (~Thunderbi@syn-047-229-123-186.res.spectrum.com) (Ping timeout: 264 seconds) |
2024-12-21 09:13:26 +0100 | tzh | (~tzh@c-76-115-131-146.hsd1.or.comcast.net) (Quit: zzz) |
2024-12-21 09:15:54 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 265 seconds) |
2024-12-21 09:21:01 +0100 | <probie> | It's not possible to override precedence for a function specified in another module is it? |
2024-12-21 09:23:12 +0100 | Guest46 | (~Guest46@2405:201:e016:301c:9934:efe2:6f7:528d) |
2024-12-21 09:25:21 +0100 | Guest46 | (~Guest46@2405:201:e016:301c:9934:efe2:6f7:528d) (Client Quit) |
2024-12-21 09:25:45 +0100 | <geekosaur> | no |
2024-12-21 09:26:19 +0100 | <geekosaur> | at least, not directly. You can do `` foo = bar; infixl 4 `foo` `` or similar though |
2024-12-21 09:26:37 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 09:28:31 +0100 | Guest46 | (~Guest46@2405:201:e016:301c:9934:efe2:6f7:528d) |
2024-12-21 09:28:36 +0100 | Guest46 | (~Guest46@2405:201:e016:301c:9934:efe2:6f7:528d) (Client Quit) |
2024-12-21 09:31:02 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 244 seconds) |
2024-12-21 09:37:06 +0100 | Square | (~Square@user/square) (Ping timeout: 246 seconds) |
2024-12-21 09:46:38 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 09:51:30 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 260 seconds) |
2024-12-21 09:59:30 +0100 | ljdarj | (~Thunderbi@user/ljdarj) ljdarj |
2024-12-21 10:02:01 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 10:06:41 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 244 seconds) |
2024-12-21 10:14:59 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 10:16:06 +0100 | Tuplanolla | (~Tuplanoll@91-159-69-59.elisa-laajakaista.fi) Tuplanolla |
2024-12-21 10:19:48 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 276 seconds) |
2024-12-21 10:30:21 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 10:30:40 +0100 | rembo10_ | (~rembo10@main.remulis.com) (Quit: ZNC 1.8.2 - https://znc.in) |
2024-12-21 10:32:09 +0100 | rembo10 | (~rembo10@main.remulis.com) rembo10 |
2024-12-21 10:36:39 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 244 seconds) |
2024-12-21 10:40:17 +0100 | __monty__ | (~toonn@user/toonn) toonn |
2024-12-21 10:44:04 +0100 | acidjnk_new | (~acidjnk@p200300d6e7283f52b5be3bacf47f1ed3.dip0.t-ipconnect.de) acidjnk |
2024-12-21 10:47:39 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 10:51:34 +0100 | vanishingideal | (~vanishing@user/vanishingideal) vanishingideal |
2024-12-21 10:51:51 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 244 seconds) |
2024-12-21 10:51:57 +0100 | ash3en | (~Thunderbi@2a03:7846:b6eb:101:93ac:a90a:da67:f207) ash3en |
2024-12-21 11:02:54 +0100 | tnt2 | (~Thunderbi@user/tnt1) tnt1 |
2024-12-21 11:03:01 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 11:04:39 +0100 | tnt1 | (~Thunderbi@user/tnt1) (Ping timeout: 265 seconds) |
2024-12-21 11:04:39 +0100 | tnt2 | tnt1 |
2024-12-21 11:07:47 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 252 seconds) |
2024-12-21 11:17:41 +0100 | Sgeo_ | (~Sgeo@user/sgeo) (Read error: Connection reset by peer) |
2024-12-21 11:18:34 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 11:19:45 +0100 | vanishingideal | (~vanishing@user/vanishingideal) (Ping timeout: 244 seconds) |
2024-12-21 11:23:12 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 252 seconds) |
2024-12-21 11:33:31 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 11:35:51 +0100 | sawilagar | (~sawilagar@user/sawilagar) sawilagar |
2024-12-21 11:36:01 +0100 | pabs3 | (~pabs3@user/pabs3) (Read error: Connection reset by peer) |
2024-12-21 11:36:45 +0100 | pabs3 | (~pabs3@user/pabs3) pabs3 |
2024-12-21 11:38:32 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 264 seconds) |
2024-12-21 11:44:31 +0100 | ephilalethes | (~noumenon@202.186.203.84) noumenon |
2024-12-21 11:45:41 +0100 | billchenchina | (~billchenc@183.95.251.11) billchenchina |
2024-12-21 11:48:53 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 11:50:01 +0100 | billchenchina | (~billchenc@183.95.251.11) (Ping timeout: 244 seconds) |
2024-12-21 11:53:09 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 248 seconds) |
2024-12-21 11:56:51 +0100 | ljdarj | (~Thunderbi@user/ljdarj) (Ping timeout: 272 seconds) |
2024-12-21 12:00:44 +0100 | ash3en | (~Thunderbi@2a03:7846:b6eb:101:93ac:a90a:da67:f207) (Quit: ash3en) |
2024-12-21 12:03:46 +0100 | Guest93 | (~Guest93@106.219.180.229) |
2024-12-21 12:04:18 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 12:04:30 +0100 | Guest93 | (~Guest93@106.219.180.229) (Client Quit) |
2024-12-21 12:06:32 +0100 | carbolymer_ | carbolymer |
2024-12-21 12:09:38 +0100 | tnt2 | (~Thunderbi@user/tnt1) tnt1 |
2024-12-21 12:10:29 +0100 | tnt1 | (~Thunderbi@user/tnt1) (Ping timeout: 252 seconds) |
2024-12-21 12:10:29 +0100 | tnt2 | tnt1 |
2024-12-21 12:10:49 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 245 seconds) |
2024-12-21 12:17:38 +0100 | AlexZenon | (~alzenon@5.139.233.146) (Ping timeout: 265 seconds) |
2024-12-21 12:19:23 +0100 | alexherbo2 | (~alexherbo@2a02-8440-3508-e5d2-70ed-26be-f60d-e304.rev.sfr.net) alexherbo2 |
2024-12-21 12:22:18 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 12:23:03 +0100 | AlexZenon | (~alzenon@5.139.233.146) |
2024-12-21 12:24:09 +0100 | rvalue- | (~rvalue@user/rvalue) rvalue |
2024-12-21 12:24:43 +0100 | rvalue | (~rvalue@user/rvalue) (Ping timeout: 264 seconds) |
2024-12-21 12:26:30 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 246 seconds) |
2024-12-21 12:28:17 +0100 | rvalue- | rvalue |
2024-12-21 12:30:12 +0100 | youthlic | (~Thunderbi@user/youthlic) (Ping timeout: 265 seconds) |
2024-12-21 12:34:30 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 12:36:12 +0100 | youthlic | (~Thunderbi@user/youthlic) youthlic |
2024-12-21 12:37:20 +0100 | alexherbo2 | (~alexherbo@2a02-8440-3508-e5d2-70ed-26be-f60d-e304.rev.sfr.net) (Remote host closed the connection) |
2024-12-21 12:39:30 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 260 seconds) |
2024-12-21 12:41:03 +0100 | mewra | (~aranea@wireguard/contributorcat/mira) (Quit: back in a couple weeks :3) |
2024-12-21 12:48:53 +0100 | Digitteknohippie | (~user@user/digit) Digit |
2024-12-21 12:49:51 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 12:51:15 +0100 | dostoevsky | (~dostoevsk@user/dostoevsky) (Ping timeout: 276 seconds) |
2024-12-21 12:51:21 +0100 | Digit | (~user@user/digit) (Ping timeout: 246 seconds) |
2024-12-21 12:54:25 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 248 seconds) |
2024-12-21 12:55:32 +0100 | lxsameer | (lxsameer@Serene/lxsameer) lxsameer |
2024-12-21 13:00:05 +0100 | caconym | (~caconym@user/caconym) (Quit: bye) |
2024-12-21 13:03:37 +0100 | caconym | (~caconym@user/caconym) caconym |
2024-12-21 13:04:46 +0100 | lxsameer | (lxsameer@Serene/lxsameer) (Ping timeout: 252 seconds) |
2024-12-21 13:05:15 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 13:05:41 +0100 | dostoevsky | (~dostoevsk@user/dostoevsky) dostoevsky |
2024-12-21 13:06:44 +0100 | Digitteknohippie | Digit |
2024-12-21 13:06:51 +0100 | lxsameer | (lxsameer@Serene/lxsameer) lxsameer |
2024-12-21 13:09:54 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 252 seconds) |
2024-12-21 13:13:12 +0100 | lxsameer | (lxsameer@Serene/lxsameer) (Ping timeout: 244 seconds) |
2024-12-21 13:14:31 +0100 | califax | (~califax@user/califx) (Remote host closed the connection) |
2024-12-21 13:16:04 +0100 | califax | (~califax@user/califx) califx |
2024-12-21 13:16:11 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 13:35:19 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 260 seconds) |
2024-12-21 13:39:09 +0100 | Digit | (~user@user/digit) (Ping timeout: 252 seconds) |
2024-12-21 13:40:06 +0100 | Digitteknohippie | (~user@user/digit) Digit |
2024-12-21 13:42:08 +0100 | Digit | (~user@user/digit) Digit |
2024-12-21 13:44:04 +0100 | Digitteknohippie | (~user@user/digit) (Quit: sorted my other instance from locking up with a forced umount and remount) |
2024-12-21 13:45:04 +0100 | lxsameer | (~lxsameer@Serene/lxsameer) lxsameer |
2024-12-21 13:46:52 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 13:48:51 +0100 | glguy | (glguy@libera/staff/glguy) (Read error: Connection reset by peer) |
2024-12-21 13:49:48 +0100 | lxsameer | (~lxsameer@Serene/lxsameer) (Ping timeout: 246 seconds) |
2024-12-21 13:51:37 +0100 | wootehfoot | (~wootehfoo@user/wootehfoot) wootehfoot |
2024-12-21 13:53:30 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 244 seconds) |
2024-12-21 14:02:53 +0100 | pavonia | (~user@user/siracusa) siracusa |
2024-12-21 14:04:31 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 14:08:56 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 252 seconds) |
2024-12-21 14:16:20 +0100 | Guest78 | (~Guest78@37.228.252.73) |
2024-12-21 14:17:50 +0100 | sprotte24 | (~sprotte24@p200300d16f1a2c0064c6ee858fd5dcfe.dip0.t-ipconnect.de) |
2024-12-21 14:19:53 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 14:21:57 +0100 | alp | (~alp@2001:861:8ca0:4940:94c0:33a8:5f77:cbe8) |
2024-12-21 14:24:37 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 248 seconds) |
2024-12-21 14:30:21 +0100 | Digitteknohippie | (~user@user/digit) Digit |
2024-12-21 14:32:00 +0100 | Digit | (~user@user/digit) (Ping timeout: 276 seconds) |
2024-12-21 14:32:33 +0100 | alp | (~alp@2001:861:8ca0:4940:94c0:33a8:5f77:cbe8) (Ping timeout: 248 seconds) |
2024-12-21 14:34:07 +0100 | Smiles | (uid551636@id-551636.lymington.irccloud.com) Smiles |
2024-12-21 14:34:27 +0100 | machinedgod | (~machinedg@d108-173-18-100.abhsia.telus.net) machinedgod |
2024-12-21 14:40:53 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 14:45:32 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 265 seconds) |
2024-12-21 14:53:06 +0100 | weary-traveler | (~user@user/user363627) user363627 |
2024-12-21 14:56:17 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 14:58:46 +0100 | meritamen | (~user@user/meritamen) meritamen |
2024-12-21 15:02:04 +0100 | tremon | (~tremon@83.80.159.219) tremon |
2024-12-21 15:03:25 +0100 | Digitteknohippie | Digit |
2024-12-21 15:03:51 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 276 seconds) |
2024-12-21 15:14:19 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 15:18:57 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 252 seconds) |
2024-12-21 15:29:16 +0100 | <zzz> | i've always wonder if Haskell without infix operators would be nicer |
2024-12-21 15:29:40 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 15:30:19 +0100 | <zzz> | then again, function composition would get awkward |
2024-12-21 15:31:14 +0100 | Guest78 | (~Guest78@37.228.252.73) (Quit: Client closed) |
2024-12-21 15:34:00 +0100 | <probie> | Personally, I wouldn't hate a version of Haskell where all infix operators have the same precedence as `$` |
2024-12-21 15:38:28 +0100 | <enikar> | there is liskell, if many parentheses don't afraid you ;) |
2024-12-21 15:38:56 +0100 | <ski> | `y * k + x' would be awkward |
2024-12-21 15:40:34 +0100 | <probie> | ski: That's not annoying at all. The annoying operator is `-`, because `3 - 4 - 5 - 6` is `3 - (4 - (5 - 6))` |
2024-12-21 15:41:01 +0100 | <ski> | it would get interpreted as `y * (k + x)' |
2024-12-21 15:41:05 +0100 | <ski> | yea, that too |
2024-12-21 15:46:06 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 252 seconds) |
2024-12-21 15:46:45 +0100 | <probie> | ski: Pretty much all the APL descendants (APL itself, K, J, Q, BQN) already do this, and their users seems satisfied with how `y*k+x` is parsed |
2024-12-21 15:47:22 +0100 | <ski> | iirc, Smalltalk also does this (although to the left, not to the right) |
2024-12-21 15:48:21 +0100 | <ski> | enikar : then there's the concatenative languages |
2024-12-21 15:50:19 +0100 | <probie> | Re smalltalk: That's right, because x+k*y is (using pseudo-Java syntax) `x.Plus(k).Mult(y)` |
2024-12-21 15:50:22 +0100 | meritamen | (~user@user/meritamen) (Remote host closed the connection) |
2024-12-21 15:52:21 +0100 | <enikar> | ski: concatenative languages? |
2024-12-21 15:52:40 +0100 | <probie> | languages like Forth and Factor |
2024-12-21 15:53:30 +0100 | <enikar> | I found that: https://en.wikipedia.org/wiki/Concatenative_programming_language |
2024-12-21 15:54:52 +0100 | <probie> | In a concatenative programming language, If I have a function `f` and a function `g`, their composition (written in Haskell as `f . g`) is just `g f` |
2024-12-21 15:56:59 +0100 | <enikar> | when I discovered forth it was a great moment :) |
2024-12-21 15:57:24 +0100 | <ski> | > run (lit 3 . lit 2 . mult . lit 1 . add) -- `3 * 2 + 1' |
2024-12-21 15:57:25 +0100 | <lambdabot> | 7 |
2024-12-21 15:57:33 +0100 | wootehfoot | (~wootehfoo@user/wootehfoot) (Ping timeout: 246 seconds) |
2024-12-21 15:57:39 +0100 | <ski> | > run (lit 1 . lit 3 . lit 2 . mult . add) -- `1 + 3 * 2' |
2024-12-21 15:57:57 +0100 | <lambdabot> | 7 |
2024-12-21 15:58:03 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 15:58:06 +0100 | <ski> | > run (lit 3 . lit 2 . sub) -- `3 - 2' |
2024-12-21 15:58:08 +0100 | <lambdabot> | 1 |
2024-12-21 15:58:17 +0100 | <ski> | > run (lit 3 . lit 2 . swap_ . sub) -- `2 - 3' |
2024-12-21 15:58:19 +0100 | <lambdabot> | -1 |
2024-12-21 15:58:36 +0100 | <ski> | > run (lit 3 . dup . mult) -- `3 * 3' |
2024-12-21 15:58:37 +0100 | <lambdabot> | 9 |
2024-12-21 15:58:44 +0100 | <ski> | enikar : like that ^ |
2024-12-21 15:58:54 +0100 | <enikar> | yes :) |
2024-12-21 15:59:51 +0100 | <ski> | (btw, note how `foo . bar' does the word `foo' first, and then the word `bar', not the other way around) |
2024-12-21 16:01:28 +0100 | <enikar> | oh! I see! |
2024-12-21 16:01:30 +0100 | <ski> | probie : *nod* (re Smalltalk) |
2024-12-21 16:01:59 +0100 | <ski> | enikar : .. which may be unexpected/surprising (re your comment about `f . g' above) |
2024-12-21 16:02:20 +0100 | <enikar> | yes it is |
2024-12-21 16:02:30 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 260 seconds) |
2024-12-21 16:03:42 +0100 | <ski> | (er, sorry, that was probie who said that) |
2024-12-21 16:04:27 +0100 | <ski> | enikar : <https://en.wikipedia.org/wiki/Threaded_code> is also interesting |
2024-12-21 16:04:33 +0100 | <enikar> | never mind :) |
2024-12-21 16:05:33 +0100 | <probie> | I'm not sure if I'd call it a truly concatenative language, but Uiuia is stack based language in which Haskell's `f . g` is written as `f g`. However `f\ng` (where \n is a literal newline) is the same as `g f`. |
2024-12-21 16:05:48 +0100 | wootehfoot | (~wootehfoo@user/wootehfoot) wootehfoot |
2024-12-21 16:05:55 +0100 | <ski> | that's interesting |
2024-12-21 16:06:22 +0100 | <ski> | probie : does it have `swap',`drop' and `dup' ? |
2024-12-21 16:07:14 +0100 | <enikar> | ski: thanks, I didn't know that, but I wrote a simple calculator that used threaded code. |
2024-12-21 16:07:37 +0100 | youthlic | (~Thunderbi@user/youthlic) (Quit: youthlic) |
2024-12-21 16:10:49 +0100 | <probie> | ski: yes, but it since it's also inspired by APL and therefore everything important needs to be a single character, they're most commonly spelled `:`, `◌` and `.` respectively |
2024-12-21 16:13:21 +0100 | <probie> | e.g. `3 4 swap drop dup *` would be `×.◌:3 4` |
2024-12-21 16:13:22 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 16:13:39 +0100 | ski | nods |
2024-12-21 16:13:50 +0100 | <probie> | sorry, `×.◌:4 3` |
2024-12-21 16:13:59 +0100 | youthlic | (~Thunderbi@user/youthlic) youthlic |
2024-12-21 16:14:01 +0100 | youthlic | (~Thunderbi@user/youthlic) (Client Quit) |
2024-12-21 16:15:04 +0100 | <enikar> | APL is too odd |
2024-12-21 16:15:42 +0100 | tremon | (~tremon@83.80.159.219) (Quit: getting boxed in) |
2024-12-21 16:17:41 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 248 seconds) |
2024-12-21 16:18:32 +0100 | CrunchyFlakes | (~CrunchyFl@31.19.233.78) (Read error: Connection reset by peer) |
2024-12-21 16:20:23 +0100 | CrunchyFlakes | (~CrunchyFl@ip1f13e94e.dynamic.kabel-deutschland.de) |
2024-12-21 16:22:01 +0100 | ephilalethes | (~noumenon@202.186.203.84) (Read error: Connection reset by peer) |
2024-12-21 16:28:42 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 16:33:01 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 252 seconds) |
2024-12-21 16:34:52 +0100 | wootehfoot | (~wootehfoo@user/wootehfoot) (Ping timeout: 252 seconds) |
2024-12-21 16:39:43 +0100 | ft | (~ft@p508db9c7.dip0.t-ipconnect.de) (Ping timeout: 264 seconds) |
2024-12-21 16:43:03 +0100 | ljdarj | (~Thunderbi@user/ljdarj) ljdarj |
2024-12-21 16:43:14 +0100 | Smiles | (uid551636@id-551636.lymington.irccloud.com) (Quit: Connection closed for inactivity) |
2024-12-21 16:44:03 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 16:46:09 +0100 | ft | (~ft@p508db070.dip0.t-ipconnect.de) ft |
2024-12-21 16:48:47 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 265 seconds) |
2024-12-21 16:49:59 +0100 | <hellwolf> | Question: even with NoImplicitPrelude, GHC.Types seem still imported |
2024-12-21 16:50:09 +0100 | <hellwolf> | hence Int, Bool, etc. are all available. |
2024-12-21 16:50:24 +0100 | <hellwolf> | can one go further to strip those away? |
2024-12-21 16:54:27 +0100 | alecs | (~alecs@61.pool85-58-154.dynamic.orange.es) alecs |
2024-12-21 16:57:33 +0100 | <probie> | hellwolf: are you sure? They're not imported for me. If I run `ghci -XNoImplicitPrelude` and ask `:k Int` I definitely get a "Not in scope" error |
2024-12-21 16:57:50 +0100 | MyNetAz | (~MyNetAz@user/MyNetAz) (Read error: Connection reset by peer) |
2024-12-21 16:57:56 +0100 | <hellwolf> | you are right. |
2024-12-21 16:58:10 +0100 | <hellwolf> | I did :Set -XNoImplicitPrelude afterwards |
2024-12-21 16:58:25 +0100 | gmg | (~user@user/gehmehgeh) (Quit: Leaving) |
2024-12-21 16:58:48 +0100 | alecs | (~alecs@61.pool85-58-154.dynamic.orange.es) (Ping timeout: 246 seconds) |
2024-12-21 16:58:50 +0100 | ethantwardy | (user@user/ethantwardy) (Quit: WeeChat 4.4.2) |
2024-12-21 16:59:27 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 17:01:01 +0100 | ethantwardy | (user@user/ethantwardy) ethantwardy |
2024-12-21 17:02:32 +0100 | tzh | (~tzh@c-76-115-131-146.hsd1.or.comcast.net) tzh |
2024-12-21 17:04:51 +0100 | MyNetAz | (~MyNetAz@user/MyNetAz) MyNetAz |
2024-12-21 17:06:31 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 252 seconds) |
2024-12-21 17:14:43 +0100 | ethantwardy | (user@user/ethantwardy) (Quit: WeeChat 4.4.2) |
2024-12-21 17:17:29 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 17:18:26 +0100 | ethantwardy | (user@user/ethantwardy) ethantwardy |
2024-12-21 17:22:08 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 265 seconds) |
2024-12-21 17:25:50 +0100 | sprotte24 | (~sprotte24@p200300d16f1a2c0064c6ee858fd5dcfe.dip0.t-ipconnect.de) (Quit: Leaving) |
2024-12-21 17:27:32 +0100 | ethantwardy | (user@user/ethantwardy) (Quit: WeeChat 4.4.2) |
2024-12-21 17:27:55 +0100 | tnt2 | (~Thunderbi@user/tnt1) tnt1 |
2024-12-21 17:28:57 +0100 | tnt1 | (~Thunderbi@user/tnt1) (Ping timeout: 244 seconds) |
2024-12-21 17:28:57 +0100 | tnt2 | tnt1 |
2024-12-21 17:32:53 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 17:33:41 +0100 | Smiles | (uid551636@id-551636.lymington.irccloud.com) Smiles |
2024-12-21 17:36:10 +0100 | ethantwardy | (user@user/ethantwardy) ethantwardy |
2024-12-21 17:37:09 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 248 seconds) |
2024-12-21 17:37:31 +0100 | ethantwardy | (user@user/ethantwardy) (Client Quit) |
2024-12-21 17:41:52 +0100 | ethantwardy | (user@user/ethantwardy) ethantwardy |
2024-12-21 17:42:39 +0100 | machinedgod | (~machinedg@d108-173-18-100.abhsia.telus.net) (Ping timeout: 272 seconds) |
2024-12-21 17:43:38 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 17:45:31 +0100 | ethantwardy | (user@user/ethantwardy) (Client Quit) |
2024-12-21 17:47:13 +0100 | ethantwardy | (user@user/ethantwardy) ethantwardy |
2024-12-21 17:47:45 +0100 | ethantwardy | (user@user/ethantwardy) (Client Quit) |
2024-12-21 17:48:29 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 260 seconds) |
2024-12-21 17:49:28 +0100 | ethantwardy | (user@user/ethantwardy) ethantwardy |
2024-12-21 17:50:02 +0100 | ethantwardy | (user@user/ethantwardy) (Client Quit) |
2024-12-21 17:51:22 +0100 | ethantwardy | (user@user/ethantwardy) ethantwardy |
2024-12-21 17:52:25 +0100 | ethantwardy | (user@user/ethantwardy) (Client Quit) |
2024-12-21 17:53:56 +0100 | rachelambda8 | (~rachelamb@cust-95-80-25-71.csbnet.se) (Quit: β reduced) |
2024-12-21 17:54:21 +0100 | ethantwardy | (user@user/ethantwardy) ethantwardy |
2024-12-21 17:54:54 +0100 | ethantwardy | (user@user/ethantwardy) (Client Quit) |
2024-12-21 17:56:18 +0100 | ethantwardy | (user@user/ethantwardy) ethantwardy |
2024-12-21 17:57:02 +0100 | ethantwardy | (user@user/ethantwardy) (Client Quit) |
2024-12-21 17:57:22 +0100 | tnt1 | (~Thunderbi@user/tnt1) (Ping timeout: 252 seconds) |
2024-12-21 17:57:25 +0100 | ljdarj | (~Thunderbi@user/ljdarj) (Ping timeout: 265 seconds) |
2024-12-21 17:57:46 +0100 | tnt1 | (~Thunderbi@user/tnt1) tnt1 |
2024-12-21 17:59:02 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 18:00:46 +0100 | ethantwardy | (user@user/ethantwardy) ethantwardy |
2024-12-21 18:00:58 +0100 | tnt2 | (~Thunderbi@user/tnt1) tnt1 |
2024-12-21 18:02:09 +0100 | tnt1 | (~Thunderbi@user/tnt1) (Ping timeout: 248 seconds) |
2024-12-21 18:02:10 +0100 | tnt2 | tnt1 |
2024-12-21 18:03:45 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 248 seconds) |
2024-12-21 18:13:30 +0100 | toch | (toch@user/toch) (Ping timeout: 252 seconds) |
2024-12-21 18:14:25 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 18:19:04 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 244 seconds) |
2024-12-21 18:28:00 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 18:32:57 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 246 seconds) |
2024-12-21 18:33:18 +0100 | ljdarj | (~Thunderbi@user/ljdarj) ljdarj |
2024-12-21 18:39:33 +0100 | <WzC> | Hmm, does anyone know if I can/how to use coerce to coerce some phantom parameter from one kind into another? More concretely; I would like this to just work : https://paste.tomsmeding.com/MdEGcxHR (and I feel it should, sicne 's' and the kind is universally quantified anyway |
2024-12-21 18:40:14 +0100 | <WzC> | I think something like this used to work (porting some old code to newer ghc's, but now s.t. like this gives an error) |
2024-12-21 18:42:28 +0100 | toch | (toch@user/toch) toch |
2024-12-21 18:44:03 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-21 18:45:58 +0100 | <ski> | type role Foo phantom -- does adding this help ? (need `RoleAnnotations') |
2024-12-21 18:46:45 +0100 | <WzC> | unfortunately not |
2024-12-21 18:47:09 +0100 | michalz | (~michalz@185.246.207.203) |
2024-12-21 18:47:16 +0100 | <WzC> | I think the issue is that the coercible typeclass seems to actually have kind annotations that force that the types have to have the same kind |
2024-12-21 18:47:40 +0100 | <WzC> | i.e. the haddocks now say: class a ~R# b => Coercible (a :: k) (b :: k) |
2024-12-21 18:49:58 +0100 | <ski> | hm, can you do `data Foo k (s :: k) = Foo' ? |
2024-12-21 18:50:20 +0100 | lxsameer | (~lxsameer@Serene/lxsameer) lxsameer |
2024-12-21 18:50:30 +0100 | ski | wonders whether that might help |
2024-12-21 18:50:54 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 252 seconds) |
2024-12-21 18:51:49 +0100 | <WzC> | interesting idea; doesn't seem to though :( |