Home freenode/#haskell: Logs Calendar

Logs: freenode/#haskell

←Prev  Next→
Page 1 .. 954 955 956 957 958 959 960 961 962 963 964 .. 5022
502,152 events total
2020-10-30 10:44:21 <dminuoso> Where caseS is a "sort-of" constrained version of bind
2020-10-30 10:45:02 <dminuoso> But such a thing would require some first-class way of specifying generic pattern matching
2020-10-30 10:45:42 <dminuoso> typetetris: you can just use servant or scotty?
2020-10-30 10:46:11 <[exa]> hm, lenses? `caseS :: [ (Prism ... , sel) ] -> sel -> sel`
2020-10-30 10:46:54 <typetetris> dminuoso: now you mention it, there is a link creating function in servant?
2020-10-30 10:47:23 <dminuoso> typetetris: Mmm, perhaps you could concoct such a thing yourself?
2020-10-30 10:47:41 <dminuoso> Add some type combinator to tag endpoints
2020-10-30 10:47:43 <[exa]> typetetris: I used scotty and just made a small function that gave the correct link to given routes
2020-10-30 10:48:02 <dminuoso> Such that you can say `Tag "foo" :> "foo" :> Get '[] NoContent`
2020-10-30 10:48:13 <[exa]> typetetris: if I got it correctly you basically want to make sure that rendered html anchors match what's in routing?
2020-10-30 10:48:18 gehmehgeh joins (~ircuser1@gateway/tor-sasl/gehmehgeh)
2020-10-30 10:48:42 <[exa]> dminuoso: anyway thanks for explanation :]
2020-10-30 10:48:54 <dminuoso> And then pull out the route through some `getUrl :: (KnownSymbol k, MonadFail m) => Proxy k -> m Url`
2020-10-30 10:49:02 <dminuoso> With some magic machinery that needs to be written
2020-10-30 10:49:17 <typetetris> [exa]: yes
2020-10-30 10:49:20 _noblegas joins (uid91066@gateway/web/irccloud.com/x-sqjfvivbwmtlawjw)
2020-10-30 10:49:26 <dminuoso> That would be some real type tetris right there.
2020-10-30 10:49:37 <merijn> dminuoso: Please make optparse-selective so I won't have to ;)
2020-10-30 10:49:47 <typetetris> dminuoso: I knew, I need to change my nickname some time ... :(
2020-10-30 10:49:57 ensyde joins (~ensyde@99-185-235-117.lightspeed.chrlnc.sbcglobal.net)
2020-10-30 10:50:04 <dminuoso> typetetris: I think it should be quite possible, in fact.
2020-10-30 10:50:11 <dminuoso> ANd useful
2020-10-30 10:50:20 <typetetris> dminuoso: I think it is already there :)
2020-10-30 10:50:47 × dexterfoo quits (dexter@2a01:7e00::f03c:91ff:fe86:59ec) (Ping timeout: 272 seconds)
2020-10-30 10:50:53 flx_ joins (flux@coffee.modeemi.fi)
2020-10-30 10:50:59 × cocreature quits (~cocreatur@eirene.uberspace.de) (Read error: Connection reset by peer)
2020-10-30 10:51:03 × Geekingfrog quits (geekingfro@2a01:7e01::f03c:92ff:fe48:8bdf) (Remote host closed the connection)
2020-10-30 10:51:14 Geekingfrog joins (~geekingfr@li2156-64.members.linode.com)
2020-10-30 10:51:15 cocreature joins (~cocreatur@eirene.uberspace.de)
2020-10-30 10:51:35 <[exa]> merijn: hopefully that could finally allow the global options leaking to subparsers :]
2020-10-30 10:51:46 <dminuoso> typetetris: https://hackage.haskell.org/package/servant-0.16.2/docs/Servant-Links.html
2020-10-30 10:51:50 <merijn> [exa]: That's already fixed, I think?
2020-10-30 10:51:56 <[exa]> merijn: O_O
2020-10-30 10:52:04 dexterfoo joins (dexter@2a01:7e00::f03c:91ff:fe86:59ec)
2020-10-30 10:52:06 <dminuoso> typetetris: Would that work for you?
2020-10-30 10:52:11 [exa] opens docs
2020-10-30 10:52:31 <merijn> [exa]: https://github.com/pcapriotti/optparse-applicative/issues/294
2020-10-30 10:52:41 × Jon quits (jon@dow.land) (Ping timeout: 272 seconds)
2020-10-30 10:52:48 × GyroW quits (~GyroW@unaffiliated/gyrow) (Quit: Someone ate my pie)
2020-10-30 10:52:52 <typetetris> dminuoso: I will take a look at it.
2020-10-30 10:53:05 GyroW joins (~GyroW@ptr-48ujrfd1ztq5fjywfw3.18120a2.ip6.access.telenet.be)
2020-10-30 10:53:05 × GyroW quits (~GyroW@ptr-48ujrfd1ztq5fjywfw3.18120a2.ip6.access.telenet.be) (Changing host)
2020-10-30 10:53:05 GyroW joins (~GyroW@unaffiliated/gyrow)
2020-10-30 10:53:11 <[exa]> merijn: w o n d e r f u l
2020-10-30 10:53:23 <dminuoso> Personally, I'd try very hard to avoid yesod. I'd take any pain to get links with servant instead :p
2020-10-30 10:53:25 <merijn> [exa]: It's even on hackage already :)
2020-10-30 10:53:52 Jon joins (~jon@redmars.org)
2020-10-30 10:54:23 <typetetris> What is that selective thing you are talking about?
2020-10-30 10:54:24 × ensyde quits (~ensyde@99-185-235-117.lightspeed.chrlnc.sbcglobal.net) (Ping timeout: 240 seconds)
2020-10-30 10:54:40 hackage mu-schema 0.3.1.1 - Format-independent schemas for serialization https://hackage.haskell.org/package/mu-schema-0.3.1.1 (AlejandroSerrano)
2020-10-30 10:55:13 × m0rphism quits (~m0rphism@HSI-KBW-046-005-177-122.hsi8.kabel-badenwuerttemberg.de) (Quit: WeeChat 2.7.1)
2020-10-30 10:55:13 × mflux quits (flux@coffee.modeemi.fi) (Ping timeout: 272 seconds)
2020-10-30 10:55:21 flx_ is now known as mflux
2020-10-30 10:55:57 <[exa]> merijn: are there any code changes required? (I'm on optparse 0.16)
2020-10-30 10:56:01 <merijn> typetetris: Selective functors
2020-10-30 10:56:16 <merijn> [exa]: The changelog has some stuff on how to enable it
2020-10-30 10:56:24 <dminuoso> Ah what I wouldnt give for "disabling the type system" for just a moment, so I could build [1,[2,3,4],5,6,[7,8]] and flatten it...
2020-10-30 10:56:26 <[exa]> great, thanks
2020-10-30 10:56:26 <merijn> or disable? I don't remember
2020-10-30 10:56:30 <dminuoso> Is there any cool tricks to build lists like that?
2020-10-30 10:57:04 <merijn> typetetris: https://hackage.haskell.org/package/selective
2020-10-30 10:57:17 <merijn> typetetris: See the paper linked in the docs for an explanation of the niche it fills
2020-10-30 10:57:46 × andreas303 quits (~andreas@gateway/tor-sasl/andreas303) (Remote host closed the connection)
2020-10-30 10:59:11 p-core joins (~Thunderbi@2001:718:1e03:5128:2ab7:7f35:48a1:8515)
2020-10-30 11:00:11 <[exa]> back to selectives...this sounds like a great way to describe DFAs (and regexes)
2020-10-30 11:00:15 × lyxia quits (~lyxia@poisson.chat) (Ping timeout: 256 seconds)
2020-10-30 11:00:55 andreas303 joins (~andreas@gateway/tor-sasl/andreas303)
2020-10-30 11:03:24 [exa] takes a huge melting pot and combines alternative+selective
2020-10-30 11:04:59 whatisRT joins (~whatisRT@2002:5b41:6a33:0:cdb:717d:49e3:4e14)
2020-10-30 11:06:04 × carlomagno quits (~cararell@148.87.23.9) (Ping timeout: 240 seconds)
2020-10-30 11:09:35 <[exa]> merijn: anyway it's off by default, enabled by `prefs $ subparserInline <> helpShowGlobals`, thanks a lot!
2020-10-30 11:09:49 × jonathanx quits (~jonathan@dyn-8-sc.cdg.chalmers.se) (Remote host closed the connection)
2020-10-30 11:10:41 × cfricke quits (~cfricke@unaffiliated/cfricke) (Quit: WeeChat 2.9)
2020-10-30 11:11:49 <Uniaika> dminuoso: not that I know of :/
2020-10-30 11:12:03 <Uniaika> except maybe building your own AST of values and operating on it
2020-10-30 11:15:11 hackage mu-protobuf 0.4.0.1 - Protocol Buffers serialization and gRPC schema import for Mu microservices https://hackage.haskell.org/package/mu-protobuf-0.4.0.1 (AlejandroSerrano)
2020-10-30 11:15:45 <dminuoso> Well, Im just using a slightly modifivation of Writer
2020-10-30 11:16:01 cfricke joins (~cfricke@unaffiliated/cfricke)
2020-10-30 11:16:08 <dminuoso> newtype ListW e a = ListW { unListW (Writer [e] a) }
2020-10-30 11:16:22 <dminuoso> with some putE :: e -> ListW e (); putEs :: [e] -> ListW e ();
2020-10-30 11:16:36 × Stanley00_ quits (~stanley00@unaffiliated/stanley00) ()
2020-10-30 11:17:04 <dminuoso> So I can do `execList $ do { putE a; putEs bs; putE c; putE; d; putEs es }`
2020-10-30 11:17:37 __monty__ joins (~toonn@unaffiliated/toonn)
2020-10-30 11:18:48 × chaosmasttter quits (~chaosmast@p200300c4a70a4101f96c699b406ffa93.dip0.t-ipconnect.de) (Ping timeout: 268 seconds)
2020-10-30 11:19:13 <Uniaika> that's uh… that's a way to do it indeed :D
2020-10-30 11:21:35 <dminuoso> an alternative is just `[a] <> bs <> [c] <> [d] <> es` and align it nicely vertically
2020-10-30 11:21:43 <dminuoso> Perhaps Ill just do that and not care
2020-10-30 11:22:39 hackage megaparsec 9.0.1 - Monadic parser combinators https://hackage.haskell.org/package/megaparsec-9.0.1 (mrkkrp)
2020-10-30 11:22:50 carlomagno joins (~cararell@148.87.23.4)
2020-10-30 11:23:39 hackage megaparsec-tests 9.0.1 - Test utilities and the test suite of Megaparsec https://hackage.haskell.org/package/megaparsec-tests-9.0.1 (mrkkrp)
2020-10-30 11:26:06 × pta2002 quits (~quassel@104.248.23.110) (Remote host closed the connection)
2020-10-30 11:27:48 × rprije quits (~rprije@194-193-168-77.tpgi.com.au) (Ping timeout: 256 seconds)
2020-10-30 11:28:50 × alp_ quits (~alp@2a01:e0a:58b:4920:4824:2411:72d0:af73) (Ping timeout: 264 seconds)
2020-10-30 11:29:47 invaser joins (~Thunderbi@31.148.23.125)
2020-10-30 11:30:37 × olligobber quits (olligobber@gateway/vpn/privateinternetaccess/olligobber) (Remote host closed the connection)
2020-10-30 11:31:46 × bliminse quits (~bliminse@host109-158-129-241.range109-158.btcentralplus.com) (Ping timeout: 256 seconds)
2020-10-30 11:32:41 rprije joins (~rprije@194-193-168-77.tpgi.com.au)
2020-10-30 11:32:44 bliminse joins (~bliminse@host109-158-129-241.range109-158.btcentralplus.com)
2020-10-30 11:34:50 × Jonkimi727406120 quits (~Jonkimi@119.123.241.90) (Ping timeout: 264 seconds)
2020-10-30 11:36:40 duairc joins (~shane@ana.rch.ist)

All times are in UTC.