Home freenode/#haskell: Logs Calendar

Logs: freenode/#haskell

←Prev  Next→
Page 1 .. 26 27 28 29 30 31 32 33 34 35 36 .. 5022
502,152 events total
2020-09-17 16:18:58 <carter> i get add and mult confused
2020-09-17 16:19:04 <carter> sum, pair, & and par
2020-09-17 16:19:23 <carter> i dont really see the metaphor for the additive vs mult binary operators perspective
2020-09-17 16:19:24 <ski> hm. when i read Wadler's paper on session types and linear logic, i was thinking all connectives were the opposite of what i expected
2020-09-17 16:19:47 <carter> and i alwasy forget which things are additives vs mult
2020-09-17 16:19:57 <ski> (iow, replaced by duals, everywhere. or possibly it was just for one of the subsystems described)
2020-09-17 16:20:20 <carter> i dont like a lott of / most expositions i've seen
2020-09-17 16:20:45 <dolio> ski: Might depend on how they were being used, I guess.
2020-09-17 16:20:45 <ski> consider `a * (b + c) = (a * b) + (a * c)'
2020-09-17 16:20:53 <ski> `*' is multiplicative, `+' is additive
2020-09-17 16:20:55 <dolio> Inputs vs outputs.
2020-09-17 16:20:57 <ski> that's how i remember it
2020-09-17 16:21:45 <ski> dolio : yes, presumably, but it still seemed simpler to me, to just flip all the connectives, then. not upset people's expectations, for what seemed to be no reason
2020-09-17 16:23:10 <ski> carter : fwiw, i don't like the usual notation for (some of) the connectives ..
2020-09-17 16:23:16 bicho_rastrero joins (~cerdito@154.85-87-39.dynamic.clientes.euskaltel.es)
2020-09-17 16:23:24 <dolio> Which one? :)
2020-09-17 16:23:24 <ski> .. so, in personal notes, i'm using my own convention :)
2020-09-17 16:23:31 <ski> yea, there's several
2020-09-17 16:23:39 <ski> i had Girard's one in mind
2020-09-17 16:23:58 <dolio> I think both are wrong categorically.
2020-09-17 16:24:27 <ski> (i reconstructed it from memory, after getting exposed to the ideas. then, after a bit, i noticed my reconstructed version was not the same as in the papers i read)
2020-09-17 16:24:42 <carter> dolio: which are wrong how?
2020-09-17 16:25:04 <dolio> carter: Additives are (co)product, but I think neither notation uses * for additve conjunction.
2020-09-17 16:26:08 <dolio> That would suggest + for additive disjunction, too, but maybe Girard doesn't do that, either.
2020-09-17 16:26:17 <dolio> It's a circled +?
2020-09-17 16:26:41 <dolio> I've heard Girard's notation is supposed to remind you of distributive laws.
2020-09-17 16:26:48 nan` joins (~nan`@unaffiliated/nan/x-5405850)
2020-09-17 16:27:18 <carter> lol
2020-09-17 16:27:46 <dolio> But I'm not sure that's worth it.
2020-09-17 16:29:26 × p-core quits (~Thunderbi@koleje-wifi-0046.koleje.cuni.cz) (Quit: p-core)
2020-09-17 16:29:28 × jedws quits (~jedws@101.184.189.58) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2020-09-17 16:29:45 <ezzieyguywuf> so pretty much always just use ghcup rather thn whatever my OS's package manager has, right?
2020-09-17 16:29:45 p-core joins (~Thunderbi@koleje-wifi-0046.koleje.cuni.cz)
2020-09-17 16:29:57 Gurkenglas joins (~Gurkengla@unaffiliated/gurkenglas)
2020-09-17 16:30:10 carlomagno joins (~cararell@inet-hqmc02-o.oracle.com)
2020-09-17 16:30:34 <maerwald> ezzieyguywuf: if your OS PM gets it right... then that's also nice
2020-09-17 16:30:47 <ski> clearly ⌜+⌝ ought to be coproduct ("either","internal choice"), ⌜×⌝ be product ("with","external choice"), ⌜0⌝ be initial object ("void"), ⌜1⌝ be terminal object ("erase"), i thought. that leaves ⌜⊕⌝ for multiplicative disjunction ("par"), ⌜⊗⌝ for multiplicative conjunction, and then i took ⌜⊥⌝ ("bot") and ⌜⊤⌝ ("top","unit") as the respective neutral elements for those
2020-09-17 16:30:47 <dumptruckman> So... If I wanted to model a game state a Monad would be sensible for this, right?
2020-09-17 16:31:00 <maerwald> ezzieyguywuf: but ghcup is faster with adding new versions, most likely
2020-09-17 16:31:17 <dolio> Oh yeah, the units are all mixed up, too.
2020-09-17 16:31:28 <ezzieyguywuf> maerwald: they did the ghc nicely, they just pulled the binary from upstream, but the cabal install is a mess - I end up having to jump through all these hoops to get the cabal dependencies installed in the PM
2020-09-17 16:31:56 <ezzieyguywuf> I was planning to just install ghc and cabal from the OS, then cabal install to grab things I need for dev and install the locally
2020-09-17 16:32:57 hackage uniqueness-periods-vector-filters 0.1.1.0 - A library allows to change the structure of the 'RealFrac' function output. https://hackage.haskell.org/package/uniqueness-periods-vector-filters-0.1.1.0 (OleksandrZhabenko)
2020-09-17 16:33:17 <ski> yes, Girard uses : ⌜⊕⌝,⌜&⌝,⌜0⌝,⌜⊤⌝ for the additives, and ⌜⅋⌝,⌜⊗⌝,⌜⊥⌝,⌜1⌝ for the multiplicatives
2020-09-17 16:34:01 × p-core quits (~Thunderbi@koleje-wifi-0046.koleje.cuni.cz) (Remote host closed the connection)
2020-09-17 16:34:25 × coot quits (~coot@37.30.52.181.nat.umts.dynamic.t-mobile.pl) (Quit: coot)
2020-09-17 16:34:27 <ski> dumptruckman : monads can be nice for keeping track of state, yes
2020-09-17 16:35:40 <ski> (oh, forgot to say that mult. conj. is "(both) .. and .."/"tensor")
2020-09-17 16:38:16 coot joins (~coot@37.30.52.181.nat.umts.dynamic.t-mobile.pl)
2020-09-17 16:38:20 × fendor quits (~fendor@t204-126.demo.tuwien.ac.at) (Remote host closed the connection)
2020-09-17 16:41:30 <Uniaika> phadej: do you think if SqlQQ can be safely extracted from postgresql-simple? I'd like to use it for sqlite too but I'm not familiar with postgresql-simple's internals
2020-09-17 16:43:08 <ezzieyguywuf> k so really...no definitive answer on OS vs ghcup
2020-09-17 16:43:09 <ski> dumptruckman : some alternative might perhaps be to try to keep local state, maybe via some kind of stream processors or something (FRP ?)
2020-09-17 16:43:14 LKoen joins (~LKoen@81.255.219.130)
2020-09-17 16:43:17 <dumptruckman> mmk
2020-09-17 16:43:37 <ezzieyguywuf> any gentoo users in here?
2020-09-17 16:43:44 <dumptruckman> How would I lift the list out of this to be able to use intersect on an instance of Shares? `data Shares = Shares [Sharable]`
2020-09-17 16:43:46 <maerwald> ezzieyguywuf: why
2020-09-17 16:44:00 <maerwald> also: gentoo is not the distro that does get GHC right
2020-09-17 16:44:12 <ski> dumptruckman : pattern-matching
2020-09-17 16:44:19 <dumptruckman> what would that look like
2020-09-17 16:44:28 hackage pusher-http-haskell 2.0.0.1 - Haskell client library for the Pusher Channels HTTP API https://hackage.haskell.org/package/pusher-http-haskell-2.0.0.1 (willsewell)
2020-09-17 16:44:35 <dumptruckman> do i need to define `intersect :: Shares -> Shares -> Shares`?
2020-09-17 16:44:38 <ski> intersectShares :: Shares -> Shares -> Shares
2020-09-17 16:44:39 <dumptruckman> ok
2020-09-17 16:44:46 <monochrom> "OS vs ghcup" depends on the OS. However, for 90% of OSes, go with ghcup.
2020-09-17 16:44:52 <dumptruckman> oh, i have to name it differently?
2020-09-17 16:45:03 <ski> instersectShares (Shares ss0) (Shares ss1) = Shares (intersect ss0 ss1)
2020-09-17 16:45:15 <ski> depends on whether you import `intersect' qualified
2020-09-17 16:45:37 <dumptruckman> hmm ok
2020-09-17 16:45:59 geekosaur joins (42d52102@66.213.33.2)
2020-09-17 16:46:47 <dumptruckman> is it silly to use the & operator for this?
2020-09-17 16:46:53 <dumptruckman> is that even possible?
2020-09-17 16:46:58 <monochrom> You can.
2020-09-17 16:47:00 <ezzieyguywuf> maerwald: there's been changes in gentoo rather recently, the haskell situation is lots better
2020-09-17 16:47:20 <ezzieyguywuf> but I still think I'm going to stick to ghcup - I don't want to have, like, mtl and stuff installed at the system level
2020-09-17 16:47:30 × coot quits (~coot@37.30.52.181.nat.umts.dynamic.t-mobile.pl) (Quit: coot)
2020-09-17 16:47:50 <maerwald> ezzieyguywuf: I'd be surprised, because the gentoo PM cannot handle installing the same package mulitple times
2020-09-17 16:48:01 <maerwald> which you need for haskell packages
2020-09-17 16:48:51 <maerwald> The proper way to packages haskell is: only package GHC and cabal and *nothing* else (no haskell packages)
2020-09-17 16:49:17 <ski> (dumptruckman : btw, in Haskell terminology, you wouldn't talk about "an instance of Shares", but rather about values of (type) `Shares')
2020-09-17 16:49:20 <maerwald> everything else ends up showing limitations of the package manager with the only exception being nix
2020-09-17 16:49:32 <maerwald> but then... you know... you'd have to use nix, ugh
2020-09-17 16:50:18 <ezzieyguywuf> maerwald: it can, it's called "slots"
2020-09-17 16:50:49 <ezzieyguywuf> maerwald: that's what I wanted to do, but in the current setup, I have separate packages for cabal's dependencies, i.e. mtl, fail, etc.
2020-09-17 16:51:04 <maerwald> ezzieyguywuf: no, I'm talking about the same version
2020-09-17 16:51:09 <maerwald> slots don't do that
2020-09-17 16:51:18 <ezzieyguywuf> also, on a different note - I accidentally ran `ghcup` in `/root` as `myUser`, and it gave me a permission error when it tried to do `cabal new-update`
2020-09-17 16:51:21 <phadej> Uniaika: https://hackage.haskell.org/package/postgresql-simple-0.6.2/docs/src/Database.PostgreSQL.Simple.SqlQQ.html#sql just copy it
2020-09-17 16:51:27 <phadej> it doesn't really do anything smart
2020-09-17 16:51:29 <dumptruckman> ski: thanks, i wasn't sure about that
2020-09-17 16:51:31 <ezzieyguywuf> shouldn't it always dereference my ~ variable, no matter what the current directory is?
2020-09-17 16:51:53 <phadej> (cliking source on hackage docs pages is the trick, often enough ;)
2020-09-17 16:51:54 <ezzieyguywuf> maerwald: so there's a need for the same version of the same package to be installed multiple times?
2020-09-17 16:52:06 <maerwald> ezzieyguywuf: You cannot install filepath-1.2.0.0 for multiple GHC slots on gentoo
2020-09-17 16:52:21 <maerwald> that's a fact, slots don't solve this
2020-09-17 16:52:22 <maerwald> nix does
2020-09-17 16:52:38 <ski> dumptruckman : it's fine, got what you meant. just pointing it out, for more efficient future communication
2020-09-17 16:53:02 <ezzieyguywuf> neat! is ghcup tui using the boxes thing?
2020-09-17 16:53:08 <ezzieyguywuf> urm, bricks
←Prev  Next→
Page 1 .. 26 27 28 29 30 31 32 33 34 35 36 .. 5022

All times are in UTC.