2024-08-30 00:07:22 +0200 | sawilagar | (~sawilagar@user/sawilagar) (Ping timeout: 265 seconds) |
2024-08-30 00:18:05 +0200 | peterbecich | (~Thunderbi@syn-047-229-123-186.res.spectrum.com) |
2024-08-30 00:24:28 +0200 | nshepperd | (~nshepperd@li364-218.members.linode.com) |
2024-08-30 00:25:20 +0200 | weary-traveler | (~user@user/user363627) |
2024-08-30 00:30:26 +0200 | <int-e> | tfw you copy the Complex data type and the Num instance and rip out `abs` and `signum` so that it works for Num instead of RealFloat :-/ |
2024-08-30 00:44:12 +0200 | <yin> | types can be infix? |
2024-08-30 00:45:23 +0200 | Pixi | (~Pixi@user/pixi) |
2024-08-30 00:51:59 +0200 | <int-e> | That's a GHC extension, TypeOperators |
2024-08-30 00:52:12 +0200 | <int-e> | data constructors can be infix in Haskell98 |
2024-08-30 00:52:38 +0200 | <int-e> | using operators starting with : (not including : or ::) |
2024-08-30 00:55:54 +0200 | Tuplanolla | (~Tuplanoll@91-159-69-59.elisa-laajakaista.fi) (Quit: Leaving.) |
2024-08-30 01:04:53 +0200 | acidjnk_new | (~acidjnk@p200300d6e72cfb18ac0e327209850a07.dip0.t-ipconnect.de) (Ping timeout: 248 seconds) |
2024-08-30 01:05:10 +0200 | <yin> | i see |
2024-08-30 01:07:06 +0200 | <yin> | can i import type operators? |
2024-08-30 01:07:31 +0200 | <yin> | import Data.Modular ( ? ) |
2024-08-30 01:07:53 +0200 | dehsou^ | (~dehsou@c-98-242-74-66.hsd1.ga.comcast.net) |
2024-08-30 01:10:57 +0200 | troojg | (~troojg@user/troojg) |
2024-08-30 01:12:52 +0200 | <geekosaur> | as usual, wrap operators in parens |
2024-08-30 01:13:54 +0200 | <probie> | If it's at both value level and type level, you might need `import Data.Module ( type(?) )` or something (I think that's the right syntax, but I'm not 100% sure) |
2024-08-30 01:33:56 +0200 | neuroevolutus | (~neuroevol@206.217.206.115) |
2024-08-30 01:37:10 +0200 | son0p | (~ff@186.121.18.131) (Killed (NickServ (GHOST command used by son0p-!~ff@2800:e2:f80:ee7::3))) |
2024-08-30 01:37:48 +0200 | <Axman6> | lystra: have you added a new field to whatever type is being constructed my mempty? |
2024-08-30 01:38:08 +0200 | son0p | (~ff@186.121.18.131) |
2024-08-30 01:38:52 +0200 | neuroevolutus | (~neuroevol@206.217.206.115) (Quit: Client closed) |
2024-08-30 01:41:35 +0200 | <yin> | probie: that's it, thanks. `import Data.Modular ( type(/) )` |
2024-08-30 01:44:24 +0200 | raehik | (~raehik@rdng-25-b2-v4wan-169990-cust1344.vm39.cable.virginm.net) (Ping timeout: 252 seconds) |
2024-08-30 01:57:02 +0200 | <lystra> | Axman6: Nope. Let me check. |
2024-08-30 01:58:14 +0200 | <Axman6> | I'm a bit surprised there isn't an error on line 16 of the diff if the field doesn't exist though |
2024-08-30 01:58:29 +0200 | lol_ | (~lol@2603:3016:1e01:b960:f4ac:a003:2d11:ead1) |
2024-08-30 01:58:37 +0200 | <Axman6> | oh that is the error, yeah that makes sense, that field doesn't exiswt |
2024-08-30 01:58:39 +0200 | <Axman6> | exist* |
2024-08-30 01:59:47 +0200 | Square | (~Square@user/square) (Ping timeout: 252 seconds) |
2024-08-30 02:01:59 +0200 | jcarpenter2 | (~lol@2603:3016:1e01:b960:a04f:145c:6e83:611e) (Ping timeout: 260 seconds) |
2024-08-30 02:05:30 +0200 | Buliarous | (~gypsydang@46.232.210.139) |
2024-08-30 02:11:16 +0200 | chiselfuse | (~chiselfus@user/chiselfuse) (Ping timeout: 260 seconds) |
2024-08-30 02:13:10 +0200 | chiselfuse | (~chiselfus@user/chiselfuse) |
2024-08-30 02:13:48 +0200 | spew | (~spew@201.141.99.170) |
2024-08-30 02:23:32 +0200 | cbarrett | (sid192934@helmsley.irccloud.com) (Read error: Connection reset by peer) |
2024-08-30 02:23:37 +0200 | iphy | (sid67735@user/iphy) (Ping timeout: 252 seconds) |
2024-08-30 02:23:38 +0200 | buhman | (sid411355@user/buhman) (Ping timeout: 252 seconds) |
2024-08-30 02:23:43 +0200 | cbarrett | (sid192934@id-192934.helmsley.irccloud.com) |
2024-08-30 02:23:44 +0200 | totbwf | (uid402332@uxbridge.irccloud.com) (Read error: Connection reset by peer) |
2024-08-30 02:23:44 +0200 | edwardk | (sid47016@haskell/developer/edwardk) (Read error: Connection reset by peer) |
2024-08-30 02:23:49 +0200 | jackdk | (sid373013@cssa/jackdk) (Ping timeout: 248 seconds) |
2024-08-30 02:23:52 +0200 | totbwf | (uid402332@id-402332.uxbridge.irccloud.com) |
2024-08-30 02:23:55 +0200 | edwardk | (sid47016@haskell/developer/edwardk) |
2024-08-30 02:23:57 +0200 | degraafk | (sid71464@lymington.irccloud.com) (Read error: Connection reset by peer) |
2024-08-30 02:24:00 +0200 | Fangs | (sid141280@hampstead.irccloud.com) (Ping timeout: 252 seconds) |
2024-08-30 02:24:00 +0200 | caasih | (sid13241@ilkley.irccloud.com) (Ping timeout: 252 seconds) |
2024-08-30 02:24:08 +0200 | degraafk | (sid71464@id-71464.lymington.irccloud.com) |
2024-08-30 02:24:21 +0200 | shawwwn | (sid6132@helmsley.irccloud.com) (Ping timeout: 248 seconds) |
2024-08-30 02:24:21 +0200 | delyan_ | (sid523379@hampstead.irccloud.com) (Ping timeout: 248 seconds) |
2024-08-30 02:24:43 +0200 | Kamuela | (sid111576@tinside.irccloud.com) (Ping timeout: 252 seconds) |
2024-08-30 02:24:43 +0200 | bjs | (sid190364@user/bjs) (Ping timeout: 252 seconds) |
2024-08-30 02:27:00 +0200 | iphy | (sid67735@user/iphy) |
2024-08-30 02:27:00 +0200 | delyan_ | (sid523379@id-523379.hampstead.irccloud.com) |
2024-08-30 02:27:02 +0200 | shawwwn | (sid6132@id-6132.helmsley.irccloud.com) |
2024-08-30 02:27:03 +0200 | jackdk | (sid373013@cssa/jackdk) |
2024-08-30 02:27:03 +0200 | Kamuela | (sid111576@id-111576.tinside.irccloud.com) |
2024-08-30 02:27:06 +0200 | bjs | (sid190364@user/bjs) |
2024-08-30 02:27:06 +0200 | buhman | (sid411355@user/buhman) |
2024-08-30 02:27:07 +0200 | Fangs | (sid141280@id-141280.hampstead.irccloud.com) |
2024-08-30 02:28:01 +0200 | caasih | (sid13241@id-13241.ilkley.irccloud.com) |
2024-08-30 02:30:30 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 02:30:46 +0200 | ddellacosta | (~ddellacos@ool-44c73c8f.dyn.optonline.net) |
2024-08-30 02:32:04 +0200 | califax | (~califax@user/califx) (Remote host closed the connection) |
2024-08-30 02:33:34 +0200 | califax | (~califax@user/califx) |
2024-08-30 02:34:54 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 246 seconds) |
2024-08-30 02:38:04 +0200 | <lystra> | Looks like I need to update libraries/Cabal/Cabal-syntax/src/Distribution/Types/BuildInfo.hs but I think ldOptions might contain any non-L flags so I'll play around with that first. |
2024-08-30 02:40:26 +0200 | <Axman6> | yeah I guess if it's just another linker option, then that would be fine |
2024-08-30 02:42:24 +0200 | peterbecich | (~Thunderbi@syn-047-229-123-186.res.spectrum.com) (Ping timeout: 260 seconds) |
2024-08-30 02:43:02 +0200 | <yin> | should we expect much difference between `join . words` and `filter (not . isSpace)` ? |
2024-08-30 02:45:54 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 02:46:01 +0200 | <haskellbridge> | <zwro> hmm.. i wonder if `join.words` gets optimized in that way |
2024-08-30 02:46:08 +0200 | <EvanR> | well the first one logically rebuilds the list twice, while the second one once |
2024-08-30 02:46:19 +0200 | <EvanR> | but there's the reality of compilation |
2024-08-30 02:46:53 +0200 | <yin> | yes i'm assuming optimization. that's really my question |
2024-08-30 02:47:32 +0200 | <yin> | unfortunately i'm in no position to try it out at the moment |
2024-08-30 02:51:17 +0200 | <yin> | `join . words` feels more elegant |
2024-08-30 02:51:59 +0200 | <yin> | wonder if we can count on some type of "fusion" in this case |
2024-08-30 02:53:00 +0200 | <EvanR> | @src words |
2024-08-30 02:53:00 +0200 | <lambdabot> | words s = case dropWhile isSpace s of |
2024-08-30 02:53:00 +0200 | <lambdabot> | "" -> [] |
2024-08-30 02:53:01 +0200 | <lambdabot> | s' -> w : words s'' where (w, s'') = break isSpace s' |
2024-08-30 02:53:09 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 248 seconds) |
2024-08-30 02:53:15 +0200 | <EvanR> | @src filter |
2024-08-30 02:53:15 +0200 | <lambdabot> | filter _ [] = [] |
2024-08-30 02:53:15 +0200 | <lambdabot> | filter p (x:xs) |
2024-08-30 02:53:15 +0200 | <lambdabot> | | p x = x : filter p xs |
2024-08-30 02:53:15 +0200 | <lambdabot> | | otherwise = filter p xs |
2024-08-30 02:53:41 +0200 | <EvanR> | not that that is the real source |
2024-08-30 02:53:56 +0200 | <EvanR> | but it's very similar |
2024-08-30 03:04:09 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 03:08:44 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 252 seconds) |
2024-08-30 03:10:10 +0200 | <d34df00d> | Ugh. |
2024-08-30 03:10:16 +0200 | <d34df00d> | Since when `foo :: Bool -> Num a => a` is a legit haskell? |
2024-08-30 03:10:21 +0200 | <d34df00d> | (without any extensions enabled) |
2024-08-30 03:10:35 +0200 | <EvanR> | forever I think |
2024-08-30 03:10:49 +0200 | <EvanR> | it's the same as Bool -> (Num a => a) |
2024-08-30 03:10:58 +0200 | <d34df00d> | Hmm, ghc 9.0 gets upset: https://gcc.godbolt.org/z/8eGYYn1xv |
2024-08-30 03:11:07 +0200 | <d34df00d> | Yes, but it requires RankNTypes, just as ghc 9.0 correctly says. |
2024-08-30 03:11:38 +0200 | <EvanR> | that's a rank 1 type |
2024-08-30 03:11:57 +0200 | <d34df00d> | So I'm curious whether it's ghc 9.0 indeed correct, or whether it's actually allowed by Haskell 98/2010 since it's not really a rank-n. |
2024-08-30 03:11:58 +0200 | <d34df00d> | Yeah. |
2024-08-30 03:13:14 +0200 | <d34df00d> | Or, I shall say, it could be converted to a rank-1 type, to be more precise. |
2024-08-30 03:14:51 +0200 | <d34df00d> | EvanR: yep, if you try to define it as `foo = const 1`, you'll get "Couldn't match type ‘a0’ with ‘Num a => a’ // Expected: Bool -> Num a => a // Actual: Bool -> a0" |
2024-08-30 03:15:34 +0200 | <d34df00d> | `foo = undefined` also fails to unify unless I enable -XImpredicativeTypes. |
2024-08-30 03:15:36 +0200 | <EvanR> | const 1 obviously doesn't type check |
2024-08-30 03:15:58 +0200 | <EvanR> | er |
2024-08-30 03:16:01 +0200 | <EvanR> | :t const 1 |
2024-08-30 03:16:02 +0200 | <lambdabot> | Num a => b -> a |
2024-08-30 03:16:25 +0200 | <EvanR> | yeah |
2024-08-30 03:16:33 +0200 | <d34df00d> | Is `Num a => b -> a` ~ `b -> Num a => a`? |
2024-08-30 03:17:35 +0200 | <haskellbridge> | <zwro> this is news to me |
2024-08-30 03:18:18 +0200 | <EvanR> | that can be asked by using a type equality GADT |
2024-08-30 03:18:24 +0200 | <EvanR> | with Refl as the constructor |
2024-08-30 03:18:41 +0200 | <d34df00d> | EvanR: the particular error message with `const 1` is "Cannot instantiate unification variable ‘a0’ with a type involving polytypes: Num a => a" which suggests to me that at least part of ghc considers this to be a rank-2. |
2024-08-30 03:19:19 +0200 | <EvanR> | it seems so, but you didn't put an explicit forall, in which case I want my money back |
2024-08-30 03:19:34 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 03:19:45 +0200 | <d34df00d> | That was kinda my original question tho :) |
2024-08-30 03:20:06 +0200 | <EvanR> | stuff can be higher rank without explicit forall? balderdash! |
2024-08-30 03:20:55 +0200 | <d34df00d> | Ok, I'm lazy, so I didn't do the GADT test and instead just `bar :: (b -> Num a => a) ~ (Num a => b -> a) => ()` |
2024-08-30 03:20:57 +0200 | <d34df00d> | This fails to typecheck. |
2024-08-30 03:23:12 +0200 | <d34df00d> | `foo :: forall a. Bool -> Num a => a` behaves funny too tho. `foo = const 1` still complains about polytypes, while `foo = undefined` now unifies. |
2024-08-30 03:23:14 +0200 | <EvanR> | yeah const 1 earlier also basically proved that |
2024-08-30 03:24:05 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 248 seconds) |
2024-08-30 03:33:10 +0200 | lol_ | jcarpenter2 |
2024-08-30 03:34:58 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 03:37:40 +0200 | peterbecich | (~Thunderbi@syn-047-229-123-186.res.spectrum.com) |
2024-08-30 03:38:09 +0200 | Axman6 | (~Axman6@user/axman6) (Ping timeout: 240 seconds) |
2024-08-30 03:39:05 +0200 | spew | (~spew@201.141.99.170) (Quit: spew) |
2024-08-30 03:39:33 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 265 seconds) |
2024-08-30 03:49:00 +0200 | troojg | (~troojg@user/troojg) (Ping timeout: 276 seconds) |
2024-08-30 03:49:19 +0200 | <lystra> | Just decided to do runhaskell Setup.hs configure --ghc-options="-optl-Wl,-rpath,/path/to/lib" in the end. Seems to work. |
2024-08-30 03:50:25 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 03:56:05 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 248 seconds) |
2024-08-30 04:06:47 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 04:11:09 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 246 seconds) |
2024-08-30 04:17:24 +0200 | ZharMeny | (~ZharMeny@user/ZharMeny) (Quit: \) |
2024-08-30 04:22:10 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 04:23:41 +0200 | ec | (~ec@gateway/tor-sasl/ec) (Ping timeout: 260 seconds) |
2024-08-30 04:29:09 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 260 seconds) |
2024-08-30 04:39:54 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 04:44:23 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 255 seconds) |
2024-08-30 04:45:58 +0200 | tabemann_ | tabemann |
2024-08-30 04:55:19 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 04:59:05 +0200 | ec | (~ec@gateway/tor-sasl/ec) |
2024-08-30 05:00:08 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 272 seconds) |
2024-08-30 05:00:08 +0200 | td_ | (~td@i53870918.versanet.de) (Ping timeout: 272 seconds) |
2024-08-30 05:01:50 +0200 | td_ | (~td@i5387090B.versanet.de) |
2024-08-30 05:10:45 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 05:12:40 +0200 | aforemny_ | (~aforemny@2001:9e8:6cc8:4500:8afd:cf35:f7f8:813a) |
2024-08-30 05:13:01 +0200 | aforemny | (~aforemny@i59F516D8.versanet.de) (Ping timeout: 252 seconds) |
2024-08-30 05:15:13 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 252 seconds) |
2024-08-30 05:20:59 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 05:24:17 +0200 | Lord_of_Life_ | (~Lord@user/lord-of-life/x-2819915) |
2024-08-30 05:24:26 +0200 | Lord_of_Life | (~Lord@user/lord-of-life/x-2819915) (Ping timeout: 255 seconds) |
2024-08-30 05:25:37 +0200 | Lord_of_Life_ | Lord_of_Life |
2024-08-30 05:29:57 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 248 seconds) |
2024-08-30 05:32:32 +0200 | ski | (~ski@145.224.119.31) (Ping timeout: 255 seconds) |
2024-08-30 05:33:23 +0200 | ski | (~ski@217.65.136.250) |
2024-08-30 05:41:03 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 05:45:34 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 260 seconds) |
2024-08-30 05:50:07 +0200 | takuan | (~takuan@178-116-218-225.access.telenet.be) |
2024-08-30 05:56:26 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 05:58:16 +0200 | peterbecich | (~Thunderbi@syn-047-229-123-186.res.spectrum.com) (Ping timeout: 265 seconds) |
2024-08-30 06:00:42 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 246 seconds) |
2024-08-30 06:10:26 +0200 | Axman6 | (~Axman6@user/axman6) |
2024-08-30 06:11:51 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 06:17:12 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 276 seconds) |
2024-08-30 06:22:01 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 06:25:39 +0200 | gmg | (~user@user/gehmehgeh) |
2024-08-30 06:26:29 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 248 seconds) |
2024-08-30 06:28:07 +0200 | thegeekinside | (~thegeekin@189.217.87.225) |
2024-08-30 06:30:02 +0200 | thegeekinside | (~thegeekin@189.217.87.225) (Remote host closed the connection) |
2024-08-30 06:35:30 +0200 | youthlic | (~Thunderbi@user/youthlic) |
2024-08-30 06:42:00 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 06:43:06 +0200 | neuroevolutus | (~neuroevol@37.19.200.161) |
2024-08-30 06:45:49 +0200 | Ekho | (~Ekho@user/ekho) (Quit: CORE ERROR, SYSTEM HALTED.) |
2024-08-30 06:46:32 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 252 seconds) |
2024-08-30 06:52:00 +0200 | bliminse | (~bliminse@user/bliminse) (Quit: leaving) |
2024-08-30 06:54:10 +0200 | youthlic | (~Thunderbi@user/youthlic) (Ping timeout: 248 seconds) |
2024-08-30 06:57:12 +0200 | Ekho | (~Ekho@user/ekho) |
2024-08-30 06:57:26 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 07:01:20 +0200 | peterbecich | (~Thunderbi@syn-047-229-123-186.res.spectrum.com) |
2024-08-30 07:02:03 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 245 seconds) |
2024-08-30 07:04:38 +0200 | peterbecich1 | (~Thunderbi@syn-047-229-123-186.res.spectrum.com) |
2024-08-30 07:04:41 +0200 | michalz | (~michalz@185.246.207.197) |
2024-08-30 07:05:23 +0200 | peterbecich | (~Thunderbi@syn-047-229-123-186.res.spectrum.com) (Ping timeout: 245 seconds) |
2024-08-30 07:05:39 +0200 | peterbecich1 | peterbecich |
2024-08-30 07:12:58 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 07:15:46 +0200 | euphores | (~SASL_euph@user/euphores) (Quit: Leaving.) |
2024-08-30 07:17:19 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 252 seconds) |
2024-08-30 07:22:58 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 07:27:19 +0200 | euphores | (~SASL_euph@user/euphores) |
2024-08-30 07:27:30 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 246 seconds) |
2024-08-30 07:28:59 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 07:33:28 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 252 seconds) |
2024-08-30 07:42:11 +0200 | neuroevolutus | (~neuroevol@37.19.200.161) (Quit: Client closed) |
2024-08-30 07:51:30 +0200 | bliminse | (~bliminse@user/bliminse) |
2024-08-30 07:53:47 +0200 | bliminse | (~bliminse@user/bliminse) (Client Quit) |
2024-08-30 07:55:23 +0200 | bliminse | (~bliminse@user/bliminse) |
2024-08-30 07:58:32 +0200 | bliminse | (~bliminse@user/bliminse) (Client Quit) |
2024-08-30 07:59:41 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 08:01:59 +0200 | oo_miguel | (~Thunderbi@78.10.207.45) |
2024-08-30 08:02:18 +0200 | esnos | (~user@176.106.34.161) |
2024-08-30 08:03:50 +0200 | bliminse | (~bliminse@user/bliminse) |
2024-08-30 08:04:15 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 252 seconds) |
2024-08-30 08:04:59 +0200 | bliminse | (~bliminse@user/bliminse) (Client Quit) |
2024-08-30 08:05:05 +0200 | weary-traveler | (~user@user/user363627) (Remote host closed the connection) |
2024-08-30 08:05:52 +0200 | bliminse | (~bliminse@user/bliminse) |
2024-08-30 08:07:14 +0200 | <esnos> | Hi, I'm on arch linux and I want to use package Control.Monad.Random. I installed it via haskell-monadrandom package, but after restarting emacs, emacs still can't find package. I also tried to cabal install it, but I got error `Warning: Couldn't figure out linker information!` which I think is specific to arch linux. Do you know what can I do to see this package? |
2024-08-30 08:15:06 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 08:16:52 +0200 | <EvanR> | create a new cabal project and list the package in the deps |
2024-08-30 08:17:06 +0200 | <EvanR> | the default is to download and install the packages per project |
2024-08-30 08:17:31 +0200 | <EvanR> | unless this is broken on arch linux for some reason |
2024-08-30 08:18:04 +0200 | <esnos> | I'm just doing last assigment from cis 194, is it possible to globaly download haskell package? |
2024-08-30 08:18:23 +0200 | <c_wraith> | ultimately, system package managers are really bad at managing haskell libraries. (and mostly they don't even try) |
2024-08-30 08:18:39 +0200 | <EvanR> | it is possible to install them globally but it's usually a bad idea |
2024-08-30 08:18:51 +0200 | <esnos> | Or haskell packages on linux are only for other program in extra repo, not for lsp? |
2024-08-30 08:19:28 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 244 seconds) |
2024-08-30 08:19:50 +0200 | <EvanR> | doing an assignment for cis 194 is a good reason to make a project |
2024-08-30 08:19:59 +0200 | <esnos> | So something like cabal init cis_194, cabal update, cabal install MonadRandom would work? |
2024-08-30 08:20:34 +0200 | divya | (~user@202.170.201.250) |
2024-08-30 08:20:47 +0200 | <esnos> | EvanR: Should I have project for each assigment, or just one for all of them? |
2024-08-30 08:22:19 +0200 | <EvanR> | if there are no conflicts among any of the dependencies they could all be the same project |
2024-08-30 08:24:10 +0200 | <c_wraith> | note that if you're really doing small things (single module), cabal scripts have a lot less ceremony involved. https://cabal.readthedocs.io/en/stable/getting-started.html#running-a-single-file-haskell-script |
2024-08-30 08:24:28 +0200 | <c_wraith> | If they've got multiple modules, a full cabal project is easier to work with. |
2024-08-30 08:26:02 +0200 | <EvanR> | oh yeah, cabal script is good for 1 source file and you only need 1 dependency package |
2024-08-30 08:26:21 +0200 | <EvanR> | and you don't care about compile time |
2024-08-30 08:26:59 +0200 | <c_wraith> | if you've only got one source, *usually* compile times won't be bad. |
2024-08-30 08:28:00 +0200 | dysthesis | (~dysthesis@user/dysthesis) |
2024-08-30 08:30:04 +0200 | <esnos> | Didn't know about cabal scripts, can they replace python script? |
2024-08-30 08:30:32 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 08:30:35 +0200 | <esnos> | Also, now I have some problem with linker |
2024-08-30 08:30:40 +0200 | <esnos> | Love arch for haskell |
2024-08-30 08:32:11 +0200 | ft | (~ft@p4fc2a393.dip0.t-ipconnect.de) (Quit: leaving) |
2024-08-30 08:32:22 +0200 | <geekosaur> | (a) you can specify more than one dependency (b) cabal since 3.8 caches compiled scripts |
2024-08-30 08:32:49 +0200 | <mauke> | doesn't arch package a ghc that uses dynamic libraries or something? |
2024-08-30 08:34:13 +0200 | <geekosaur> | you want `ghc-options: -dynamic` on Arch |
2024-08-30 08:34:51 +0200 | <geekosaur> | installing `ghc-static` will work for bootlibs, but if you install any other Haskell package via pacman you won't be able to get static libraries |
2024-08-30 08:35:00 +0200 | <esnos> | geekosaur: where I can set it? |
2024-08-30 08:35:10 +0200 | rosco | (~rosco@175.136.158.234) |
2024-08-30 08:35:18 +0200 | <geekosaur> | in the cabal file, in the library or executable stanza |
2024-08-30 08:35:39 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 276 seconds) |
2024-08-30 08:35:39 +0200 | <geekosaur> | if you;'re using a cabal script, it goes in the cabal comment at the top |
2024-08-30 08:36:51 +0200 | lortabac | (~lortabac@2a01:e0a:541:b8f0:55ab:e185:7f81:54a4) |
2024-08-30 08:38:58 +0200 | CrunchyFlakes | (~CrunchyFl@ip-109-42-115-64.web.vodafone.de) |
2024-08-30 08:41:59 +0200 | <Inst> | esnos still here? |
2024-08-30 08:42:38 +0200 | <Inst> | the mainstream haskell community has a feud with the maintainers of archlinux packages on Haskell |
2024-08-30 08:43:30 +0200 | <Inst> | because afaik esnows installed via pacman, right? |
2024-08-30 08:43:40 +0200 | <geekosaur> | yes |
2024-08-30 08:44:28 +0200 | CrunchyFlakes | (~CrunchyFl@ip-109-42-115-64.web.vodafone.de) (Read error: Connection reset by peer) |
2024-08-30 08:45:56 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 08:46:59 +0200 | <Inst> | haskell arch linux seems to break standard Haskell tooling quite often |
2024-08-30 08:47:17 +0200 | <esnos> | Inst: Hi, yes |
2024-08-30 08:47:49 +0200 | <Franciman> | lol, do they still use dynamic linking for haskell? |
2024-08-30 08:47:56 +0200 | <geekosaur> | arch linux even breaks its own haskell packages somewhat regularly |
2024-08-30 08:48:22 +0200 | <esnos> | I now try to resolve this problem... |
2024-08-30 08:48:25 +0200 | <geekosaur> | they have lists of packages that need to be rebuilt when their dependencies change, but sometimes they miss one or two |
2024-08-30 08:48:29 +0200 | <esnos> | <no location info>: error: |
2024-08-30 08:48:29 +0200 | <esnos> | Warning: Couldn't figure out linker information! |
2024-08-30 08:48:29 +0200 | <esnos> | Make sure you're using GNU ld, GNU gold or the built in OS X linker, etc. |
2024-08-30 08:48:29 +0200 | <esnos> | collect2: fatal error: cannot find ‘ld’ |
2024-08-30 08:48:33 +0200 | <esnos> | compilation terminated. |
2024-08-30 08:48:36 +0200 | <esnos> | `gcc' failed in phase `Linker'. (Exit code: 1) |
2024-08-30 08:48:59 +0200 | <geekosaur> | and then (for example) xmonad gets a bug report that turns out to be "arch forgot to rebuild xmonad-contrib after updating X11-xft or something" |
2024-08-30 08:49:28 +0200 | <geekosaur> | o.O that's definitely an arch linux issue |
2024-08-30 08:49:32 +0200 | <Franciman> | this is a point in favour of guix |
2024-08-30 08:49:34 +0200 | <Inst> | i strongly suggest you try to nuke your haskell arch linux toolchain and move to cabal or stack, preferably cabal since stack is on life support |
2024-08-30 08:49:40 +0200 | <Franciman> | declarative packages and build recipes |
2024-08-30 08:49:47 +0200 | <Inst> | https://www.haskell.org/ghcup/ |
2024-08-30 08:49:49 +0200 | <geekosaur> | it's not even coming (directly) from ghc; `collect2` is an internal gcc tool |
2024-08-30 08:50:05 +0200 | <Inst> | ghcup, rather |
2024-08-30 08:50:29 +0200 | <geekosaur> | (ghc uses gcc to link, because it's pretty much impossible to work out what needs to be linked in for glibc to work right otherwise) |
2024-08-30 08:50:40 +0200 | xff0x | (~xff0x@2405:6580:b080:900:136b:65b1:e5b:b9e1) (Ping timeout: 272 seconds) |
2024-08-30 08:50:49 +0200 | <Franciman> | geekosaur: does it use gcc both for static and dynamic linking mode? |
2024-08-30 08:50:49 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 265 seconds) |
2024-08-30 08:50:54 +0200 | <geekosaur> | yes |
2024-08-30 08:50:56 +0200 | <esnos> | Franciman: I'm playing with guix on my second laptop, after I learn it I will probably migrate to it |
2024-08-30 08:51:14 +0200 | <geekosaur> | ld is only used directly when making shared libraries |
2024-08-30 08:51:26 +0200 | <Franciman> | i see |
2024-08-30 08:51:30 +0200 | <geekosaur> | and when merging objects |
2024-08-30 08:51:30 +0200 | <Franciman> | esnos: enjoy! |
2024-08-30 08:51:38 +0200 | <Franciman> | do you also tried nix, esnos? |
2024-08-30 08:52:10 +0200 | <Franciman> | have* |
2024-08-30 08:52:28 +0200 | <esnos> | Inst: I can nuke arch linux haskell, but how I should then install cabal and ghc? From curl, or install ghc from arch linux repo and then cabal |
2024-08-30 08:52:40 +0200 | <Inst> | do the ghcup instructions |
2024-08-30 08:52:51 +0200 | <geekosaur> | ghcup does both and you can get it as a precompiled binary |
2024-08-30 08:52:59 +0200 | <Inst> | sorry, i misspoke |
2024-08-30 08:53:20 +0200 | <Inst> | just do ghcup with cabal or stack, not cabal or stack on their own |
2024-08-30 08:53:59 +0200 | <geekosaur> | cabal won't install ghc for you, stack will but that is on life support and the ghcup stack hook is recommended instead |
2024-08-30 08:54:24 +0200 | <mauke> | but will that fix the gcc error? |
2024-08-30 08:54:25 +0200 | <esnos> | Franciman: I didn't tried nix, guix have much less packages, but I heard documentation is better, so I stick with it |
2024-08-30 08:54:41 +0200 | <geekosaur> | (I don't think stack itself is on life support, but its automatically installing ghcs itslef certainly is) |
2024-08-30 08:54:45 +0200 | <Franciman> | i find docs very clear, yes |
2024-08-30 08:54:58 +0200 | <geekosaur> | mpilgrem is working closely with cabal devs for example |
2024-08-30 08:55:35 +0200 | <Inst> | wait did nix finally get gui? |
2024-08-30 08:55:40 +0200 | <geekosaur> | sadly, I suspect it won't; that spunds like somehow gcc is installed but ld isn't |
2024-08-30 08:55:46 +0200 | <Franciman> | esnos: in a perfect scenario, cabal wouldn't exist, and you would use guix or nix for managing deps ^^ |
2024-08-30 08:55:51 +0200 | <Franciman> | well cabal/cargo/pip/etc |
2024-08-30 08:55:58 +0200 | <geekosaur> | (I would have expected ld to be a dependenncy, but with Arch who knows?) |
2024-08-30 08:56:24 +0200 | <sclv> | guix or nix don't have solvers. we'll always need solvers for ad-hoc dep sets. |
2024-08-30 08:56:42 +0200 | <esnos> | Franciman: I also want to try to use guix for managing haskell packagess. Did you tried both guix and nix? If yes, how do you compare them? |
2024-08-30 08:56:46 +0200 | <geekosaur> | also I don't know if Arch has anything equivalent to Debian/Ubuntu build-essential that installs pretty much everything you need |
2024-08-30 08:56:56 +0200 | <Franciman> | esnos: no i just tried guix |
2024-08-30 08:57:21 +0200 | <Franciman> | sclv: would solvers be language dependent? |
2024-08-30 08:57:34 +0200 | <geekosaur> | guix is a sort of gnu clone of nix |
2024-08-30 08:57:35 +0200 | <esnos> | geekosaur: There is gcc and binutils in core, I have them both installed |
2024-08-30 08:57:37 +0200 | <sclv> | also we'd still use cabal/cargo etc to orchestrate _building_ |
2024-08-30 08:57:39 +0200 | <geekosaur> | not "gui" |
2024-08-30 08:57:59 +0200 | <Franciman> | sclv: uhm orchestrate building can be done by guix/nix |
2024-08-30 08:58:09 +0200 | <geekosaur> | (more specifically, the "gu" comes from Guile and the "ix" from Nix) |
2024-08-30 08:58:27 +0200 | JuanDaugherty | (~juan@user/JuanDaugherty) |
2024-08-30 08:58:56 +0200 | <Franciman> | and they really should be doing it, if you want to guarantee reproducibility. In fact they use these build systems in very strange and unusual ways to obtain their goal |
2024-08-30 08:59:53 +0200 | <sclv> | currently, sadly, solvers are language dependent because they're package-format and conventions dependent, and we have different conventions and possibilities per language ecosystem -- different treatment of multiple versions, of feature flags, of cross-cutting compiler settings (prof builds, object builds), etc. |
2024-08-30 08:59:53 +0200 | <sclv> | there's some stray efforts to build a common solver core that's potentially language independent, but i don't think the approach scales to handle everything necessary yet, and there's not a cohesive vision to make the push. |
2024-08-30 09:00:15 +0200 | <Franciman> | yeah, makes sense |
2024-08-30 09:00:24 +0200 | <esnos> | So to summarise, I should delete all haskell things I have on my computer, Install ghc package from pacman, then ghcup tui install cabal and hls, then cabal update, cabal init folder, add MonadRandom to .cabal file? |
2024-08-30 09:00:35 +0200 | <Franciman> | no esnos |
2024-08-30 09:00:39 +0200 | <Franciman> | install ghc from ghcup too |
2024-08-30 09:01:12 +0200 | <esnos> | How can I have ghcup without ghc? |
2024-08-30 09:01:20 +0200 | <Franciman> | prebuild binaries |
2024-08-30 09:01:22 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 09:01:26 +0200 | <sclv> | ghcup is the _installer for ghc_ |
2024-08-30 09:01:36 +0200 | <Franciman> | also isn't ghcup written in bash? |
2024-08-30 09:01:37 +0200 | <esnos> | Ok, I get it wrong |
2024-08-30 09:01:56 +0200 | <sclv> | just run the magic command line here on a clean system and it'll do everything for you https://www.haskell.org/ghcup/ |
2024-08-30 09:02:08 +0200 | <Franciman> | sclv: so do you think there is room for avoiding duplication of work in packaging? |
2024-08-30 09:02:37 +0200 | <Franciman> | maybe cabal would produce a guix package definition |
2024-08-30 09:02:39 +0200 | <sclv> | ghcup isn't written in bash -- but the script that i linked is a bash script that wraps installing ghcup and its deps, then running it to get the basics going all at once. |
2024-08-30 09:02:46 +0200 | <esnos> | sclv: There is also package ghcup-hs-bin in aur, maybe this will be better because of arch |
2024-08-30 09:02:49 +0200 | <Franciman> | instead of dealing with all the build project itself |
2024-08-30 09:03:10 +0200 | xff0x | (~xff0x@2405:6580:b080:900:136b:65b1:e5b:b9e1) |
2024-08-30 09:03:46 +0200 | <sclv> | esnos: arch's treatment of ghc is the whole problem we're trying to get you past. it configures it in a way that is not suitable for development. the best thing on arch as a haskell developer (rather than consumer of programs) is sadly to bypass everything haskell related it provides |
2024-08-30 09:03:56 +0200 | Sgeo | (~Sgeo@user/sgeo) (Read error: Connection reset by peer) |
2024-08-30 09:04:16 +0200 | <Franciman> | lol i once asked them why they did that and they answered: apparently haskell's ecosystem is super brittle |
2024-08-30 09:04:33 +0200 | <Franciman> | SO why are you doing it if it's so brittle |
2024-08-30 09:04:39 +0200 | <Franciman> | stick to what's working |
2024-08-30 09:05:19 +0200 | <geekosaur> | because people want pandoc |
2024-08-30 09:05:37 +0200 | <esnos> | sclv: Ok, I will then use ghcup from link |
2024-08-30 09:05:40 +0200 | <sclv> | Franciman: I don't think we have duplication of work in packaging. cabal manifests have a _lot_ more data than nix package descriptions. Nix _relies_ on that data to build packages -- it has to make use of the manifests itself. So we can't do away with language-specific files that describe how to build packages, which is what cabal files are. |
2024-08-30 09:05:47 +0200 | <Franciman> | no geekosaur i mean stick to the way haskell is known to work |
2024-08-30 09:06:14 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 252 seconds) |
2024-08-30 09:06:28 +0200 | <sclv> | There are tools that extract a small fraction of the data in cabal files that is necessary for nix files, and do that autogen tho. |
2024-08-30 09:06:54 +0200 | <Franciman> | sclv: i think there is, because if i want to package an haskell lib or program i have to recursively do it for all deps |
2024-08-30 09:07:08 +0200 | <sclv> | Sure. but you can automate that too. |
2024-08-30 09:07:11 +0200 | <Franciman> | while cabal could do that for me |
2024-08-30 09:07:19 +0200 | <JuanDaugherty> | #archlinux said hs ecosys was brittle? |
2024-08-30 09:07:26 +0200 | acidjnk_new | (~acidjnk@p200300d6e72cfb704920adbe3bc2fb8d.dip0.t-ipconnect.de) |
2024-08-30 09:07:38 +0200 | <Axman6> | Arch have been pretty good at making it brittle =) |
2024-08-30 09:07:50 +0200 | <sclv> | I think what you're asking for isn't about cabal files, or even cabal the tool. You just want a tool to automatically recursively package haskell for nix, and I'm pretty sure those exist? |
2024-08-30 09:07:52 +0200 | <Axman6> | I remember when they broke basically everything to do with haskell |
2024-08-30 09:07:59 +0200 | <Franciman> | sclv: no wait |
2024-08-30 09:08:14 +0200 | <Franciman> | also i don't know about nix |
2024-08-30 09:08:18 +0200 | peterbecich | (~Thunderbi@syn-047-229-123-186.res.spectrum.com) (Ping timeout: 245 seconds) |
2024-08-30 09:08:20 +0200 | <Franciman> | nix is less obsessed about reproducibility |
2024-08-30 09:08:20 +0200 | <JuanDaugherty> | they're whole schtick is the distribution mechanism, so figures |
2024-08-30 09:08:32 +0200 | <JuanDaugherty> | *their |
2024-08-30 09:08:34 +0200 | <geekosaur> | I think they mean things like cross-module inlining meaning that you can never simply replace a shared object, you have to rebuild everything that uses it |
2024-08-30 09:08:38 +0200 | <haskellbridge> | <sm> arch packagers and haskell devs don't talk to each other it seems |
2024-08-30 09:08:44 +0200 | <geekosaur> | and they have a hard rule that everything must use shared libs |
2024-08-30 09:08:52 +0200 | <Axman6> | I thought the main thing Nix cares about is reproducibility |
2024-08-30 09:09:09 +0200 | <Franciman> | Axman6: they care, they are not just obsessed with it to the level guix is |
2024-08-30 09:09:28 +0200 | <davean> | sm: Talk? Well it requires listening for the talking to do any good. |
2024-08-30 09:09:42 +0200 | <Franciman> | sclv: i agree on cabal files being necessary and cabal being available, but i don't see why cabal has to manage all the building process |
2024-08-30 09:09:49 +0200 | <Franciman> | rather than handing it to nix |
2024-08-30 09:10:10 +0200 | <Franciman> | there is the duplication. Cabal could just create package definitions and then let the package manager |
2024-08-30 09:10:16 +0200 | <Axman6> | Nix doesn't run on windows, afaik, so that's one reason isn't it? |
2024-08-30 09:10:16 +0200 | <geekosaur> | I thought cabal2nix did exactly that? |
2024-08-30 09:10:30 +0200 | <geekosaur> | converts a cabal file to a nix derivation |
2024-08-30 09:10:38 +0200 | <sclv> | here's an old post from an arch maintainer explaining their philosophy. it makes things easier for them, and its fine for application users, and they don't want to do anything harder to support devs well (in part because they're underresourced), so they don't https://www.reddit.com/r/linux/comments/9emwtu/comment/e5qssdz/?context=3 |
2024-08-30 09:10:45 +0200 | CrunchyFlakes | (~CrunchyFl@ip-109-42-115-64.web.vodafone.de) |
2024-08-30 09:11:22 +0200 | <Inst> | and haskell community could do a lot more, but haskell community is also underresourced |
2024-08-30 09:11:25 +0200 | <Inst> | got bigger fish to fry |
2024-08-30 09:11:27 +0200 | CrunchyFlakes | (~CrunchyFl@ip-109-42-115-64.web.vodafone.de) (Read error: Connection reset by peer) |
2024-08-30 09:11:28 +0200 | <JuanDaugherty> | can see how arch and ghc/hs ecosys r at x-purposes, three concurrent levels of the compiler and stuff |
2024-08-30 09:11:28 +0200 | <Franciman> | geekosaur: oh it also produces all the recusrive definitions? |
2024-08-30 09:11:32 +0200 | <Inst> | thanks sclv / sm etc for the hard work on cabal! |
2024-08-30 09:11:36 +0200 | <Axman6> | yeah I thought Nix had pretty good support for haskell packages, and could manage installing haskell packages that hadn't been explicitly converted to use nix? |
2024-08-30 09:11:54 +0200 | JuanDaugherty | was over nix a dozen ya |
2024-08-30 09:11:54 +0200 | youthlic | (~Thunderbi@user/youthlic) |
2024-08-30 09:12:08 +0200 | <Franciman> | Axman6: you mean install packages wiithout having them as nix apcakges? |
2024-08-30 09:12:10 +0200 | <Franciman> | packages* |
2024-08-30 09:12:12 +0200 | <Axman6> | I'm pretty sure if you install a random Haskell package with Nix, it will handle installing all the dependancies |
2024-08-30 09:12:14 +0200 | <geekosaur> | Franciman, see what Axman6 said |
2024-08-30 09:12:15 +0200 | <Axman6> | yes |
2024-08-30 09:12:25 +0200 | <geekosaur> | it just reruns cabal2nix on the deps that are missing |
2024-08-30 09:12:27 +0200 | <Franciman> | guix would disapprove |
2024-08-30 09:12:34 +0200 | <Axman6> | Nix knows enough cabal to recursivly install things |
2024-08-30 09:12:35 +0200 | <Franciman> | they need all dependencies packaged |
2024-08-30 09:12:39 +0200 | <Franciman> | to accept a package in the repos |
2024-08-30 09:12:52 +0200 | <JuanDaugherty> | https://eg.meansofproduction.biz/eg/index.php/NixOS |
2024-08-30 09:12:56 +0200 | <sclv> | Franciman: nix is a package manager, its not a builder! Nix uses language specific builders for every language that needs them afaik. "handing it to nix" would be nightmarish for nix devs, duplicate work, and likely get things wrong. If you look at how much work cabal does to build a single package, even when all deps already exist and are solved, there's a lot going on. |
2024-08-30 09:12:57 +0200 | <Franciman> | ok thanks |
2024-08-30 09:13:08 +0200 | <Axman6> | there's a difference between installing a haskell package with nix and a haskell package being in nixpkgs. |
2024-08-30 09:13:14 +0200 | <Axman6> | nix understands haskell packages |
2024-08-30 09:13:43 +0200 | <Franciman> | guix requires everything to be packaged |
2024-08-30 09:13:55 +0200 | <Franciman> | i mean it's not necessary to have a package, but to have it accepted in the repos |
2024-08-30 09:13:59 +0200 | vpan | (~vpan@212.117.1.172) |
2024-08-30 09:14:15 +0200 | <Franciman> | i see |
2024-08-30 09:14:19 +0200 | <sclv> | Right. But there's automated tooling that the nix people use for the haskell packages there, and I bet it could be adapted to guix |
2024-08-30 09:14:35 +0200 | <Franciman> | i see about being a package manager |
2024-08-30 09:14:43 +0200 | <Axman6> | Nix doesn't require that, but it can produce reproducible builds form hackage packages (or git repos I think, if you want that) |
2024-08-30 09:15:12 +0200 | <JuanDaugherty> | nix and hs are cognitively consonant on being declarative, but srs useful thing for hs, pointless gimmick for a problem of 20 ya in the other case |
2024-08-30 09:16:49 +0200 | <JuanDaugherty> | good thing there arent a lot of discerning ppl due to turnover or whatever |
2024-08-30 09:16:55 +0200 | <sclv> | the nix configuration language itself is from my experience with it an imperative macro system pretending to be a declarative language. but its still the best thing we have. |
2024-08-30 09:17:10 +0200 | <haskellbridge> | <sm> thanks Inst, but you might have meant someone else (I haven't worked hard on cabal.. except using & supporting) |
2024-08-30 09:17:10 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 09:17:16 +0200 | <Franciman> | sclv: guix is more declarative, tbh |
2024-08-30 09:17:21 +0200 | <geekosaur> | eh? take a look at how guix does it sometime |
2024-08-30 09:18:05 +0200 | <davean> | I find guix way easier to read. I use nix though. I wish we could have the best of both. |
2024-08-30 09:18:07 +0200 | <Franciman> | builders produce a gexp, which is roughly a s-expr representing a list of operations to make |
2024-08-30 09:18:14 +0200 | <Franciman> | on the store |
2024-08-30 09:18:22 +0200 | CiaoSen | (~Jura@2a05:5800:247:2000:ca4b:d6ff:fec1:99da) |
2024-08-30 09:18:31 +0200 | <Franciman> | and then guix runs the gexp it obtains from a package definition + input |
2024-08-30 09:18:45 +0200 | <geekosaur> | also, guix has something nix decidedly doesn't: standards for how derivations work and interact |
2024-08-30 09:18:51 +0200 | <dminuoso> | 07:11:36 Axman6 │ yeah I thought Nix had pretty good support for haskell packages, and could manage installing haskell packages that hadn't been explicitly converted to use nix? |
2024-08-30 09:18:54 +0200 | <dminuoso> | Check out haskell.nix |
2024-08-30 09:19:02 +0200 | <davean> | geekosaur: nix is *so inconsistent* |
2024-08-30 09:19:10 +0200 | <geekosaur> | exactly |
2024-08-30 09:19:11 +0200 | <Franciman> | geekosaur: maybe with flakes things have changed though |
2024-08-30 09:19:19 +0200 | <Franciman> | i'm not familiar with nix |
2024-08-30 09:19:46 +0200 | <Inst> | esnos: so, any progress on your issue? |
2024-08-30 09:20:01 +0200 | <geekosaur> | guix set out design guidelines and policies, having learned from nix |
2024-08-30 09:20:07 +0200 | <dminuoso> | nix has extremely poor UX, very poor standard libary, syntax that makes it hard to structure non-trivial code, uncontrollable evaluation order - and an ecosystem that ties errors into evaluation errors making any kind of error handling nightmarish to impossible. |
2024-08-30 09:20:26 +0200 | <dminuoso> | Yes we use it with NixOS to manage our entire infrastructure. So I'm entitled to rant about it. |
2024-08-30 09:20:35 +0200 | <davean> | dminuoso: I have a situation ATM with that I have no idea how to resolve |
2024-08-30 09:20:44 +0200 | <Axman6> | I haven't done a whole lot with nix, but that matches my experience too |
2024-08-30 09:20:47 +0200 | <Franciman> | dminuoso: and have you tried guix? Does it suffer from same problems or other problems? |
2024-08-30 09:20:59 +0200 | <JuanDaugherty> | true believers |
2024-08-30 09:21:09 +0200 | <geekosaur> | the big problem with guix is its ecosystem is tiny compared to nix |
2024-08-30 09:21:15 +0200 | Franciman | nods |
2024-08-30 09:21:21 +0200 | <Franciman> | it's getting better now |
2024-08-30 09:21:30 +0200 | <Franciman> | also nonguix has non-free stuff |
2024-08-30 09:21:31 +0200 | <dminuoso> | JuanDaugherty: Oh Im far from a believer. I'm not blinded about all the negative parts about it - it's just that for managing hundreds of servers, short of k8s there aren't any good alternatives. |
2024-08-30 09:21:35 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 255 seconds) |
2024-08-30 09:21:58 +0200 | <dminuoso> | Franciman: Have not tried it yet, and given how deep we are into NixOS already I don't think we will pull out of it any time soon. |
2024-08-30 09:22:05 +0200 | <davean> | dminuoso: its hilarious. when I set a path to "./file" it errors, claiming "./sub/dir/file" (where the nix file it is used from is) doesn't exist. If I set it to "./sub/dir/file" it gets further and then says "./sub/dir/sub/dir/file" doesn't exist. The errors both come from the same place of course. |
2024-08-30 09:22:07 +0200 | <Franciman> | i see |
2024-08-30 09:22:11 +0200 | <dminuoso> | From that ecosystem, NixOS is the good part honestly. |
2024-08-30 09:22:25 +0200 | <davean> | dminuoso: somewhere in the litterly 20k lines of trace I'm sure there is a meaningful difference. |
2024-08-30 09:22:29 +0200 | <JuanDaugherty> | dminuoso, i meant ur employer |
2024-08-30 09:22:43 +0200 | <JuanDaugherty> | and/or colleagues |
2024-08-30 09:22:54 +0200 | <JuanDaugherty> | them that bought the nix kool aid |
2024-08-30 09:23:00 +0200 | <dminuoso> | JuanDaugherty: I'm the singular cause for why we started adopting NixOS. I pushed for it. |
2024-08-30 09:23:09 +0200 | <geekosaur> | "oops" |
2024-08-30 09:23:12 +0200 | <JuanDaugherty> | ur bad |
2024-08-30 09:23:16 +0200 | <dminuoso> | And even in hindsight I still think its the right decision. |
2024-08-30 09:23:26 +0200 | <dminuoso> | Much rather deal with a bad nix ecosystem than with ansible, puppet or chef. |
2024-08-30 09:23:38 +0200 | <dminuoso> | k8s might have been a better choice perhaps who knows |
2024-08-30 09:24:01 +0200 | <[exa]> | depending on how long ago that was, k8s might have not been a usable choice back then |
2024-08-30 09:24:15 +0200 | <geekosaur> | from what I've heard from k8s users, you'd probably just be trading your current problems for different ones |
2024-08-30 09:24:24 +0200 | <davean> | dminuoso: k8s doesn't cover as much as nixos does, and with a lot more layers of complexity. |
2024-08-30 09:24:50 +0200 | tromp | (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) |
2024-08-30 09:25:38 +0200 | <dminuoso> | davean: What you wrote with the path, sounds like a regular day with nix. |
2024-08-30 09:25:48 +0200 | <esnos> | Ok, I nuked everything with sudo pacman -Rcsn <big haskell packages> |
2024-08-30 09:25:52 +0200 | <JuanDaugherty> | well k8 is a specif thing, system app, comparing it to nix is a category error |
2024-08-30 09:25:57 +0200 | cfricke | (~cfricke@user/cfricke) |
2024-08-30 09:25:59 +0200 | <JuanDaugherty> | *specific |
2024-08-30 09:26:19 +0200 | <dminuoso> | JuanDaugherty: I noted that we adopted this for NixOS to maintain a fleet of hundreds of servers, that's our prime usecase. |
2024-08-30 09:26:24 +0200 | <davean> | JuanDaugherty: Its not a category error. They both can do some of the same jobs, specificly the relivent ones here. |
2024-08-30 09:26:27 +0200 | <dminuoso> | Which is why k8s is a suitable comparison. |
2024-08-30 09:26:36 +0200 | <jackdk> | dminuoso: I agree with all your frustrations re: Nix, and also own a mug that says "use Nix for literally everything". |
2024-08-30 09:26:38 +0200 | <JuanDaugherty> | k |
2024-08-30 09:27:00 +0200 | <davean> | I really wish we had nix with some of the engenering of guix |
2024-08-30 09:27:49 +0200 | CiaoSen | (~Jura@2a05:5800:247:2000:ca4b:d6ff:fec1:99da) (Ping timeout: 248 seconds) |
2024-08-30 09:28:20 +0200 | <davean> | dminuoso: BTW, while we're at it, any idea about the path issue? ;) |
2024-08-30 09:28:40 +0200 | <davean> | I've no clue how to debug or fix it. |
2024-08-30 09:29:06 +0200 | <jackdk> | I need to look at guix more, but I'm frustrated by a package set which is both bootstrappable but fails to build openssl-1.1.1l because all of the certificates in the test suite have expired =S. But using a mature language and having proper functions for each type of build system are both really attractive to me. |
2024-08-30 09:29:33 +0200 | <Franciman> | jackdk: i think that is now solved |
2024-08-30 09:29:45 +0200 | JuanDaugherty | (~juan@user/JuanDaugherty) (Quit: JuanDaugherty) |
2024-08-30 09:29:56 +0200 | <Franciman> | yeah guix can seem slow sometimes, because there is not much money and people, but that is also up to us |
2024-08-30 09:29:59 +0200 | <Franciman> | who keep preferring nix |
2024-08-30 09:30:25 +0200 | <davean> | I mean as long as guix is gnu rotted I kinda don't have a choice? |
2024-08-30 09:30:29 +0200 | <dminuoso> | For my personal computer I decided to give Qubes OS a try, because I'm a sucker for exotic ideas in operating systems. :-) |
2024-08-30 09:30:46 +0200 | <Franciman> | davean: wdym? There are "non-free" channels |
2024-08-30 09:30:49 +0200 | <Franciman> | like nonguix |
2024-08-30 09:30:54 +0200 | <davean> | Franciman: its nothing about the freeness |
2024-08-30 09:31:01 +0200 | <Franciman> | gnu rotten means? |
2024-08-30 09:31:02 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 09:31:30 +0200 | <davean> | Just the general issues gnu projects have about how they go about getting stuff done. I don't think man hours could solve guix |
2024-08-30 09:31:52 +0200 | <probie> | I ran Qubes for a while. It worked pretty well for most of my work workloads apart from watching videos |
2024-08-30 09:32:06 +0200 | <probie> | also was rather battery unfriendly |
2024-08-30 09:32:06 +0200 | <Franciman> | davean: can you explain a bit more? |
2024-08-30 09:32:31 +0200 | <dminuoso> | probie: Oh yeah, video playback is horrible - full fan speed every time, and jittery playback at 15-20fps! |
2024-08-30 09:32:34 +0200 | <davean> | Franciman: A lot of gnu projects are too focused on doing the cool thing in someone's head to ever deliver. |
2024-08-30 09:32:52 +0200 | <davean> | gnu has a VERY strong history of never delivering projects |
2024-08-30 09:32:54 +0200 | <Franciman> | davean: i think guix is more pragmatic |
2024-08-30 09:33:11 +0200 | <Franciman> | yes that is true, but guix is working, what is the problem is that they are sometimes slow in accepting packages |
2024-08-30 09:33:16 +0200 | <Franciman> | or fixing some non core issues |
2024-08-30 09:33:17 +0200 | <dminuoso> | davean: I hear Emacs is close to being finished! |
2024-08-30 09:33:22 +0200 | <Franciman> | because there are few people |
2024-08-30 09:33:37 +0200 | <davean> | Franciman: yet they do things like all the bootstrapping stuf |
2024-08-30 09:33:49 +0200 | <Franciman> | yet it works |
2024-08-30 09:34:01 +0200 | <Franciman> | bootstrappable stuff is cool, but that's not the only thing they do |
2024-08-30 09:34:30 +0200 | <haskellbridge> | <sm> davean: I’d say its history of delivering is a bit stronger! |
2024-08-30 09:35:33 +0200 | <jackdk> | Franciman: Alas, no. I still get the test error on `guix pull`. |
2024-08-30 09:35:49 +0200 | <Franciman> | what, jackdk. Let me try |
2024-08-30 09:35:55 +0200 | <Franciman> | what are your configs? |
2024-08-30 09:35:59 +0200 | <Franciman> | I also have openssl and it works |
2024-08-30 09:36:09 +0200 | <Franciman> | maybe a different version tho |
2024-08-30 09:36:53 +0200 | <probie> | GNU delivered GCC and Gnome. That's actually a pretty good result overall |
2024-08-30 09:36:55 +0200 | <Franciman> | i see there is openssl-1.1.1q |
2024-08-30 09:37:12 +0200 | <Franciman> | is it ok jackdk ? |
2024-08-30 09:37:44 +0200 | <jackdk> | Franciman: The main thing is that I have substituters turned off, and I'm building against the `d531237` commit of https://git.savannah.gnu.org/git/guix.git . I don't know if this is the absolute latest, but it's what a five-minute-old `guix pull` gave me |
2024-08-30 09:38:06 +0200 | <Franciman> | ah i can't afford to build everything from sources on this lappy |
2024-08-30 09:38:35 +0200 | <davean> | right but you'd only encounter that error on build? |
2024-08-30 09:38:48 +0200 | <jackdk> | Yeah the binary substitute is presumably fine, but I believe in the whole bootstrap thing, and am frustrated that they've done so much good work on that front but not disarmed the certificate timebombs. |
2024-08-30 09:39:34 +0200 | <davean> | I mean I believe the bootstrap thing is good. Just years spent on that while not dealing with the core product means the momentum is elsewhere. |
2024-08-30 09:39:51 +0200 | <jackdk> | Like, I'll randomly run nix commands with `--option substitute false` and file nixpkgs bugs/PRs against broken links etc |
2024-08-30 09:40:26 +0200 | <davean> | jackdk: really? I built with only my own subsituters all the time and haven't hit one yet. What are you building? |
2024-08-30 09:40:51 +0200 | <davean> | (I run into plenty of nixpkg errors, but not that one) |
2024-08-30 09:41:13 +0200 | <davean> | (More often changed hashes on sources withotu versioning for URLs themselves) |
2024-08-30 09:41:50 +0200 | <davean> | and ugh, nix's 5 ways of handling, or not being able to handle. ssh options. |
2024-08-30 09:43:09 +0200 | <jackdk> | davean: most recently https://github.com/NixOS/nixpkgs/pull/335793 , but I've seen random python packages push over the top of release tags, many fonts were broken for a while if you weren't substituting them because the function they were calling changed interface, and others |
2024-08-30 09:43:50 +0200 | <davean> | fun. Yah sounds like you're in a different area than I am |
2024-08-30 09:44:04 +0200 | <davean> | every subsystem of the nixpkgs ecosystem is its own jungle. |
2024-08-30 09:44:40 +0200 | <jackdk> | Yeah true. Sometimes it's fundamental stuff too: dhcpcd moved from self-hosted releases to github and nobody noticed because they got at least the source tarball from cache.nixos.org |
2024-08-30 09:44:55 +0200 | ubert | (~Thunderbi@178.165.175.79.wireless.dyn.drei.com) |
2024-08-30 09:45:02 +0200 | tromp | (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…) |
2024-08-30 09:45:06 +0200 | dysthesis | (~dysthesis@user/dysthesis) (Ping timeout: 260 seconds) |
2024-08-30 09:45:36 +0200 | <davean> | I had an unprincipaled script that riped all the sources out and precached them. I wonder ... |
2024-08-30 09:45:45 +0200 | <davean> | it was unprincipled though. |
2024-08-30 09:47:02 +0200 | dysthesis | (~dysthesis@user/dysthesis) |
2024-08-30 09:51:17 +0200 | mreh | (~matthew@host86-160-168-12.range86-160.btcentralplus.com) |
2024-08-30 09:51:42 +0200 | youthlic | (~Thunderbi@user/youthlic) (Ping timeout: 246 seconds) |
2024-08-30 09:52:05 +0200 | <geekosaur> | that makes it different from nix itself how? 😛 |
2024-08-30 09:52:37 +0200 | <esnos> | Inst, Franciman, svcl, geekosaur, everything works! Thank you for your help, I apprecaite it |
2024-08-30 09:53:03 +0200 | lxsameer | (~lxsameer@Serene/lxsameer) |
2024-08-30 09:53:05 +0200 | <dminuoso> | davean: I think the biggest issue is not even that you have these disconnected jungles everywhere, but the fundamental lack of types or documentation. The disconencted jungles just mean you have to reverse engineer tens of thousands of lines of code over and over again. |
2024-08-30 09:53:27 +0200 | <esnos> | *sclv |
2024-08-30 09:53:29 +0200 | <dminuoso> | And while yes, documentation is slowly improving, it's far from `@hoogle void` and getting some instant response. |
2024-08-30 09:54:04 +0200 | <davean> | geekosaur: Its different because its not what they test again :) |
2024-08-30 09:55:06 +0200 | kuribas | (~user@ptr-17d51ep5b2wbec6a4va.18120a2.ip6.access.telenet.be) |
2024-08-30 09:55:08 +0200 | <dminuoso> | The code hierarchy is normal and just an artifact of `nixpkgs` not being exactly a singular project, but just a monorepo for several teams to colocate their code. |
2024-08-30 09:55:37 +0200 | <dminuoso> | (Mostly because nixpkgs did not come with any kind of dependency management |
2024-08-30 09:55:56 +0200 | <dminuoso> | So stuffing it all in a mono repo where you could just import from left to right is a natural consequence |
2024-08-30 09:56:27 +0200 | <esnos> | So for anyone else on arch having problem with building and ld, just nuke every haskell package, you can do it by first finding them with pacman -Qs haskell and then sudo pacman -Rcns big packages, install ghcup from link, ghcup tui everything, cabal init <folder> and in .cabal folder add every package you need. |
2024-08-30 09:56:33 +0200 | <davean> | 90% of my issues with nixos is the nix language |
2024-08-30 09:57:05 +0200 | <dminuoso> | davean: Yup. NixOS itself is arguably the better part precisely because it actually goes through the hoop of building an intermediate abstraction, an intermediate language with a separate evaluator. |
2024-08-30 09:57:23 +0200 | <dminuoso> | Now sadly the error handling is still tied to plain nix expressions which is why NixOS errors are mostly unreadable.. |
2024-08-30 09:57:24 +0200 | ash3en | (~Thunderbi@2a02:3100:7fb9:6a00:1cf6:2c47:e97c:d5d1) |
2024-08-30 09:57:55 +0200 | <geekosaur> | seriously, go look at guix and see what could be |
2024-08-30 09:57:59 +0200 | <davean> | now now, my 20k line error is perfectly made of latin1 chars. I can see the chars just fine |
2024-08-30 09:58:05 +0200 | <davean> | geekosaur: We have? |
2024-08-30 09:58:14 +0200 | <dminuoso> | davean: heh :) |
2024-08-30 09:58:20 +0200 | <geekosaur> | mind, I have Issues with the FSF, but I recognize good design and quite frankly guix is what nix should have been |
2024-08-30 10:02:07 +0200 | Axman6 | (~Axman6@user/axman6) (Remote host closed the connection) |
2024-08-30 10:07:15 +0200 | <divya> | So is guile a fine language. Integrates well with the system. |
2024-08-30 10:07:51 +0200 | <geekosaur> | guile is a good scheme implementation, with reasonably good integration with the system |
2024-08-30 10:08:29 +0200 | xff0x | (~xff0x@2405:6580:b080:900:136b:65b1:e5b:b9e1) (Ping timeout: 260 seconds) |
2024-08-30 10:09:05 +0200 | <davean> | Scheme is not like what I'd have picked, but its fine? |
2024-08-30 10:10:02 +0200 | <geekosaur> | it's far better than the ad hoc mess nix uses |
2024-08-30 10:11:07 +0200 | <davean> | yep, its fine |
2024-08-30 10:11:18 +0200 | <davean> | There is nothing deeply, fundimentally, wrong with it |
2024-08-30 10:11:41 +0200 | <probie> | Scheme is very much a "maximum value for minimum effort" language |
2024-08-30 10:12:12 +0200 | <probie> | s/minimum effort/minimum implementation effort/ |
2024-08-30 10:12:41 +0200 | <divya> | probie: Yep, exactly. I decided this year to replace my python scripts with Scheme (Chez, Racket) ones. It's much faster and easier to write. |
2024-08-30 10:13:07 +0200 | <haskellbridge> | <sm> Hey, fun |
2024-08-30 10:13:11 +0200 | <davean> | I feel like what you say is sorta true probie, but I also don't feel I can really invest in it to make things better in general. |
2024-08-30 10:13:32 +0200 | <dminuoso> | geekosaur: The sad thing is just, that ecosystem is in the end more important than usability of a language from a practical point of view. |
2024-08-30 10:13:38 +0200 | <dminuoso> | When you want to use it to maintain hundreds of servers. |
2024-08-30 10:13:47 +0200 | <merijn> | esnos: Ah, you fell victim to one of the classic blunders! The most famous of which is, 'never get involved in a land war in Asia,' but only slightly less well-known is this: 'Never try to use Arch's Haskell package!' |
2024-08-30 10:13:58 +0200 | <davean> | dminuoso: you know, I believed that, and I still do, but nix does try that theory pretty hard |
2024-08-30 10:14:27 +0200 | <dminuoso> | Oh it does. |
2024-08-30 10:15:01 +0200 | <divya> | merijn: I've had 3 package dependency hell situations in Arch this year alone because of haskell and python packages through pacman. |
2024-08-30 10:15:14 +0200 | <dminuoso> | Oh hello merijn, been a while since I've seen you. |
2024-08-30 10:15:25 +0200 | <divya> | I badly need to switch to guix, but I haven't been able to because I have 2600 packages and a tightly customized setup. |
2024-08-30 10:15:34 +0200 | <merijn> | divya: Personally I think the Haskell situation is most egregious, because they just intentionally ship a GHC/cabal that is broken in the default configuration |
2024-08-30 10:15:50 +0200 | <merijn> | dminuoso: Yeah, I got a new job and actually have to work during office hours now ;) |
2024-08-30 10:15:56 +0200 | <divya> | merijn: Yep, now I just use `ghcup` for everything. |
2024-08-30 10:16:05 +0200 | <dminuoso> | merijn: Neat, where do you work at? |
2024-08-30 10:16:14 +0200 | <merijn> | Small b2b company doing Scala |
2024-08-30 10:16:19 +0200 | ubert | (~Thunderbi@178.165.175.79.wireless.dyn.drei.com) (Ping timeout: 264 seconds) |
2024-08-30 10:16:28 +0200 | <divya> | Also congrats on the new job merijn, at least someone's getting one. I'm having to switch and the dread is real. |
2024-08-30 10:16:41 +0200 | <esnos> | merijn: I won't make same mistake ever again |
2024-08-30 10:17:22 +0200 | <merijn> | the thing is they could even make the default Arch config "just work", IFF they simply patches GHC to use dynamic linking by default (rather than static as it normally does) |
2024-08-30 10:17:36 +0200 | <merijn> | but they refuse to do that too |
2024-08-30 10:17:52 +0200 | <dminuoso> | esnos: There's some interesting stories about why Arch Haskell favours dynamic linking that only demonstrate how Arch Linux is a tinker distribution, and I dont mean `tinker` in a good sense. |
2024-08-30 10:18:24 +0200 | <divya> | Arch got the meme status for a long time for no good reason, really. |
2024-08-30 10:18:44 +0200 | <dminuoso> | esnos: You know, it used to be that there was this one guy living somewhere in eastern Europe maintaining all of hackage. And he compiled the AUR packages on his personal computer, and because his internet was slow, he wanted to reduce the amount of bandwidth needed to upload AUR packages from his personal machine... |
2024-08-30 10:18:51 +0200 | <dminuoso> | Which is why its all dynamic linking. |
2024-08-30 10:19:10 +0200 | <dminuoso> | You'd think something like Arch would have build infrastructure from which AUR was built from, automatically... |
2024-08-30 10:20:04 +0200 | ubert | (~Thunderbi@178.165.175.79.wireless.dyn.drei.com) |
2024-08-30 10:21:42 +0200 | <davean> | dminuoso: I mean if it was actually the reason they could get a shell or use a CI system |
2024-08-30 10:21:49 +0200 | CrunchyFlakes | (~CrunchyFl@ip-109-42-115-64.web.vodafone.de) |
2024-08-30 10:24:04 +0200 | econo_ | (uid147250@id-147250.tinside.irccloud.com) (Quit: Connection closed for inactivity) |
2024-08-30 10:25:04 +0200 | <esnos> | dminuoso: Wow, didn't expect that... when I learn guix I will transistion to it |
2024-08-30 10:25:27 +0200 | tzh | (~tzh@c-76-115-131-146.hsd1.or.comcast.net) (Quit: zzz) |
2024-08-30 10:39:49 +0200 | <albet70> | can we use list comprehension to implememt "split" function? |
2024-08-30 10:40:24 +0200 | <dminuoso> | albet70: What do you expect `split` to do? |
2024-08-30 10:41:23 +0200 | <dminuoso> | `split :: Eq a => a -> [a] -> [[a]]` that breaks a list into sub-lists separated by its first argument? |
2024-08-30 10:41:32 +0200 | <albet70> | split something with something. like split "ab cd" with white space to ["ab" "cd"] |
2024-08-30 10:42:41 +0200 | <dminuoso> | I'm sure with some creativity you can come with an algorithm that uses a list-comprehension somewhere. |
2024-08-30 10:43:07 +0200 | <dminuoso> | The question is whether you forcibly want to use a list-comprehension, or just whether it lends itself in a trivial implementation |
2024-08-30 10:43:29 +0200 | <dminuoso> | If if its the latter, then no, you would not use a list comprehension. |
2024-08-30 10:44:53 +0200 | <dminuoso> | Since list comprehensions are just syntactic sugar around the [] instance of Monad, we could however generalize and find some other Monad to do it with. |
2024-08-30 10:48:53 +0200 | <dminuoso> | % split _ [] = []; split y xxs = x : split y (drop 1 xs) where (x,xs) = span (/= y) xxs |
2024-08-30 10:48:53 +0200 | <yahb2> | <no output> |
2024-08-30 10:49:03 +0200 | <dminuoso> | % split ' ' "foo bar" |
2024-08-30 10:49:03 +0200 | <yahb2> | ["foo","bar"] |
2024-08-30 10:49:11 +0200 | youthlic | (~Thunderbi@user/youthlic) |
2024-08-30 10:49:19 +0200 | <dminuoso> | I guess State would a possibility here |
2024-08-30 10:52:55 +0200 | Axman6 | (~Axman6@user/axman6) |
2024-08-30 10:53:24 +0200 | <merijn> | The real question would be "why would you want that"? |
2024-08-30 10:53:35 +0200 | <merijn> | Considering those functions already exist :p |
2024-08-30 10:53:39 +0200 | youthlic | (~Thunderbi@user/youthlic) (Ping timeout: 252 seconds) |
2024-08-30 10:54:08 +0200 | <dminuoso> | On list? |
2024-08-30 10:54:31 +0200 | <dminuoso> | │ alinab |
2024-08-30 10:54:38 +0200 | <merijn> | split package has like billion split variations already |
2024-08-30 10:54:48 +0200 | tromp | (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) |
2024-08-30 10:54:59 +0200 | <dminuoso> | merijn: Oh I dislike depending on a package just for a single use case. :/ |
2024-08-30 10:55:06 +0200 | <merijn> | sure |
2024-08-30 10:55:11 +0200 | <dminuoso> | If anything a simple `splitOn` should be in base. |
2024-08-30 10:55:33 +0200 | <merijn> | but the question has no context on "why", so any answer is gonna be kinda pointless |
2024-08-30 10:56:00 +0200 | <dminuoso> | merijn: So are you happy with scala? |
2024-08-30 10:56:08 +0200 | <merijn> | Define happy :p |
2024-08-30 10:56:20 +0200 | <dminuoso> | Okay, define your emotional state for me, please. |
2024-08-30 10:56:28 +0200 | <dminuoso> | Or describe it. |
2024-08-30 10:56:31 +0200 | <dminuoso> | :-) |
2024-08-30 10:56:39 +0200 | <merijn> | dminuoso: how happily I depend on package is also a function of how much they pull in, split depends on nothing but base, so about as lightweight as it gets |
2024-08-30 10:57:19 +0200 | <merijn> | dminuoso: ADTs and functional ecosystem is nice, subtyping is absolutely terrible, and the fact that Scala 2 is still stuck in the Java/JVM mistake of "namespaces = objects" is kinda annoying |
2024-08-30 10:58:02 +0200 | <merijn> | most things being methods on objects kinda sucks, because of needing to keep implicit context of the object you call in mind |
2024-08-30 10:58:03 +0200 | <dminuoso> | merijn: Oh it just has lpad vibes to me. |
2024-08-30 10:58:16 +0200 | <merijn> | the type inference is ass and don't get me started on sbt |
2024-08-30 10:58:36 +0200 | <dminuoso> | Okay, you're complaining as usual - so I guess you're having fun at work? |
2024-08-30 10:58:37 +0200 | <merijn> | sbt is yet another in a long list of tools that make me ask "why does Haskell get so much shit for tooling?" |
2024-08-30 10:58:53 +0200 | <Axman6> | I was sup unhappy with scala it nearly made me quit the highest paying job I've ever had |
2024-08-30 10:59:00 +0200 | <Axman6> | so* |
2024-08-30 10:59:05 +0200 | <merijn> | dminuoso: I mean, it's still an order of magnitude better than python/java/ruby/javascript/whatever |
2024-08-30 10:59:15 +0200 | <merijn> | But it's no Haskell :) |
2024-08-30 10:59:20 +0200 | <davean> | merijn: because people aren't upset with tools, they're upset with having to learn things. |
2024-08-30 10:59:22 +0200 | <merijn> | Axman6: It's not that bad |
2024-08-30 10:59:30 +0200 | <Axman6> | The scala we were doing was |
2024-08-30 10:59:40 +0200 | <merijn> | davean: of course, that's why it annoys me |
2024-08-30 10:59:43 +0200 | <Axman6> | I spent literally three months trying to write one SQL query |
2024-08-30 10:59:45 +0200 | <dminuoso> | So it's not really scala but the software. There's some horrible Haskell software out there too. |
2024-08-30 10:59:53 +0200 | <dminuoso> | Axman6: Sounds like opaleye! |
2024-08-30 11:00:08 +0200 | <merijn> | cabal is, objectively, still one of the best tools I have *ever* used |
2024-08-30 11:00:16 +0200 | <Axman6> | and then I got taken off that, replaced with two developers, who developed the scala library we were using for writing SQL queries... and they took another three months to write it |
2024-08-30 11:00:32 +0200 | <merijn> | sbt takes *literally* 15+ seconds to open the shell |
2024-08-30 11:00:48 +0200 | <merijn> | "oh, but startup cost is unimportant, because you just keep the shell open as you work" |
2024-08-30 11:00:59 +0200 | <Axman6> | >:( |
2024-08-30 11:01:33 +0200 | <davean> | Axman6: what was so bad about the query? |
2024-08-30 11:01:40 +0200 | <merijn> | Wanna run 5 different commands in your CI to report things? Well, either 1) run them all in one big batch command with their input interleaved because sbt has no way to redirect output, or 2) eat 15s startup cost at every invocation |
2024-08-30 11:01:50 +0200 | <merijn> | Axman6: scalikejdbc? |
2024-08-30 11:03:21 +0200 | <haskellbridge> | <magic_rb> Dumb solution, but prefix every commands output with some market, like "command1> " and then split on it. That way you can launch them at the same time, let sbt be sbt and split it afterwards |
2024-08-30 11:04:01 +0200 | <haskellbridge> | <magic_rb> It may be possible to do all of that through gnu sed, at least the "prefixing" part is possible |
2024-08-30 11:04:30 +0200 | <merijn> | maggic_rb: That only works if I control the command output, which I don't |
2024-08-30 11:04:52 +0200 | <haskellbridge> | <magic_rb> Cant you pipe it? |
2024-08-30 11:05:02 +0200 | <merijn> | That means doing separate sbt invocations |
2024-08-30 11:05:24 +0200 | <haskellbridge> | <magic_rb> Command you mean literal shell lcommand or some sbt jargon |
2024-08-30 11:05:49 +0200 | <merijn> | the point is that you do either "sbt cmd1 cmd2 cmd3 cmd4" and get the output of everything or you do "sbt cm1; sbt cmd2; sbt cmd3; sbt cmd4" |
2024-08-30 11:06:05 +0200 | <merijn> | The former means all your output is together, the second means 15s startup cost every invocation |
2024-08-30 11:06:20 +0200 | <merijn> | So that's literally a minute of waiting for sbt to start in your build |
2024-08-30 11:06:21 +0200 | <Axman6> | I can't even remember which library it was now, we had a custom layer on top of it that just didn't do what it was supposed to, and it was all done in metaprogramming, so you had three levels where things could go wrong - template instantiation, compile time and runtime. The library was supposed to prevent all runtime errors but it did not (and loved making invalid queries) |
2024-08-30 11:07:39 +0200 | <mauke> | now that's what I call synergy |
2024-08-30 11:08:31 +0200 | <Axman6> | the library was quill, whose website seems to have disappeared, which is probably a good thing |
2024-08-30 11:08:38 +0200 | terrorjack4 | (~terrorjac@2a01:4f8:c17:dc9f::) (Quit: The Lounge - https://thelounge.chat) |
2024-08-30 11:09:25 +0200 | <Axman6> | hmm, or it became some zio thing? who knows. I don't need this triggering tonight =) |
2024-08-30 11:09:39 +0200 | terrorjack4 | (~terrorjac@2a01:4f8:c17:dc9f::) |
2024-08-30 11:09:42 +0200 | <merijn> | I was about to say, scalikejdbc didn't seem that bad. I don't really like the DSL type stuff, I'd rather just write explicit SQL for each use case rather than trying to get DSLs to reuse them |
2024-08-30 11:10:45 +0200 | lortabac | (~lortabac@2a01:e0a:541:b8f0:55ab:e185:7f81:54a4) (Quit: WeeChat 4.2.2) |
2024-08-30 11:11:54 +0200 | <Axman6> | davean: I think it was a join on a table with itself, with a relatively complex expression to match rows with each other |
2024-08-30 11:18:49 +0200 | <davean> | Axman6: I assume you had it written in raw SQL already |
2024-08-30 11:19:30 +0200 | esnos | (~user@176.106.34.161) (Remote host closed the connection) |
2024-08-30 11:20:05 +0200 | rosco | (~rosco@175.136.158.234) (Quit: Lost terminal) |
2024-08-30 11:20:44 +0200 | __monty__ | (~toonn@user/toonn) |
2024-08-30 11:22:47 +0200 | <haskellbridge> | <sm> Inst: "stack is on life support" ? |
2024-08-30 11:28:24 +0200 | CrunchyFlakes | (~CrunchyFl@ip-109-42-115-64.web.vodafone.de) (Read error: Connection reset by peer) |
2024-08-30 11:28:56 +0200 | dysthesis | (~dysthesis@user/dysthesis) (Ping timeout: 260 seconds) |
2024-08-30 11:31:24 +0200 | <Inst> | sm: well, I mean, there's a new maintainer for it |
2024-08-30 11:31:29 +0200 | <Inst> | but it's underresourced |
2024-08-30 11:31:44 +0200 | CrunchyFlakes | (~CrunchyFl@ip-109-42-115-64.web.vodafone.de) |
2024-08-30 11:33:56 +0200 | <geekosaur> | but so is pretty much everything else |
2024-08-30 11:35:06 +0200 | Smiles | (uid551636@id-551636.lymington.irccloud.com) |
2024-08-30 11:36:03 +0200 | dysthesis | (~dysthesis@user/dysthesis) |
2024-08-30 11:37:56 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 255 seconds) |
2024-08-30 11:38:05 +0200 | driib31 | (~driib@vmi931078.contaboserver.net) (Quit: The Lounge - https://thelounge.chat) |
2024-08-30 11:38:40 +0200 | driib31 | (~driib@vmi931078.contaboserver.net) |
2024-08-30 11:39:44 +0200 | <haskellbridge> | <sm> I think it's doing better than many FOSS projects |
2024-08-30 11:40:02 +0200 | son0p | (~ff@186.121.18.131) (Killed (NickServ (GHOST command used by son0p-!~ff@2800:e2:f80:ee7::3))) |
2024-08-30 11:40:37 +0200 | <Franciman> | the legendary guy from fpcomplete is not involved anymore in stack? |
2024-08-30 11:40:38 +0200 | <haskellbridge> | <sm> sometimes one active empowered maintainer can be more productive than a team |
2024-08-30 11:40:45 +0200 | <Franciman> | one of the rudest persons i have ever met |
2024-08-30 11:40:52 +0200 | <haskellbridge> | <sm> please.. |
2024-08-30 11:40:59 +0200 | son0p | (~ff@186.121.18.131) |
2024-08-30 11:42:15 +0200 | <geekosaur> | you never worked with theo de raadt, I guess? |
2024-08-30 11:42:35 +0200 | <Franciman> | lol |
2024-08-30 11:43:00 +0200 | <Rembane> | I guess there are many rude people out there |
2024-08-30 11:43:34 +0200 | <geekosaur> | anyway yes, snoyman moved on |
2024-08-30 11:45:30 +0200 | tcard_ | (~tcard@2400:4051:5801:7500:1e90:74c3:2754:ce8a) |
2024-08-30 11:46:38 +0200 | <haskellbridge> | <sm> not that it matters, but I've found him always a pleasure to work with. |
2024-08-30 11:47:08 +0200 | <Franciman> | he did a lot of fights |
2024-08-30 11:47:18 +0200 | <Franciman> | with the Haskell Community to impose his point of view |
2024-08-30 11:47:53 +0200 | <haskellbridge> | <sm> I think we're not going to agree on anything like this, let's not go there |
2024-08-30 11:48:39 +0200 | tcard | (~tcard@p3940165-ipxg22501hodogaya.kanagawa.ocn.ne.jp) (Ping timeout: 252 seconds) |
2024-08-30 11:51:42 +0200 | youthlic | (~Thunderbi@user/youthlic) |
2024-08-30 11:55:33 +0200 | mreh | (~matthew@host86-160-168-12.range86-160.btcentralplus.com) (Ping timeout: 248 seconds) |
2024-08-30 11:57:55 +0200 | <Franciman> | ok |
2024-08-30 11:58:14 +0200 | <Franciman> | speaking of which, where is hvr? |
2024-08-30 11:58:23 +0200 | rosco | (~rosco@175.136.158.234) |
2024-08-30 11:58:23 +0200 | rosco | (~rosco@175.136.158.234) (Client Quit) |
2024-08-30 11:59:06 +0200 | youthlic | (~Thunderbi@user/youthlic) (Ping timeout: 276 seconds) |
2024-08-30 12:04:47 +0200 | mreh | (~matthew@host86-160-168-12.range86-160.btcentralplus.com) |
2024-08-30 12:06:38 +0200 | echoreply | (~echoreply@45.32.163.16) (Ping timeout: 252 seconds) |
2024-08-30 12:07:02 +0200 | echoreply | (~echoreply@2001:19f0:9002:1f3b:5400:ff:fe6f:8b8d) |
2024-08-30 12:08:22 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 12:09:25 +0200 | lxsameer | (~lxsameer@Serene/lxsameer) (Ping timeout: 248 seconds) |
2024-08-30 12:12:45 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 246 seconds) |
2024-08-30 12:15:06 +0200 | <haskellbridge> | <sm> https://www.reddit.com/r/haskell/comments/1f2frrg/upgrading_from_ghc_810_to_ghc_96_an_experience/ has spawned quite an interesting discussion |
2024-08-30 12:22:50 +0200 | sawilagar | (~sawilagar@user/sawilagar) |
2024-08-30 12:23:49 +0200 | Square2 | (~Square4@user/square) |
2024-08-30 12:37:06 +0200 | lortabac | (~lortabac@2a01:e0a:541:b8f0:55ab:e185:7f81:54a4) |
2024-08-30 12:39:33 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 12:39:52 +0200 | ZharMeny | (~ZharMeny@user/ZharMeny) |
2024-08-30 12:44:37 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 248 seconds) |
2024-08-30 12:55:26 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 12:58:29 +0200 | cfricke | (~cfricke@user/cfricke) (Ping timeout: 248 seconds) |
2024-08-30 13:00:01 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 244 seconds) |
2024-08-30 13:00:32 +0200 | Tuplanolla | (~Tuplanoll@91-159-69-59.elisa-laajakaista.fi) |
2024-08-30 13:09:57 +0200 | rubin55 | (sid666177@id-666177.lymington.irccloud.com) |
2024-08-30 13:11:03 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 13:11:32 +0200 | ftzm | (~ftzm@085080243169.dynamic.telenor.dk) (Ping timeout: 255 seconds) |
2024-08-30 13:11:47 +0200 | cfricke | (~cfricke@user/cfricke) |
2024-08-30 13:16:34 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 248 seconds) |
2024-08-30 13:17:31 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 13:18:14 +0200 | cfricke | (~cfricke@user/cfricke) (Ping timeout: 260 seconds) |
2024-08-30 13:19:11 +0200 | dysthesis | (~dysthesis@user/dysthesis) (Ping timeout: 260 seconds) |
2024-08-30 13:22:40 +0200 | tromp | (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…) |
2024-08-30 13:23:03 +0200 | <absence> | Is there a way to derive the obvious Bifunctor instance for this using deriving via or something? newtype ValidationNe e a = ValidationNe (Validation (NonEmpty e) a) deriving newtype (Functor, Applicative) |
2024-08-30 13:25:22 +0200 | <merijn> | I don't think GHC has anything like that, but there may be some TH/generics library that can? |
2024-08-30 13:25:42 +0200 | <merijn> | but, tbh, it'd probably be less work to implement the Bifunctor than finding a library for that |
2024-08-30 13:27:54 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Read error: Connection reset by peer) |
2024-08-30 13:28:03 +0200 | merijn | (~merijn@77.242.116.146) |
2024-08-30 13:29:55 +0200 | rosco | (~rosco@175.136.158.234) |
2024-08-30 13:31:43 +0200 | cfricke | (~cfricke@user/cfricke) |
2024-08-30 13:32:23 +0200 | <absence> | merijn: Yes, if it involves additional libraries, one line of boilerplate is probably easiest. |
2024-08-30 13:34:22 +0200 | <lortabac> | I wonder why 'second' is not 'fmap' by default |
2024-08-30 13:36:32 +0200 | <ncf> | because it's bimap id by default |
2024-08-30 13:37:16 +0200 | <lortabac> | 'fmap' would make more sense to me |
2024-08-30 13:37:33 +0200 | CrunchyFlakes | (~CrunchyFl@ip-109-42-115-64.web.vodafone.de) (Read error: Connection reset by peer) |
2024-08-30 13:37:40 +0200 | <lortabac> | you'd be able to define an instance with 'first' only |
2024-08-30 13:38:13 +0200 | <lortabac> | and only define 'bimap' if there is a more efficient implementation |
2024-08-30 13:40:31 +0200 | CrunchyFlakes | (~CrunchyFl@ip-109-42-115-64.web.vodafone.de) |
2024-08-30 13:42:49 +0200 | <absence> | lortabac: Maybe for compatibility reasons? Functor wasn't originally a superclass. |
2024-08-30 13:43:15 +0200 | <lortabac> | maybe they didn't want to break existing unlawful instances |
2024-08-30 13:45:50 +0200 | <absence> | Or existing instances that implement Functor using second. |
2024-08-30 13:47:03 +0200 | statusbot | (~statusbot@ec2-34-198-122-184.compute-1.amazonaws.com) (Remote host closed the connection) |
2024-08-30 13:47:18 +0200 | statusbot | (~statusbot@ec2-34-198-122-184.compute-1.amazonaws.com) |
2024-08-30 13:50:03 +0200 | <lortabac> | ah right, I didn't think about that |
2024-08-30 14:20:45 +0200 | CrunchyFlakes | (~CrunchyFl@ip-109-42-115-64.web.vodafone.de) (Read error: Connection reset by peer) |
2024-08-30 14:21:02 +0200 | CrunchyFlakes | (~CrunchyFl@ip-109-42-115-64.web.vodafone.de) |
2024-08-30 14:21:03 +0200 | ft | (~ft@p4fc2a393.dip0.t-ipconnect.de) |
2024-08-30 14:23:58 +0200 | CiaoSen | (~Jura@2a05:5800:247:2000:ca4b:d6ff:fec1:99da) |
2024-08-30 14:29:15 +0200 | CiaoSen | (~Jura@2a05:5800:247:2000:ca4b:d6ff:fec1:99da) (Ping timeout: 252 seconds) |
2024-08-30 14:30:28 +0200 | xff0x | (~xff0x@2405:6580:b080:900:6ee3:d4d7:e5a8:4661) |
2024-08-30 14:30:39 +0200 | machinedgod | (~machinedg@d50-99-47-73.abhsia.telus.net) |
2024-08-30 14:30:41 +0200 | Miroboru | (~myrvoll@178-164-114.82.3p.ntebredband.no) (Ping timeout: 248 seconds) |
2024-08-30 14:32:46 +0200 | Miroboru | (~myrvoll@178-164-114.82.3p.ntebredband.no) |
2024-08-30 14:32:52 +0200 | poxel | (~lennart@user/poxel) |
2024-08-30 14:38:21 +0200 | ddellacosta | (~ddellacos@ool-44c73c8f.dyn.optonline.net) (Ping timeout: 246 seconds) |
2024-08-30 14:47:52 +0200 | AlexZenon | (~alzenon@178.34.150.250) (Quit: ;-) |
2024-08-30 14:52:02 +0200 | AlexNoo | (~AlexNoo@178.34.150.250) (Quit: Leaving) |
2024-08-30 14:54:10 +0200 | regev | (~dararam@147.236.231.188) |
2024-08-30 15:00:00 +0200 | JuanDaugherty | (~juan@user/JuanDaugherty) |
2024-08-30 15:03:42 +0200 | cfricke | (~cfricke@user/cfricke) (Ping timeout: 272 seconds) |
2024-08-30 15:12:35 +0200 | regev | (~dararam@147.236.231.188) (Ping timeout: 255 seconds) |
2024-08-30 15:13:22 +0200 | weary-traveler | (~user@user/user363627) |
2024-08-30 15:14:42 +0200 | regev | (~dararam@147.236.231.188) |
2024-08-30 15:16:03 +0200 | mreh | (~matthew@host86-160-168-12.range86-160.btcentralplus.com) (Ping timeout: 276 seconds) |
2024-08-30 15:17:40 +0200 | regev | (~dararam@147.236.231.188) (Read error: Connection reset by peer) |
2024-08-30 15:20:38 +0200 | AlexZenon | (~alzenon@178.34.150.250) |
2024-08-30 15:20:55 +0200 | AlexNoo | (~AlexNoo@178.34.150.250) |
2024-08-30 15:25:11 +0200 | JuanDaugherty | (~juan@user/JuanDaugherty) (Quit: JuanDaugherty) |
2024-08-30 15:25:58 +0200 | Solution | (~Solution@78-131-74-26.pool.digikabel.hu) |
2024-08-30 15:34:30 +0200 | ash3en | (~Thunderbi@2a02:3100:7fb9:6a00:1cf6:2c47:e97c:d5d1) (Quit: ash3en) |
2024-08-30 15:35:33 +0200 | Blasius | (~Blasius@5ec169d9.skybroadband.com) (Ping timeout: 276 seconds) |
2024-08-30 15:47:57 +0200 | Miroboru | (~myrvoll@178-164-114.82.3p.ntebredband.no) (Quit: Lost terminal) |
2024-08-30 16:00:59 +0200 | xff0x | (~xff0x@2405:6580:b080:900:6ee3:d4d7:e5a8:4661) (Ping timeout: 260 seconds) |
2024-08-30 16:01:36 +0200 | xff0x | (~xff0x@2405:6580:b080:900:15aa:6ce:9db7:891e) |
2024-08-30 16:10:02 +0200 | comerijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 16:13:22 +0200 | merijn | (~merijn@77.242.116.146) (Ping timeout: 272 seconds) |
2024-08-30 16:13:31 +0200 | Sgeo | (~Sgeo@user/sgeo) |
2024-08-30 16:20:04 +0200 | comerijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 260 seconds) |
2024-08-30 16:22:36 +0200 | cfricke | (~cfricke@user/cfricke) |
2024-08-30 16:24:07 +0200 | Smiles | (uid551636@id-551636.lymington.irccloud.com) (Quit: Connection closed for inactivity) |
2024-08-30 16:31:52 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 16:38:54 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 260 seconds) |
2024-08-30 16:49:55 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 16:50:27 +0200 | oneeyedalien | (~oneeyedal@user/oneeyedalien) |
2024-08-30 16:51:16 +0200 | lortabac | (~lortabac@2a01:e0a:541:b8f0:55ab:e185:7f81:54a4) (Quit: WeeChat 4.2.2) |
2024-08-30 16:55:37 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 244 seconds) |
2024-08-30 17:01:47 +0200 | oneeyedalien | (~oneeyedal@user/oneeyedalien) (Ping timeout: 252 seconds) |
2024-08-30 17:02:41 +0200 | cfricke | (~cfricke@user/cfricke) (Quit: WeeChat 4.2.2) |
2024-08-30 17:06:53 +0200 | spew | (~spew@201.141.99.170) |
2024-08-30 17:07:05 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 17:12:21 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 248 seconds) |
2024-08-30 17:12:48 +0200 | tromp | (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) |
2024-08-30 17:23:20 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 17:26:52 +0200 | rvalue | (~rvalue@user/rvalue) (Read error: Connection reset by peer) |
2024-08-30 17:27:22 +0200 | rvalue | (~rvalue@user/rvalue) |
2024-08-30 17:28:06 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 246 seconds) |
2024-08-30 17:39:08 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 17:40:44 +0200 | ash3en | (~Thunderbi@2a03:7846:b6eb:101:93ac:a90a:da67:f207) |
2024-08-30 17:40:59 +0200 | ash3en | (~Thunderbi@2a03:7846:b6eb:101:93ac:a90a:da67:f207) (Client Quit) |
2024-08-30 17:41:45 +0200 | ash3en | (~Thunderbi@2a03:7846:b6eb:101:93ac:a90a:da67:f207) |
2024-08-30 17:44:15 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 252 seconds) |
2024-08-30 17:44:33 +0200 | srazkvt | (~sarah_@2a01:e0a:483:6900:b6d5:d9cd:2f20:2e49) |
2024-08-30 17:50:24 +0200 | oneeyedalien | (~oneeyedal@user/oneeyedalien) |
2024-08-30 17:54:55 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 18:00:21 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 248 seconds) |
2024-08-30 18:08:06 +0200 | ash3en | (~Thunderbi@2a03:7846:b6eb:101:93ac:a90a:da67:f207) (Ping timeout: 265 seconds) |
2024-08-30 18:11:11 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 18:14:08 +0200 | lxsameer | (~lxsameer@Serene/lxsameer) |
2024-08-30 18:14:44 +0200 | tromp | (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…) |
2024-08-30 18:16:13 +0200 | athan_ | (~athan@syn-098-153-145-140.biz.spectrum.com) (Quit: Konversation terminated!) |
2024-08-30 18:17:41 +0200 | athan | (~athan@syn-098-153-145-140.biz.spectrum.com) |
2024-08-30 18:18:04 +0200 | machinedgod | (~machinedg@d50-99-47-73.abhsia.telus.net) (Ping timeout: 252 seconds) |
2024-08-30 18:22:09 +0200 | pavonia | (~user@user/siracusa) (Quit: Bye!) |
2024-08-30 18:24:54 +0200 | <Inst> | well, have to hope for snoyman's safety |
2024-08-30 18:30:00 +0200 | <EvanR> | say what |
2024-08-30 18:32:37 +0200 | <Inst> | sorry, reply to long-dead conversaton (iirc, Snoyman is in a warzone, it's just some polite thoughts) |
2024-08-30 18:34:40 +0200 | <Inst> | (his declared location is 10 km from the lebanon border) |
2024-08-30 18:34:52 +0200 | <Inst> | and i'll drop it |
2024-08-30 18:40:46 +0200 | regev | (~dararam@147.236.228.71) |
2024-08-30 18:42:50 +0200 | tromp | (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) |
2024-08-30 18:43:04 +0200 | <EvanR> | sorry to hear that |
2024-08-30 18:43:35 +0200 | Smiles | (uid551636@id-551636.lymington.irccloud.com) |
2024-08-30 18:44:51 +0200 | VictorHugenay | (~VictorHug@user/VictorHugenay) |
2024-08-30 18:46:13 +0200 | ski | (~ski@217.65.136.250) (Ping timeout: 248 seconds) |
2024-08-30 18:47:49 +0200 | ski | (~ski@217.65.136.250) |
2024-08-30 18:48:54 +0200 | <regev> | hey everyone, i have a begginer question about the Show typeclass. |
2024-08-30 18:49:34 +0200 | <regev> | i understand the type class Eq, and how type can automatically be part of it. |
2024-08-30 18:50:09 +0200 | <regev> | i cant understand how a type can automatically deriving of Show |
2024-08-30 18:50:37 +0200 | <regev> | Where can i find the implementation of it? or is it compiler internal? |
2024-08-30 18:51:22 +0200 | <ncf> | https://www.haskell.org/onlinereport/haskell2010/haskellch11.html#x18-18600011.4 |
2024-08-30 18:51:36 +0200 | <haskellbridge> | <sm> basic types have simple show implementations, and more complex types are just lots of those combined |
2024-08-30 18:52:48 +0200 | <haskellbridge> | <sm> in my mind at least. ncf's link looks much more complicated |
2024-08-30 18:53:18 +0200 | <EvanR> | imagine that ADTs only have () as a leaf types and the show implementation is "()". Now extrapolate however you think Eq works using that at the base |
2024-08-30 18:54:04 +0200 | <EvanR> | the real thing is more complicated because of efficiency of building a big string = list of chars |
2024-08-30 18:54:08 +0200 | <mauke> | regev: yes, "deriving" is built into the compiler |
2024-08-30 18:55:05 +0200 | <mauke> | the compiler knows what your source code looks like, so it can construct a facsimile in string form |
2024-08-30 18:56:04 +0200 | <regev> | mauke: thanks, that was the clarification i needed |
2024-08-30 18:56:08 +0200 | <EvanR> | you can play similar games by using Generic |
2024-08-30 18:56:18 +0200 | <EvanR> | it gives you access to constructor names and field names for example |
2024-08-30 18:56:28 +0200 | <mauke> | or Data.Data.Data |
2024-08-30 18:56:46 +0200 | <EvanR> | triple Dat |
2024-08-30 18:57:02 +0200 | <EvanR> | I had totally forgotten about Data.Data |
2024-08-30 19:01:12 +0200 | dehsou^ | (~dehsou@c-98-242-74-66.hsd1.ga.comcast.net) (Ping timeout: 246 seconds) |
2024-08-30 19:04:22 +0200 | spew | (~spew@201.141.99.170) (Ping timeout: 272 seconds) |
2024-08-30 19:09:12 +0200 | tzh | (~tzh@c-76-115-131-146.hsd1.or.comcast.net) |
2024-08-30 19:10:56 +0200 | spew | (~spew@201.141.99.170) |
2024-08-30 19:11:55 +0200 | L29Ah | (~L29Ah@wikipedia/L29Ah) () |
2024-08-30 19:16:15 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 246 seconds) |
2024-08-30 19:17:52 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 19:19:20 +0200 | tromp | (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…) |
2024-08-30 19:22:06 +0200 | Alleria | (~Alleria@user/alleria) |
2024-08-30 19:22:55 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 264 seconds) |
2024-08-30 19:23:46 +0200 | JuanDaugherty | (~juan@user/JuanDaugherty) |
2024-08-30 19:26:37 +0200 | srazkvt | (~sarah_@2a01:e0a:483:6900:b6d5:d9cd:2f20:2e49) (Quit: Leaving) |
2024-08-30 19:29:05 +0200 | vpan | (~vpan@212.117.1.172) (Quit: Leaving.) |
2024-08-30 19:33:33 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 19:36:25 +0200 | <monochrom> | The presence of precedence levels and infix data constructors causes parenthesizing. That's the only complication. |
2024-08-30 19:38:18 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 246 seconds) |
2024-08-30 19:39:16 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 19:39:27 +0200 | kuribas | (~user@ptr-17d51ep5b2wbec6a4va.18120a2.ip6.access.telenet.be) (Quit: ERC (IRC client for Emacs 27.1)) |
2024-08-30 19:40:33 +0200 | tromp | (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) |
2024-08-30 19:41:28 +0200 | rosco | (~rosco@175.136.158.234) (Quit: Lost terminal) |
2024-08-30 19:44:27 +0200 | L29Ah | (~L29Ah@wikipedia/L29Ah) |
2024-08-30 19:45:32 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 272 seconds) |
2024-08-30 19:49:19 +0200 | ash3en | (~Thunderbi@2a03:7846:b6eb:101:93ac:a90a:da67:f207) |
2024-08-30 19:51:11 +0200 | <ski> | regev : generally, it generates a definition of `showsPrec' (*not* `show' !), which makes the definition (if written correctly) properly take precedences into account, inserting brackets, and which makes your `Show' instance properly compose and combine with instances coming from other code. (which is why it's generally a bad idea to make your `Show' instance do some custom pretty-printed thing. `Show' is |
2024-08-30 19:51:17 +0200 | <ski> | not for that) |
2024-08-30 19:52:33 +0200 | <ski> | .. if you want to hand-define a `Show' instance, then `showsPrec' (not `show') is also what you normally should define. for very simple cases (an enumeration type, with none of the data constructors taking any parameters / having any components), you can define `show' instead |
2024-08-30 19:53:20 +0200 | <ski> | e.g., let's say you define a type of binary trees : |
2024-08-30 19:53:28 +0200 | <ski> | data Tree a = Leaf a |
2024-08-30 19:53:43 +0200 | <ski> | | Branch (Tree a) (Tree a) |
2024-08-30 19:53:59 +0200 | <ski> | deriving (Eq,Show,Read) |
2024-08-30 19:54:15 +0200 | <ski> | then the generated `Show' instance would look something like |
2024-08-30 19:54:26 +0200 | <ski> | instance Show a => Show (Tree a) |
2024-08-30 19:54:28 +0200 | <ski> | where |
2024-08-30 19:55:16 +0200 | <ski> | showsPrec p (Leaf x) = showParen (p > 10) |
2024-08-30 19:55:37 +0200 | <ski> | $ showString "Leaf " |
2024-08-30 19:55:49 +0200 | <ski> | . showsPrec 11 x |
2024-08-30 19:56:07 +0200 | <ski> | showsPrec p (Branch l r) = showParen (p > 10) |
2024-08-30 19:56:12 +0200 | Alleria | (~Alleria@user/alleria) (Ping timeout: 276 seconds) |
2024-08-30 19:56:16 +0200 | <ski> | $ showString "Branch " |
2024-08-30 19:56:22 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 19:56:23 +0200 | <ski> | . showsPrec 11 l |
2024-08-30 19:56:27 +0200 | <ski> | . showChar ' ' |
2024-08-30 19:56:29 +0200 | <ski> | . showsPrec 11 r |
2024-08-30 19:57:13 +0200 | <ski> | (the calls to `showsPrec' on `l' and `r' are recursive calls. the call using `x' appeals to the `Show a' constraint, deferring to the `Show' instance of the element type) |
2024-08-30 19:57:24 +0200 | regev | (~dararam@147.236.228.71) (Read error: Connection reset by peer) |
2024-08-30 19:58:43 +0200 | <ski> | `10' here is the precedence level of the (left associative) "invisible infix operator" of application (in `Leaf x', `Leaf' is applied to `x'; and in `Branch l r', `Branch' is applied to `l', and the result of that is applied to `r') |
2024-08-30 20:00:33 +0200 | <ski> | and `10' is the next precedence, which is used on the right hand side of the infix operator, because it is a left-associative operator (`f x y' means `(f x) y'). (if we didn't have `Leaf' to the left in `Leaf x', but an arbitrary expression, we'd have used `showsPrec 10' for showing that expression. but this doesn't happen with data constructors) |
2024-08-30 20:00:41 +0200 | <ski> | er .. `11' is the next precedence |
2024-08-30 20:02:36 +0200 | <ski> | (it would be possible to define a data type, with an infix data constructor, and declare a precedence and associativity for it. although, iirc, GHC's `Show' will ignore the associativity (even though it would be easy to take it into account), so if you want your `Show' to not insert brackets redundant due to associativity of your data constructor, you do need to manually write your `Show' instance) |
2024-08-30 20:03:37 +0200 | regev | (~dararam@147.236.228.71) |
2024-08-30 20:03:49 +0200 | ski | looks at regev |
2024-08-30 20:04:35 +0200 | KicksonButt_ | (~AdminUser@187.21.174.221) |
2024-08-30 20:07:20 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 252 seconds) |
2024-08-30 20:09:23 +0200 | KicksonButt | (~KicksonBu@187.21.174.221) |
2024-08-30 20:09:43 +0200 | <KicksonButt_> | testing |
2024-08-30 20:11:04 +0200 | <ski> | testing failed |
2024-08-30 20:11:48 +0200 | KicksonButt | (~KicksonBu@187.21.174.221) (Quit: Client closed) |
2024-08-30 20:12:17 +0200 | <probie> | apparently you should have said it succeeded |
2024-08-30 20:15:45 +0200 | <dmj`> | please insert more coins |
2024-08-30 20:18:48 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 20:19:59 +0200 | pikajude | (~jude@2001:19f0:ac01:373:5400:2ff:fe86:3274) (Ping timeout: 260 seconds) |
2024-08-30 20:20:20 +0200 | pikajude | (~jude@149.28.207.64) |
2024-08-30 20:24:05 +0200 | misterfish | (~misterfis@84.53.85.146) |
2024-08-30 20:24:46 +0200 | <monochrom> | Did you know: IRC servers do not echo the messages you send. If you say "testing" then it is only your client, not the server, that displays your own "testing". |
2024-08-30 20:24:49 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 248 seconds) |
2024-08-30 20:25:47 +0200 | <EvanR> | does anyone see this -- automatic yes |
2024-08-30 20:26:19 +0200 | <monochrom> | Boltzmann IRC client. >:) |
2024-08-30 20:27:33 +0200 | Digit | (~user@user/digit) (Ping timeout: 248 seconds) |
2024-08-30 20:30:57 +0200 | machinedgod | (~machinedg@d50-99-47-73.abhsia.telus.net) |
2024-08-30 20:33:16 +0200 | <KicksonButt_> | Is it possible to reply to specific message in IRC? |
2024-08-30 20:33:43 +0200 | <[exa]> | KicksonButt_: not really, it simulates a real-life conversation where all speech is lost in the mess of history |
2024-08-30 20:35:24 +0200 | <[exa]> | (technically, the messages aren't stored anywhere for any longer period of time than necessary for distributing them to everyone concerned, so there's also no message identifiers which would allow you to implement this) |
2024-08-30 20:35:24 +0200 | <KicksonButt_> | At least it seems you can reply to specific user |
2024-08-30 20:35:33 +0200 | <ski> | typically people just mention the nickname of the recipient, or reference (or quote) part of the conversation (or both), KicksonButt_ |
2024-08-30 20:36:11 +0200 | <[exa]> | KicksonButt_: well not even that, but most IRC clients will recognize if your own nickname is used in the message (esp in the beginning) and will blink/play a sound/do something sensible for that |
2024-08-30 20:36:35 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 20:36:37 +0200 | peterbecich | (~Thunderbi@syn-047-229-123-186.res.spectrum.com) |
2024-08-30 20:37:12 +0200 | <KicksonButt_> | So you just had to type my nickname, the effects I got are from my client |
2024-08-30 20:37:19 +0200 | <[exa]> | yap |
2024-08-30 20:37:22 +0200 | <KicksonButt_> | Thanks |
2024-08-30 20:37:25 +0200 | <[exa]> | also most clients allow tabbing the nicknames |
2024-08-30 20:37:39 +0200 | <KicksonButt_> | [exa]: Oh ok |
2024-08-30 20:37:42 +0200 | <[exa]> | the `Nickname: ....messate...` is a kinda convention, yes |
2024-08-30 20:37:42 +0200 | <ski> | KicksonButt_ : there's also private messages (sending only to a particular user, rather than to all (current) members of some particular channel) |
2024-08-30 20:38:07 +0200 | <ski> | some people like typing a comma, rather than a colon |
2024-08-30 20:38:19 +0200 | ski | does both, although more commonly a colon |
2024-08-30 20:39:57 +0200 | <[exa]> | KicksonButt_: btw people nowadays tend to connect via matrix.org clients or something similar, there the features are a lil bit more rich, for the price that you have an intermediate server in the middle that stores your actions |
2024-08-30 20:39:58 +0200 | <EvanR> | if you're elitist you can use a semicolon |
2024-08-30 20:40:42 +0200 | [exa] | reaches for an em dash |
2024-08-30 20:40:52 +0200 | <EvanR> | lol |
2024-08-30 20:41:13 +0200 | <[exa]> | EvanR— not bad |
2024-08-30 20:41:45 +0200 | <[exa]> | ok so, back to why I came here |
2024-08-30 20:42:04 +0200 | <monochrom> | Did you know: IRC uses the same PRIVMSG message for both "private" and "public for channel" messages. The only difference is that the latter uses the channel name for "nickname". |
2024-08-30 20:42:47 +0200 | <monochrom> | I would actually love to rationalize that with "private to the channel" but it's clearly a stretch. >:) |
2024-08-30 20:43:11 +0200 | <EvanR> | economy of interface |
2024-08-30 20:43:22 +0200 | <[exa]> | there's `partition` which splits a list into 2 by a predicate. If I modify the 2 lists (with different mappy functions), is there a way to unpartition them back to get the same order as original? |
2024-08-30 20:43:46 +0200 | <[exa]> | Normally I'd just `map` different functions based on the predicate, but here I actually need to group a few monad actions specific to both groups |
2024-08-30 20:44:10 +0200 | <monochrom> | No, you will have to attach original order if you want to recover original order. |
2024-08-30 20:44:16 +0200 | <monochrom> | Entropy increases. |
2024-08-30 20:44:26 +0200 | <[exa]> | yeah that's expected |
2024-08-30 20:44:27 +0200 | <EvanR> | merging two sorted lists is a nice lazy thing |
2024-08-30 20:44:33 +0200 | <monochrom> | Information wants to be lost. Entropy wants to increase. |
2024-08-30 20:44:47 +0200 | <EvanR> | assuming your mapping doesn't alter the ordering |
2024-08-30 20:44:49 +0200 | <[exa]> | more like, is there some super nice representation for this order reconstruction? |
2024-08-30 20:44:53 +0200 | Digit | (~user@user/digit) |
2024-08-30 20:44:55 +0200 | <ski> | [exa] : `zip [0 ..]' ? |
2024-08-30 20:45:08 +0200 | <[exa]> | I could do 2 lists of integers or so but that sounds unfunny |
2024-08-30 20:45:39 +0200 | <[exa]> | oh wait I can just store the trues/falses from the predicate and glue it later |
2024-08-30 20:46:10 +0200 | <EvanR> | you already know which list was true and which was false... one is all true the other is all false |
2024-08-30 20:46:28 +0200 | sawilagar | (~sawilagar@user/sawilagar) (Quit: Leaving) |
2024-08-30 20:46:40 +0200 | <monochrom> | You do not know ([1], [2]) came from [1,2] or [2,1]. |
2024-08-30 20:46:52 +0200 | <monochrom> | s/came from/came from whether/ |
2024-08-30 20:47:11 +0200 | <EvanR> | attaching the integers would let you do the merge two sorted lists to get sorted list thing |
2024-08-30 20:47:17 +0200 | <EvanR> | then you can drop the integers at the end |
2024-08-30 20:48:23 +0200 | <[exa]> | yeah but integers |
2024-08-30 20:48:31 +0200 | <monochrom> | Int is enough. >:) |
2024-08-30 20:48:42 +0200 | <EvanR> | good ol Int |
2024-08-30 20:48:50 +0200 | <EvanR> | tireless workhorse |
2024-08-30 20:49:06 +0200 | <[exa]> | ah yeah but it's linear so all OK there actually |
2024-08-30 20:49:25 +0200 | peterbecich | (~Thunderbi@syn-047-229-123-186.res.spectrum.com) (Ping timeout: 248 seconds) |
2024-08-30 20:49:48 +0200 | weary-traveler | (~user@user/user363627) (Remote host closed the connection) |
2024-08-30 20:50:21 +0200 | <EvanR> | partitioning a sorted list gives two sorted lists? of course it does, sure yeah |
2024-08-30 20:51:38 +0200 | neuroevolutus | (~neuroevol@37.19.200.161) |
2024-08-30 20:51:48 +0200 | <EvanR> | or write this one off thing |
2024-08-30 20:52:38 +0200 | <EvanR> | nvm you said it needs to be monaded (monoided?) before remerging |
2024-08-30 20:52:40 +0200 | Smiles | (uid551636@id-551636.lymington.irccloud.com) (Quit: Connection closed for inactivity) |
2024-08-30 20:54:24 +0200 | Square | (~Square@user/square) |
2024-08-30 20:55:49 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 248 seconds) |
2024-08-30 20:55:49 +0200 | regev | (~dararam@147.236.228.71) (Read error: Connection reset by peer) |
2024-08-30 20:57:12 +0200 | Square2 | (~Square4@user/square) (Ping timeout: 252 seconds) |
2024-08-30 20:58:50 +0200 | JuanDaugherty | (~juan@user/JuanDaugherty) (Quit: JuanDaugherty) |
2024-08-30 20:59:00 +0200 | jinsun | (~jinsun@user/jinsun) |
2024-08-30 21:01:11 +0200 | tromp | (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…) |
2024-08-30 21:01:59 +0200 | regev | (~dararam@147.236.228.71) |
2024-08-30 21:03:43 +0200 | troojg | (~troojg@user/troojg) |
2024-08-30 21:05:00 +0200 | tromp | (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) |
2024-08-30 21:06:17 +0200 | divya | (~user@202.170.201.250) (Ping timeout: 255 seconds) |
2024-08-30 21:07:33 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 21:10:58 +0200 | <[exa]> | https://play.haskell.org/saved/t1TRaU2w <- ok this is kinda what I had in mind (cc EvanR monochrom ) |
2024-08-30 21:11:01 +0200 | <[exa]> | thanks for hints! |
2024-08-30 21:11:13 +0200 | lxsameer | (~lxsameer@Serene/lxsameer) (Ping timeout: 248 seconds) |
2024-08-30 21:11:22 +0200 | <[exa]> | (more hints welcome, esp how to hide the ugly zip/fst/snd) |
2024-08-30 21:14:55 +0200 | <EvanR> | that unpartition doesn't make sense to me |
2024-08-30 21:15:37 +0200 | <EvanR> | adding the Bool doesn't add any information |
2024-08-30 21:16:19 +0200 | <EvanR> | oh it doesn't add the bool, it's encoding the original structure |
2024-08-30 21:17:04 +0200 | <ski> | (it determines the combination chosen by the predicate, on the input list) |
2024-08-30 21:17:20 +0200 | <[exa]> | yeah it's literally for reconstructing the original after gore has been applied to both partitions in separation |
2024-08-30 21:17:21 +0200 | <EvanR> | I got a simplification |
2024-08-30 21:17:27 +0200 | <[exa]> | I just got here: |
2024-08-30 21:17:29 +0200 | <EvanR> | traverse print [1..10] |
2024-08-30 21:17:40 +0200 | <[exa]> | https://play.haskell.org/saved/qIEMWImC |
2024-08-30 21:18:14 +0200 | sawilagar | (~sawilagar@user/sawilagar) |
2024-08-30 21:18:29 +0200 | <tomsmeding> | [exa]: does the previous paste even do what you want? |
2024-08-30 21:18:37 +0200 | <tomsmeding> | oh wait it does, I cannot read |
2024-08-30 21:18:39 +0200 | <[exa]> | yes |
2024-08-30 21:18:53 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 255 seconds) |
2024-08-30 21:19:20 +0200 | L29Ah | (~L29Ah@wikipedia/L29Ah) () |
2024-08-30 21:19:40 +0200 | regev | (~dararam@147.236.228.71) (Read error: Connection reset by peer) |
2024-08-30 21:19:46 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 21:20:35 +0200 | <[exa]> | basically the use case is that I have X items and algorithm that is processing them, and all of them choose between 2 paths of starting the algorithm, so it's very useful to just do the step once and re-use the result in the whole subgroup |
2024-08-30 21:20:42 +0200 | <[exa]> | (and this gets repeated recursively) |
2024-08-30 21:20:50 +0200 | <[exa]> | (it's a kinda tree traversal but reading the tree is pricey) |
2024-08-30 21:21:01 +0200 | <[exa]> | s/traversal/search/ |
2024-08-30 21:22:08 +0200 | <[exa]> | (so here instead of e.g. going through the root once for each item, I can group the items and hopefully only process the root twice) |
2024-08-30 21:23:43 +0200 | <tomsmeding> | [exa]: if you s/otherwise/let/ the two cases of partitionR align |
2024-08-30 21:24:06 +0200 | <[exa]> | O_o |
2024-08-30 21:24:12 +0200 | neuroevolutus | (~neuroevol@37.19.200.161) (Quit: Client closed) |
2024-08-30 21:24:16 +0200 | <[exa]> | how come that works?! |
2024-08-30 21:24:22 +0200 | <tomsmeding> | (glguy discovered (?) (mentioned, in any case) this yesterday) |
2024-08-30 21:24:26 +0200 | <tomsmeding> | it's an empty let block |
2024-08-30 21:24:29 +0200 | <tomsmeding> | > let in 7 |
2024-08-30 21:24:29 +0200 | regev | (~dararam@147.236.228.71) |
2024-08-30 21:24:31 +0200 | <lambdabot> | 7 |
2024-08-30 21:24:46 +0200 | <c_wraith> | that came up when we were breaking microhaskell |
2024-08-30 21:25:02 +0200 | <c_wraith> | (actually, any let block seems to break it. But that was a funny minimal test case) |
2024-08-30 21:25:09 +0200 | <tomsmeding> | https://ircbrowse.tomsmeding.com/day/lchaskell/2024/08/29?id=1342911#trid1342911 |
2024-08-30 21:25:17 +0200 | <[exa]> | first that `do` parsing thing and now this :D |
2024-08-30 21:25:23 +0200 | <[exa]> | cool find though, thanks |
2024-08-30 21:25:24 +0200 | <EvanR> | let out "dogs" |
2024-08-30 21:25:30 +0200 | <EvanR> | "woof, woof" |
2024-08-30 21:25:31 +0200 | <tomsmeding> | > let in "dogs" |
2024-08-30 21:25:32 +0200 | <lambdabot> | "dogs" |
2024-08-30 21:25:45 +0200 | weary-traveler | (~user@user/user363627) |
2024-08-30 21:25:54 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 260 seconds) |
2024-08-30 21:26:45 +0200 | ash3en | (~Thunderbi@2a03:7846:b6eb:101:93ac:a90a:da67:f207) (Ping timeout: 265 seconds) |
2024-08-30 21:27:43 +0200 | euphores | (~SASL_euph@user/euphores) (Quit: Leaving.) |
2024-08-30 21:27:51 +0200 | JuanDaugherty | (~juan@user/JuanDaugherty) |
2024-08-30 21:27:52 +0200 | <ski> | can't recall if a(n empty) `let' pattern guard has been mentioned in here before, but a(n empty) `let' list comprehension guard definitely has, since years ago |
2024-08-30 21:28:28 +0200 | <[exa]> | an empty `let` in `do` syntax is okay as well, right? |
2024-08-30 21:28:33 +0200 | <tomsmeding> | these things tend to come back when new people (re)discover them |
2024-08-30 21:28:40 +0200 | <tomsmeding> | > do { let; 7 } |
2024-08-30 21:28:42 +0200 | <lambdabot> | <hint>:1:13: error: parse error on input ‘}’ |
2024-08-30 21:28:53 +0200 | <tomsmeding> | > do { let {}; 7 } |
2024-08-30 21:28:54 +0200 | <lambdabot> | 7 |
2024-08-30 21:29:12 +0200 | <EvanR> | do 7 is also known as a dolet |
2024-08-30 21:29:15 +0200 | <[exa]> | it's okay with blocks |
2024-08-30 21:29:31 +0200 | <[exa]> | (ie. in indented `do` you don't need the {}s) |
2024-08-30 21:29:43 +0200 | <tomsmeding> | the fact that `let in _` is allowed is handy when programming with HLS, because `let` is a parse error in an expression, and GHC refuses to do anything else when there is a syntax error in the file |
2024-08-30 21:30:03 +0200 | <tomsmeding> | [exa]: I know :) |
2024-08-30 21:31:03 +0200 | <[exa]> | HLS doesn't have a pause button? |
2024-08-30 21:31:32 +0200 | <tomsmeding> | well, having a parse error in the file is a very effective pause button |
2024-08-30 21:31:43 +0200 | <tomsmeding> | but I likely want HLS feedback while writing the bindings of the `let` :p |
2024-08-30 21:33:19 +0200 | oneeyedalien | (~oneeyedal@user/oneeyedalien) (Quit: Leaving) |
2024-08-30 21:35:01 +0200 | poxel | (~lennart@user/poxel) (Quit: WeeChat 4.4.1) |
2024-08-30 21:37:15 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 21:42:59 +0200 | euphores | (~SASL_euph@user/euphores) |
2024-08-30 21:46:55 +0200 | regev | (~dararam@147.236.228.71) (Ping timeout: 264 seconds) |
2024-08-30 21:48:47 +0200 | regev | (~dararam@147.236.228.71) |
2024-08-30 21:49:04 +0200 | mrmr155334346318 | (~mrmr@user/mrmr) (Ping timeout: 260 seconds) |
2024-08-30 21:51:44 +0200 | <[exa]> | oh wow onPartitions is too good |
2024-08-30 21:52:07 +0200 | <[exa]> | literally `onPartitions (< fetchedKey) (go left) (go right)` |
2024-08-30 21:55:03 +0200 | tromp | (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…) |
2024-08-30 21:56:31 +0200 | <tomsmeding> | [exa]: I generalised it to an arbitrary traversable https://play.haskell.org/saved/b8CeDQRZ |
2024-08-30 21:56:39 +0200 | <tomsmeding> | it also got cursed |
2024-08-30 21:57:32 +0200 | <tomsmeding> | oh the `head`s should have been back in the `gets`s |
2024-08-30 21:57:47 +0200 | <tomsmeding> | ah State.Strict also works |
2024-08-30 21:58:08 +0200 | <tomsmeding> | (artifacts of messing around) |
2024-08-30 21:58:56 +0200 | <[exa]> | cursed as in "by mfix" ? |
2024-08-30 21:59:01 +0200 | <tomsmeding> | yes |
2024-08-30 21:59:14 +0200 | <tomsmeding> | as in, the two [b] arguments to partitionR are not "arguments", really |
2024-08-30 21:59:36 +0200 | <tomsmeding> | you're not supposed to have them yet when calling partitionR :p |
2024-08-30 21:59:37 +0200 | <[exa]> | mfix is little price for the tremendous clarity that this brought to this side-side-side-project |
2024-08-30 22:00:00 +0200 | tromp | (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) |
2024-08-30 22:00:10 +0200 | spew | (~spew@201.141.99.170) (Quit: spew) |
2024-08-30 22:00:27 +0200 | <tomsmeding> | the mfix is there to traverse the input only once |
2024-08-30 22:01:32 +0200 | pavonia | (~user@user/siracusa) |
2024-08-30 22:02:00 +0200 | <tomsmeding> | what is also cursed is that `first (second _)` and `snd . fst` point to the same part of the state |
2024-08-30 22:02:27 +0200 | <tomsmeding> | cue Axman6 with "you should have used lens", probably |
2024-08-30 22:03:16 +0200 | <[exa]> | oic you let the stuff generate itself to the arguments so that you can spew it right out from the traverse |
2024-08-30 22:03:20 +0200 | <[exa]> | ok nice |
2024-08-30 22:03:29 +0200 | <tomsmeding> | yes |
2024-08-30 22:05:09 +0200 | <[exa]> | actually seems better because it's less likely to explode in weird ways (as opposed to the chain of selector thunks that the other thing will generate) |
2024-08-30 22:05:10 +0200 | regev | (~dararam@147.236.228.71) (Read error: Connection reset by peer) |
2024-08-30 22:05:45 +0200 | <[exa]> | (better w.r.t. to the actual mfix used) |
2024-08-30 22:05:50 +0200 | <ski> | tomsmeding's TyingTheKnot |
2024-08-30 22:05:58 +0200 | <tomsmeding> | inspired by https://ics-websites.science.uu.nl/docs/vakken/fp/2024/exercises/lazy.html number 2 :p |
2024-08-30 22:06:11 +0200 | <tomsmeding> | [exa]: what is "the other thing"? |
2024-08-30 22:06:27 +0200 | <[exa]> | my version of partitionR |
2024-08-30 22:06:27 +0200 | <ski> | @wiki Tying the Knot |
2024-08-30 22:06:27 +0200 | <lambdabot> | https://wiki.haskell.org/Tying_the_Knot |
2024-08-30 22:06:37 +0200 | <tomsmeding> | indeed |
2024-08-30 22:07:04 +0200 | <tomsmeding> | oh do you mean that your partitionR thing was too lazy? |
2024-08-30 22:07:12 +0200 | <tomsmeding> | I'm not sure if this is any better :D |
2024-08-30 22:10:27 +0200 | regev | (~dararam@147.236.228.71) |
2024-08-30 22:13:06 +0200 | misterfish | (~misterfis@84.53.85.146) (Ping timeout: 272 seconds) |
2024-08-30 22:13:18 +0200 | <[exa]> | where's my STG simulator when I need it :D |
2024-08-30 22:13:54 +0200 | neuroevolutus | (~neuroevol@37.19.200.161) |
2024-08-30 22:14:12 +0200 | regev | (~dararam@147.236.228.71) (Read error: Connection reset by peer) |
2024-08-30 22:15:16 +0200 | tromp | (~textual@92-110-219-57.cable.dynamic.v4.ziggo.nl) (Quit: My iMac has gone to sleep. ZZZzzz…) |
2024-08-30 22:15:49 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 248 seconds) |
2024-08-30 22:16:01 +0200 | <[exa]> | ( anyway yeah it's probably same-ish, I thought that it would create a loooooong thunk line out of the `rep`s pointing to each other but that one can be consumed iteratively just as well, the main difference is likely that it might hold the spine of the (,,)'s in memory ) |
2024-08-30 22:16:32 +0200 | tomsmeding | gave up thinking about this |
2024-08-30 22:17:28 +0200 | szkl | (uid110435@id-110435.uxbridge.irccloud.com) (Quit: Connection closed for inactivity) |
2024-08-30 22:18:47 +0200 | regev | (~dararam@147.236.228.71) |
2024-08-30 22:28:08 +0200 | regev | (~dararam@147.236.228.71) (Ping timeout: 265 seconds) |
2024-08-30 22:30:06 +0200 | regev | (~dararam@147.236.228.71) |
2024-08-30 22:30:42 +0200 | takuan | (~takuan@178-116-218-225.access.telenet.be) (Ping timeout: 252 seconds) |
2024-08-30 22:35:46 +0200 | <dmj`> | [exa]: simulator? |
2024-08-30 22:37:37 +0200 | lxsameer | (~lxsameer@Serene/lxsameer) |
2024-08-30 22:37:58 +0200 | peterbecich | (~Thunderbi@syn-047-229-123-186.res.spectrum.com) |
2024-08-30 22:43:10 +0200 | regev | (~dararam@147.236.228.71) (Ping timeout: 252 seconds) |
2024-08-30 22:45:27 +0200 | regev | (~dararam@147.236.228.71) |
2024-08-30 22:51:14 +0200 | peterbecich | (~Thunderbi@syn-047-229-123-186.res.spectrum.com) (Ping timeout: 252 seconds) |
2024-08-30 22:52:21 +0200 | athan | (~athan@syn-098-153-145-140.biz.spectrum.com) (Quit: Konversation terminated!) |
2024-08-30 22:55:22 +0200 | regev | (~dararam@147.236.228.71) (Read error: Connection reset by peer) |
2024-08-30 22:56:44 +0200 | KicksonButt_ | (~AdminUser@187.21.174.221) (Ping timeout: 252 seconds) |
2024-08-30 22:57:37 +0200 | L29Ah | (~L29Ah@wikipedia/L29Ah) |
2024-08-30 22:57:51 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) |
2024-08-30 23:00:47 +0200 | regev | (~dararam@147.236.228.71) |
2024-08-30 23:01:52 +0200 | kimiamania2 | (~65804703@user/kimiamania) (Quit: PegeLinux) |
2024-08-30 23:02:00 +0200 | merijn | (~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 246 seconds) |
2024-08-30 23:02:14 +0200 | kimiamania2 | (~65804703@user/kimiamania) |
2024-08-30 23:03:19 +0200 | CrunchyFlakes | (~CrunchyFl@ip-109-42-115-64.web.vodafone.de) (Read error: Connection reset by peer) |
2024-08-30 23:06:46 +0200 | regev | (~dararam@147.236.228.71) (Read error: Connection reset by peer) |
2024-08-30 23:10:14 +0200 | athan | (~athan@syn-098-153-145-140.biz.spectrum.com) |
2024-08-30 23:10:55 +0200 | AlexZenon | (~alzenon@178.34.150.250) (Ping timeout: 264 seconds) |
2024-08-30 23:12:04 +0200 | regev | (~dararam@147.236.228.71) |
2024-08-30 23:15:19 +0200 | regev | (~dararam@147.236.228.71) (Read error: Connection reset by peer) |
2024-08-30 23:20:14 +0200 | michalz | (~michalz@185.246.207.197) (Remote host closed the connection) |
2024-08-30 23:21:39 +0200 | regev | (~dararam@147.236.228.71) |
2024-08-30 23:21:49 +0200 | troojg | (~troojg@user/troojg) (Ping timeout: 260 seconds) |
2024-08-30 23:22:34 +0200 | AlexZenon | (~alzenon@178.34.150.250) |
2024-08-30 23:28:59 +0200 | regev | (~dararam@147.236.228.71) (Ping timeout: 252 seconds) |
2024-08-30 23:34:12 +0200 | oo_miguel | (~Thunderbi@78.10.207.45) (Ping timeout: 246 seconds) |
2024-08-30 23:34:21 +0200 | peterbecich | (~Thunderbi@syn-047-229-123-186.res.spectrum.com) |
2024-08-30 23:36:19 +0200 | AlexZenon | (~alzenon@178.34.150.250) (Ping timeout: 252 seconds) |
2024-08-30 23:36:41 +0200 | regev | (~dararam@147.236.228.71) |
2024-08-30 23:40:00 +0200 | lxsameer | (~lxsameer@Serene/lxsameer) (Ping timeout: 252 seconds) |
2024-08-30 23:40:31 +0200 | AlexZenon | (~alzenon@178.34.150.250) |
2024-08-30 23:52:43 +0200 | neuroevolutus | (~neuroevol@37.19.200.161) (Ping timeout: 256 seconds) |