Re: Template Haskell

2012-07-19 Thread Mikhail Vorozhtsov
Hi Simon. On Wed, Jul 18, 2012 at 7:25 PM, Simon Peyton-Jones wrote: > Mikhail has improved Template Haskell’s handling of INLINE pragmas, > SPECIALISE pragmas, and RULES. I plan to commit his patch BTW, is there a reason why you use commit messages to attribute other people's work instead of `g

Re: API function to check whether one type fits "in" another

2012-07-19 Thread Philip Holzenspies
Dear Simon, et al, I finally got back around to working on this idea. I'm not yet quite sure whether I've now understood it all. I have reread the latest edition of "System F with Type Equality Coercions" (Jan 2011 version), so I understand that inference is now just percolating coercions upwar

Re: Why GHC doesn't warn about LHS nullary-constructor pattern bindings?

2012-07-19 Thread Christian Maeder
You're right. That's a good case for a feature request. In fact any binding that binds no variables should be warned about: let Just _ = ... Cheers Christian Am 19.07.2012 12:50, schrieb Herbert Valerio Riedel: Hello, Recently, I was a bit suprised that GHC didn't warn about useless `where

Re: Why GHC doesn't warn about LHS nullary-constructor pattern bindings?

2012-07-19 Thread Christopher Done
In your case the Nothing is unused so will never be a problem. Perhaps more worrying: foo :: Int -> Int foo n = x + 1 where Just x = Nothing This gives no warnings. ___ Glasgow-haskell-users mailing list Glasgow-haskell-users@haskell.org htt

Re: Why GHC doesn't warn about LHS nullary-constructor pattern bindings?

2012-07-19 Thread Henning Thielemann
On Thu, 19 Jul 2012, Herbert Valerio Riedel wrote: Recently, I was a bit suprised that GHC didn't warn about useless `where` definitions such as the following when using `-Wall` (and I couldn't find a respective warning GHC CLI flag which would have enabled reporting a warning in this case -- u

Why GHC doesn't warn about LHS nullary-constructor pattern bindings?

2012-07-19 Thread Herbert Valerio Riedel
Hello, Recently, I was a bit suprised that GHC didn't warn about useless `where` definitions such as the following when using `-Wall` (and I couldn't find a respective warning GHC CLI flag which would have enabled reporting a warning in this case -- unless I missed it) module Foo where foo

Re: Call to arms: lambda-case is stuck and needs your help (fwd)

2012-07-19 Thread Henning Thielemann
I want to vote, too. I am ok with all of case of \case \of \case of For me single arguments are enough. We already have this restriction for 'case' and I can work around it simply by wrapping arguments in pairs temporarily (cf. curry $ \case ...). I vote against LambdaIf, since