Newest at the top
2024-12-23 19:39:06 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 265 seconds) |
2024-12-23 19:36:35 +0100 | <ski> | nesting modules would sometimes be neat |
2024-12-23 19:35:08 +0100 | forell | (~forell@user/forell) (Ping timeout: 272 seconds) |
2024-12-23 19:34:30 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-23 19:32:20 +0100 | dsrt^ | (krt@c-98-242-74-66.hsd1.ga.comcast.net) (Ping timeout: 244 seconds) |
2024-12-23 19:32:01 +0100 | machinedgod | (~machinedg@d108-173-18-100.abhsia.telus.net) machinedgod |
2024-12-23 19:28:06 +0100 | manwithluck | (~manwithlu@194.177.28.164) (Ping timeout: 252 seconds) |
2024-12-23 19:24:04 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 260 seconds) |
2024-12-23 19:21:27 +0100 | Lord_of_Life | (~Lord@user/lord-of-life/x-2819915) Lord_of_Life |
2024-12-23 19:21:07 +0100 | Lord_of_Life | (~Lord@user/lord-of-life/x-2819915) (Ping timeout: 252 seconds) |
2024-12-23 19:19:30 +0100 | Jeanne-Kamikaze | (~Jeanne-Ka@79.127.217.49) Jeanne-Kamikaze |
2024-12-23 19:19:07 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-23 19:11:27 +0100 | Smiles | (uid551636@id-551636.lymington.irccloud.com) (Quit: Connection closed for inactivity) |
2024-12-23 19:10:53 +0100 | <hseg> | welp, code structure is forcing my hand anyway -- a bunch of transitive imports means my shims end up being imported together, causing ambiguity |
2024-12-23 19:09:12 +0100 | dsrt^ | (krt@c-98-242-74-66.hsd1.ga.comcast.net) |
2024-12-23 19:08:53 +0100 | talismanick | (~user@2601:644:937c:ed10::ae5) (Remote host closed the connection) |
2024-12-23 19:08:18 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 252 seconds) |
2024-12-23 19:06:16 +0100 | <hololeap> | it seems like a lot of libraries try to keep text-1.* support which I'm sure brings in a lot of CPP |
2024-12-23 19:05:46 +0100 | <hololeap> | like, I don't think "text >=2" is a terrible thing, esp for personal/private projects |
2024-12-23 19:05:02 +0100 | <hseg> | yeah |
2024-12-23 19:04:31 +0100 | <hololeap> | it's either that or make the constraints on your dependencies really tight |
2024-12-23 19:03:44 +0100 | <hseg> | so you just pollute your version constraints with "for this version, I need this compatibility shim" rather than the code itself |
2024-12-23 19:03:44 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) merijn |
2024-12-23 19:02:29 +0100 | <hseg> | tbh, this feels like one of those things that a more backpack-y ecosystem might do better |
2024-12-23 19:02:23 +0100 | manny__ | (~manny@static-68-235-46-164.cust.tzulo.com) (Quit: Quit) |
2024-12-23 19:01:30 +0100 | <hseg> | hm, that _is_ a fair point |
2024-12-23 19:01:18 +0100 | <hseg> | right. I'm more referring to the fact that I'm stuck either duplicating the test or moving the import, neither of which is good for readability |
2024-12-23 19:01:11 +0100 | <hololeap> | I guess you could shove the CPP stuff into its own module so it isn't stinking up the rest of your code :p |
2024-12-23 19:00:40 +0100 | manwithluck | (~manwithlu@194.177.28.164) manwithluck |
2024-12-23 18:59:50 +0100 | <hololeap> | a necessary evil sometimes |
2024-12-23 18:59:38 +0100 | <hololeap> | CPP is never very pretty. it's usually just a compatibility shim |
2024-12-23 18:59:23 +0100 | <hseg> | ... actually no, idk that that's that much more readable |
2024-12-23 18:58:58 +0100 | <hseg> | fair. a bit of a shame, though, though tbf otoh that forces the code to be somewhat more readable |
2024-12-23 18:58:27 +0100 | <hololeap> | like, one for the import and one for the actual code |
2024-12-23 18:58:15 +0100 | <hellwolf> | Btw, talking about interleaving imports and definitions; I would even go further, say, defining multiple modules in a single file could be rad for writing single file cabal scripts, e.g. |
2024-12-23 18:58:11 +0100 | <hololeap> | you might have to split it up into several identical #if blocks |
2024-12-23 18:57:58 +0100 | <hseg> | (so to support old and new versions, I need to define a shim) |
2024-12-23 18:57:43 +0100 | <hellwolf> | Noted. I am sold. I will give it a look. |
2024-12-23 18:57:43 +0100 | <hellwolf> | 12-23 19:54 <hololeap> it's a super useful package, definitely one to keep in your toolbox |
2024-12-23 18:57:34 +0100 | <hseg> | (optparse-applicative renamed text :: String -> Doc to pretty :: String -> Doc a) |
2024-12-23 18:57:19 +0100 | manwithluck | (~manwithlu@194.177.28.164) (Read error: Connection reset by peer) |
2024-12-23 18:57:11 +0100 | <hseg> | hm. am encountering this since I'm using CPP to conditionally define a shim |
2024-12-23 18:56:12 +0100 | <c_wraith> | yeah. imports have to be at the top. (more or less. after the module declaration) |
2024-12-23 18:55:20 +0100 | <hseg> | is it illegal to interleave definitions and imports? |
2024-12-23 18:54:04 +0100 | <hololeap> | it's a super useful package, definitely one to keep in your toolbox |
2024-12-23 18:53:34 +0100 | <hololeap> | well, mapMaybe is generalized to Functors, 'wither' is like a stronger traverse that can remove elements |
2024-12-23 18:53:11 +0100 | merijn | (~merijn@128-137-045-062.dynamic.caiway.nl) (Ping timeout: 265 seconds) |
2024-12-23 18:52:40 +0100 | <hellwolf> | btw, I just finished the latest haskell interlude podcast: https://haskell.foundation/podcast/60/ . good talk, recommended to listen in. |
2024-12-23 18:52:14 +0100 | <hellwolf> | i see |
2024-12-23 18:51:30 +0100 | <hololeap> | it generalizes mapMaybe to other applicatives besides lists |