jle` 2017-02-20 13:46:37
the Typeable class (which is a superclass of Exception) has some useful methods that let us write this open-sum-kinda type of behavior
MarcelineVQ 2017-02-20 13:56:40
this is quite confusing, the documentation claims "The difference between using try and catch for recovery is that in catch the handler is inside an implicit mask" but try uses catch, and I can't find evidence of masking involved in catch itself in the first place. the function in the mask related section are quite explicit about how they tinker with the masking state by using primitives with the word mask in them which aren't
MarcelineVQ 2017-02-20 13:56:41
present in catch :O
MarcelineVQ 2017-02-20 13:57:10
But let's assume for the sake of having a focus that the implicit masking is in the catch# primitive, why does try lose this property when it's using catch?
MarcelineVQ 2017-02-20 13:59:06
shoulda linked: http://hackage.haskell.org/package/base-4.9.1.0/docs/Control-Exception.html#g:3
lyxia 2017-02-20 14:03:45
Hmmm
lyxia 2017-02-20 14:04:06
I think the difference they want to point out is that try returns the error to be handled
MarcelineVQ 2017-02-20 14:04:10
maybe they mean something as simple as the fact that try doesn't have a handler that can be interacted with
lyxia 2017-02-20 14:04:15
right
MarcelineVQ 2017-02-20 14:05:19
What you've just said makes sense to me, thank you
Cale 2017-02-20 14:06:43
MarcelineVQ: Right, when you use try, you're going to have the *actual* handler out in some case expression afterward.
jle` 2017-02-20 14:06:56
edwardk: is there any way to abuse the Reverse type from 'ad' to do reverse-mode autodifferentiation with calculations involving multiple types? was going to write my own custom one
unknownln 2017-02-20 14:08:40
Hey all, interesting problem: I'm writing something which needs to read data from a source and serve it over http to a client. However, I want it to read the data as fast as it can from the source (essentially loading the whole thing into memory), regardless of the speed the client reads. I also don't want to block until the entire input has been read into memory before I start to serve the client data. Any way to do this?
unknownln 2017-02-20 14:08:41
Input data is coming from a Handle, output is a lazy bytestring sent with Spock/Wai
MarcelineVQ 2017-02-20 14:08:51
lyxia, Cale: thank you, now I'm going to troll around in ghc source for whether the implicit masking they mention is part of catch# or some effect of how they classify interruptible things
Wizek 2017-02-20 14:41:16
Hi. Anyone knows if there is a lens combinator that allows to set with a monadic function? e.g. something like this: https://gist.github.com/Wizek/9dc20498f7539a5b3850e9ce8829be5b
Wizek 2017-02-20 14:42:06
I'm thinking that the function I am looking for could have the type: `MonadState s m => ASetter s s a b -> (a -> m b) -> m ()`