Home liberachat/#haskell: Logs Calendar

Logs: liberachat/#haskell

←Prev  Next→ 1,804,395 events total
2021-08-23 20:25:45 <maerwald> fresheyeball: package foo\n\tghc-options: -optPFOO
2021-08-23 20:25:48 <maerwald> or sth?
2021-08-23 20:25:53 <maerwald> you also need `packages: ./`
2021-08-23 20:26:44 chisui joins (~chisui@200116b868b05800c65627e740591fd3.dip.versatel-1u1.de)
2021-08-23 20:26:45 <fresheyeball> ok so now cabal is not building it
2021-08-23 20:26:53 <fresheyeball> now cabal is not seeing that I set this in the cabal file
2021-08-23 20:26:57 <fresheyeball> it was before cabal.project
2021-08-23 20:27:00 <fresheyeball> I am confused
2021-08-23 20:27:04 <maerwald> too vague, links
2021-08-23 20:29:14 <geekosaur> -optP-DFOO perhaps? although I thinkk ghc itself accepts -DFOO
2021-08-23 20:29:59 <maerwald> yeah
2021-08-23 20:30:16 <maerwald> https://downloads.haskell.org/~ghc/latest/docs/html/users_guide/phases.html#ghc-flag--D%E2%9F%A8symbol%E2%9F%A9[=%E2%9F%A8value%E2%9F%A9]
2021-08-23 20:31:32 <fresheyeball> ok so sorta a red hering
2021-08-23 20:31:44 <fresheyeball> the cabal.project file actually has no effect on hls
2021-08-23 20:31:57 <fresheyeball> I figured out what was wrong with cabal, I just didn't import something
2021-08-23 20:32:16 <fresheyeball> but still hls is not picking up that I have cpp-options set in the cabal file
2021-08-23 20:32:43 <fresheyeball> http://ix.io/3wLR
2021-08-23 20:32:46 <fresheyeball> here is the cabal file
2021-08-23 20:33:39 <fresheyeball> here is the hie.yml http://ix.io/3wLT
2021-08-23 20:33:49 eggplantade joins (~Eggplanta@2600:1700:bef1:5e10:71e9:72b:1860:cb0f)
2021-08-23 20:34:03 <fresheyeball> cabal.project http://ix.io/3wLS
2021-08-23 20:35:25 wroathe joins (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
2021-08-23 20:35:25 × wroathe quits (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Changing host)
2021-08-23 20:35:25 wroathe joins (~wroathe@user/wroathe)
2021-08-23 20:37:17 abrantesasf joins (~abrantesa@2804:14d:b086:4b3c:2e56:dcff:fedb:62f)
2021-08-23 20:40:10 × wroathe quits (~wroathe@user/wroathe) (Ping timeout: 240 seconds)
2021-08-23 20:40:58 × immae quits (~immae@2a01:4f8:141:53e7::) (Ping timeout: 240 seconds)
2021-08-23 20:40:58 × JeHugawa quits (~jehugawa@2a01:4f9:c010:4649::1) (Ping timeout: 240 seconds)
2021-08-23 20:42:11 JeHugawa joins (~jehugawa@2a01:4f9:c010:4649::1)
2021-08-23 20:42:23 immae joins (~immae@2a01:4f8:141:53e7::)
2021-08-23 20:44:36 <maerwald> try to set it in cabal.project
2021-08-23 20:46:33 <fresheyeball> maerwald: how?
2021-08-23 20:46:40 <fresheyeball> https://cabal.readthedocs.io/en/latest/cabal-projectindex.html#cap-cabal.project%20fields
2021-08-23 20:46:45 <fresheyeball> I don't see it as an option
2021-08-23 20:47:04 <maerwald> fresheyeball: we described it earlier
2021-08-23 20:47:28 <maerwald> https://cabal.readthedocs.io/en/3.4/cabal-project.html?highlight=ghc-options#package-configuration-options
2021-08-23 20:47:46 hseg joins (~gesh@IGLD-84-228-238-79.inter.net.il)
2021-08-23 20:49:23 <hseg> hi. have a type (of multisets) that can be given a Num instance, except that (*) requirs some constraints on tyvars. which forces me to constrain the entire instance. which locks me out of using linear operations on the type at types failing the constraint. advice?
2021-08-23 20:49:57 <hseg> (in particular, need (*) :: Monoid a => MSet a -> MSet a -> MSet a, but would like (+) :: MSet a -> MSet a -> MSet a)
2021-08-23 20:50:20 <glguy> You can use a different class/operator for the unconstrained + operation
2021-08-23 20:50:46 <fresheyeball> yay!
2021-08-23 20:50:48 <fresheyeball> that worked
2021-08-23 20:51:17 <hseg> yeah, but that's ugly and duplicates names
2021-08-23 20:51:29 <fresheyeball> http://ix.io/3wLY
2021-08-23 20:51:31 <fresheyeball> this did the trick
2021-08-23 20:51:36 <fresheyeball> now hls is working for test suites
2021-08-23 20:51:43 <fresheyeball> maerwald:++
2021-08-23 20:52:19 <glguy> hseg: perhaps, but you can't have different constraints for the different methods of Num, so you'll need a solution that isn't Num for that
2021-08-23 20:52:29 <hseg> shame
2021-08-23 20:52:56 <hseg> current solution is to just fmap (fromJust . getFirst) . ... . fmap (First . Just)
2021-08-23 20:53:41 <hseg> which is annoying, and since my underlying implementation uses Data.Map, cannot be turned into coercions
2021-08-23 20:54:38 merijn joins (~merijn@83-160-49-249.ip.xs4all.nl)
2021-08-23 20:56:16 <hseg> not to mention that this doesn't generalize well -- if I need to tag all the parameters to a function, lift a retagging, etc I need a new combinator
2021-08-23 20:56:24 dsrt^ joins (~dsrt@12.16.129.111)
2021-08-23 20:56:38 <hseg> unlike coerce, which I can fit to the usecase with judicious tyapps
2021-08-23 20:58:47 <dminuoso> hseg: By the way, did you make any progress with your tyfam errors last night?
2021-08-23 20:59:56 <hseg> y, reported, mpickering suggested it might be due to ANN interacting with binding groups https://gitlab.haskell.org/ghc/ghc/-/issues/20265
2021-08-23 21:02:17 wroathe joins (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
2021-08-23 21:02:17 × wroathe quits (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Changing host)
2021-08-23 21:02:17 wroathe joins (~wroathe@user/wroathe)
2021-08-23 21:03:10 elf_fortrez joins (~elf_fortr@adsl-72-50-4-39.prtc.net)
2021-08-23 21:03:13 × merijn quits (~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 250 seconds)
2021-08-23 21:03:29 <hseg> hm. could live with the retagging if I could write sth like retag @(MSet :.: MSet) @MSet :: (forall f. Monoid (f l) => MSet (MSet (f k)) -> MSet (f l)) -> MSet (MSet k) -> MSet l
2021-08-23 21:05:05 × d0ku quits (~d0ku@178.43.19.40.ipv4.supernova.orange.pl) (Ping timeout: 248 seconds)
2021-08-23 21:05:27 <hseg> ... iow, want retag @f1 @f2 @f3 ... :: (forall f. Monoid (f r) => f1 (f x1) -> f2 (f x2) -> ... -> fn (f r)) -> f1 x1 -> f2 x2 -> ... fn r
2021-08-23 21:05:41 acidjnk_new joins (~acidjnk@p200300d0c72b9556a59b812708dd2de4.dip0.t-ipconnect.de)
2021-08-23 21:06:08 <hseg> ... which might be doable with a combination of the van laarhoven trick, the printf trick, and a fundep
2021-08-23 21:06:17 <dminuoso> Interesting
2021-08-23 21:06:29 retroid_ joins (~retro@5ec19a54.skybroadband.com)
2021-08-23 21:09:11 × retro_ quits (~retro@5ec19a54.skybroadband.com) (Ping timeout: 258 seconds)
2021-08-23 21:09:54 <hseg> ... actually printf=van laarhoven here
2021-08-23 21:11:14 × Hobbyboy quits (Hobbyboy@hobbyboy.co.uk) (Quit: The BNC has broken!)
2021-08-23 21:11:26 Hobbyboy joins (Hobbyboy@hobbyboy.co.uk)
2021-08-23 21:12:10 × megaTherion quits (~therion@unix.io) (Ping timeout: 240 seconds)
2021-08-23 21:12:34 × farn quits (~farn@2a03:4000:7:3cd:d4ab:85ff:feeb:f505) (Ping timeout: 240 seconds)
2021-08-23 21:12:34 × kawzeg quits (kawzeg@2a01:7e01::f03c:92ff:fee2:ec34) (Ping timeout: 240 seconds)
2021-08-23 21:12:53 × eggplantade quits (~Eggplanta@2600:1700:bef1:5e10:71e9:72b:1860:cb0f) (Remote host closed the connection)
2021-08-23 21:12:58 × jocke-l quits (jocke-l@a.x0.is) (Ping timeout: 240 seconds)
2021-08-23 21:13:45 farn joins (~farn@2a03:4000:7:3cd:d4ab:85ff:feeb:f505)
2021-08-23 21:13:49 kawzeg joins (kawzeg@2a01:7e01::f03c:92ff:fee2:ec34)
2021-08-23 21:15:03 jocke-l joins (jocke-l@a.x0.is)
2021-08-23 21:18:55 batch12 joins (~user@192.152.118.97)
2021-08-23 21:20:17 × __monty__ quits (~toonn@user/toonn) (Quit: leaving)
2021-08-23 21:23:26 eggplantade joins (~Eggplanta@2600:1700:bef1:5e10:71e9:72b:1860:cb0f)
2021-08-23 21:23:42 Guest86 joins (~Guest86@68.233.176.29)
2021-08-23 21:23:58 <Guest86> is this the correct place to get support for haskell vscode extension?
2021-08-23 21:25:04 <batch12> How do I put a constraint on a type-level list?
2021-08-23 21:25:04 <batch12> I have: class Thing a
2021-08-23 21:25:04 <batch12> and a GADT: data Carrier (is :: [i])
2021-08-23 21:25:04 <batch12> I know I can say: data Carrier (is :: [Nat])
2021-08-23 21:25:07 <batch12> But I want to say that any i that is allowed to be in that type-level list, must have a Thing instance.
2021-08-23 21:25:11 <batch12> Something like: data Carrier (is :: [forall i => Thing i])
2021-08-23 21:25:14 <batch12> Any idea about how to do this?
2021-08-23 21:26:19 <dminuoso> batch12: newtype it
2021-08-23 21:26:34 × jtomas_ quits (~jtomas@233.red-83-34-2.dynamicip.rima-tde.net) (Remote host closed the connection)
2021-08-23 21:26:36 <dminuoso> Or use a GADT
2021-08-23 21:27:06 <dminuoso> % data IsShow where Show a => a -> IsShow
2021-08-23 21:27:06 <yahb> dminuoso: ; <interactive>:15:24: error: parse error on input `a'
2021-08-23 21:27:13 <dminuoso> % data IsShow where MkShow :: Show a => a -> IsShow
2021-08-23 21:27:14 <yahb> dminuoso:

All times are in UTC.