Re: [Haskell-cafe] Missing Functor instances in GHC 7?

2010-12-10 Thread Simon Peyton-Jones
| Interestingly, if I import only Control.Applicative from within GHCi, it | does not find the instances defined in Control.Monad.Instances although | this module is imported in Control.Applicative. On the other hand, if I | write a file containing the line 'import Control.Applicative' and load |

Re: [Haskell-cafe] Missing Functor instances in GHC 7?

2010-12-10 Thread Erik Hesselink
On Fri, Dec 10, 2010 at 09:33, Simon Peyton-Jones simo...@microsoft.com wrote: | Interestingly, if I import only Control.Applicative from within GHCi, it | does not find the instances defined in Control.Monad.Instances although | this module is imported in Control.Applicative. On the other

Re: [Haskell-cafe] Missing Functor instances in GHC 7?

2010-12-10 Thread Sebastian Fischer
On Fri, 2010-12-10 at 08:33 +, Simon Peyton-Jones wrote: If there's a consensus that the behaviour is wrong, or at least unexpected, would you like to make a reproducible test case and file a ticket? I took Erik's mail as indicator that the behaviour of GHCi is inconsistent and

[Haskell-cafe] Missing Functor instances in GHC 7?

2010-12-09 Thread Sebastian Fischer
Hello, according to http://www.haskell.org/ghc/docs/latest/html/libraries/base/Control-Monad.html Control.Monad exports 20 Functor instance declarations in base-4.3.0.0. However: bash# ghc-pkg list | grep base base-4.3.0.0 bash# ghci --version The Glorious Glasgow Haskell

Re: [Haskell-cafe] Missing Functor instances in GHC 7?

2010-12-09 Thread Antoine Latter
Hi Sebastian, I imagine that many of the instances are defined in the module that defines the data type. For example, the STM instance is defined in the same module as the STM type. Are there any particular ones you're running into problems with? Take care, Antoine On Thu, Dec 9, 2010 at 11:10

Re: [Haskell-cafe] Missing Functor instances in GHC 7?

2010-12-09 Thread Sebastian Fischer
Hi Antoine, On Thu, 2010-12-09 at 23:20 -0600, Antoine Latter wrote: Are there any particular ones you're running into problems with? Yes, I cannot find the instance for ((-) r). Even if I import Control.Monad Control.Monad.Reader Control.Applicative Data.Functor

Re: [Haskell-cafe] Missing Functor instances in GHC 7?

2010-12-09 Thread Sebastian Fischer
On Fri, 2010-12-10 at 14:35 +0900, Sebastian Fischer wrote: Yes, I cannot find the Functor instance for ((-) r). As the Applicative instance for ((-) r) depends on the Functor instance I only needed to go through the imports of Control.Applicative to find that the Functor instance of ((-) r) is