Re: [Haskell-cafe] Suppressing HLint on pattern match of files

2013-10-11 Thread Dag Odenhall
Just add it next to -Wall wherever you‘re setting that, because I think you must be setting that yourself somewhere (it’s not on by default). On Thu, Oct 10, 2013 at 6:11 PM, Graham Berks gra...@fatlazycat.com wrote: Ah good point :) Wonder if I can change it on cabal file somehow. Thanks

[Haskell-cafe] MonadBaseControl IO instance for conduits ?

2013-10-11 Thread Aleksey Uymanov
Hello Haskellers! Is it posible to create instance of MonadBaseControl IO (ConduitM i o m) ? This would give a great posibility to catch exceptions just inside the ConduitM monad with lifted-base package. And more, http-conduit's `withManager` restricts base monad (which must be base for

Re: [Haskell-cafe] Suppressing HLint on pattern match of files

2013-10-11 Thread Adam Bergmark
You can also do this on a module basis with {-# OPTIONS -fno-warn-missing-signatures #-}. I prefer adding type signatures even for cases where I don't think it's important. GHC spits them out so almost no time spent, and someone might find it useful at some point. On Fri, Oct 11, 2013 at 5:53

Re: [Haskell-cafe] Store type-class polymorphic values generically

2013-10-11 Thread Christopher Done
Wait... what do you mean Core cannot generate new names to be exported. I meant if I add a new name in the Core transformation, that doesn't change the module's export list as seen by everything outside that module. Which makes sense, it just means I have to change my approach. Maybe you mean

[Haskell-cafe] Compiling arbitrary Haskell code

2013-10-11 Thread Christopher Done
Is there a definitive list of things in GHC that are unsafe to _compile_ if I were to take an arbitrary module and compile it? E.g. off the top of my head, things that might be dangerous: * TemplateHaskell/QuasiQuotes -- obviously * Are rules safe? * #includes — I presume there's some security

Re: [Haskell-cafe] Compiling arbitrary Haskell code

2013-10-11 Thread Jason Dagit
On Fri, Oct 11, 2013 at 1:30 PM, Christopher Done chrisd...@gmail.comwrote: Is there a definitive list of things in GHC that are unsafe to _compile_ if I were to take an arbitrary module and compile it? E.g. off the top of my head, things that might be dangerous: *

Re: [Haskell-cafe] Compiling arbitrary Haskell code

2013-10-11 Thread Aleksey Khudyakov
On 12.10.2013 00:30, Christopher Done wrote: Is there a definitive list of things in GHC that are unsafe to _compile_ if I were to take an arbitrary module and compile it? E.g. off the top of my head, things that might be dangerous: * TemplateHaskell/QuasiQuotes -- obviously * Are rules safe?

Re: [Haskell-cafe] Compiling arbitrary Haskell code

2013-10-11 Thread Johan Tibell
Whatever guarantees GHC offers (e.g. using Safe Haskell), I would always run things like these in a sandbox. It's much better for security to dissallow everything and then whitelist some things (e.g. let the sandbox communicate with the rest of the world in some limited way) than the other way

Re: [Haskell-cafe] Compiling arbitrary Haskell code

2013-10-11 Thread Christopher Done
On 12 October 2013 01:19, Johan Tibell johan.tib...@gmail.com wrote: Whatever guarantees GHC offers (e.g. using Safe Haskell), I would always run things like these in a sandbox. It's much better for security to dissallow everything and then whitelist some things (e.g. let the sandbox

Re: [Haskell-cafe] MonadBaseControl IO instance for conduits ?

2013-10-11 Thread John Wiegley
Aleksey Uymanov s9gf4...@gmail.com writes: Is it posible to create instance of MonadBaseControl IO (ConduitM i o m) ? No, it is not, for approximately the same reason that you cannot create one for ContT (or any form of continuation). -- John Wiegley FP Complete