Standalone Deriving, GND and roles in 7.8.1-rc2

Hello! Trying to build random packages with fresh ghc-7.8.1-rc2 I've come up with a strange bit: https://github.com/trofi/Idris-dev/commit/9f93122ba1aa075c2fa1555fea68a6c403... Is it an intended behaviour that deriving instance Parsing IdrisInnerParser capable of doing more, than newtype IdrisInnerParser a = IdrisInnerParser { runInnerParser :: Parser a } deriving (Parsing) ? Thanks! -- Sergei

I think those should be the same and that you've discovered a bug. What's the definition of the Parsing class? Thanks! Richard On Mar 5, 2014, at 3:28 PM, Sergei Trofimovich wrote:
Hello!
Trying to build random packages with fresh ghc-7.8.1-rc2 I've come up with a strange bit:
https://github.com/trofi/Idris-dev/commit/9f93122ba1aa075c2fa1555fea68a6c403...
Is it an intended behaviour that deriving instance Parsing IdrisInnerParser capable of doing more, than newtype IdrisInnerParser a = IdrisInnerParser { runInnerParser :: Parser a } deriving (Parsing) ?
Thanks!
--
Sergei _______________________________________________ ghc-devs mailing list ghc-devs@haskell.org http://www.haskell.org/mailman/listinfo/ghc-devs

On Wed, 5 Mar 2014 15:40:27 -0500
Richard Eisenberg
I think those should be the same and that you've discovered a bug. What's the definition of the Parsing class?
Here it goes [1]: class Alternative m => Parsing m where .... notFollowedBy :: (Monad m, Show a) => m a -> m () notFollowedBy p = try ((try p >>= unexpected . show) <|> pure ()) {-# INLINE notFollowedBy #-} [1]: https://github.com/ekmett/parsers/blob/master/src/Text/Parser/Combinators.hs... -- Sergei

As usual I'm the source of more headaches for Richard. ;)
-Edward
On Wed, Mar 5, 2014 at 3:57 PM, Sergei Trofimovich
On Wed, 5 Mar 2014 15:40:27 -0500 Richard Eisenberg
wrote: I think those should be the same and that you've discovered a bug. What's the definition of the Parsing class?
Here it goes [1]:
class Alternative m => Parsing m where .... notFollowedBy :: (Monad m, Show a) => m a -> m () notFollowedBy p = try ((try p >>= unexpected . show) <|> pure ()) {-# INLINE notFollowedBy #-}
[1]: https://github.com/ekmett/parsers/blob/master/src/Text/Parser/Combinators.hs...
--
Sergei
_______________________________________________ ghc-devs mailing list ghc-devs@haskell.org http://www.haskell.org/mailman/listinfo/ghc-devs

This has now been entered as bug #8851. Track progress there if you're interested.
Thanks for bringing this up!
Richard
On Mar 5, 2014, at 4:34 PM, Edward Kmett
As usual I'm the source of more headaches for Richard. ;)
-Edward
On Wed, Mar 5, 2014 at 3:57 PM, Sergei Trofimovich
wrote: On Wed, 5 Mar 2014 15:40:27 -0500 Richard Eisenberg wrote: I think those should be the same and that you've discovered a bug. What's the definition of the Parsing class?
Here it goes [1]:
class Alternative m => Parsing m where .... notFollowedBy :: (Monad m, Show a) => m a -> m () notFollowedBy p = try ((try p >>= unexpected . show) <|> pure ()) {-# INLINE notFollowedBy #-}
[1]: https://github.com/ekmett/parsers/blob/master/src/Text/Parser/Combinators.hs...
--
Sergei
_______________________________________________ ghc-devs mailing list ghc-devs@haskell.org http://www.haskell.org/mailman/listinfo/ghc-devs
participants (3)
-
Edward Kmett
-
Richard Eisenberg
-
Sergei Trofimovich