[Haskell-cafe] Re: [Haskell] question about a failure to
generalize
Neil Mitchell
ndmitchell at gmail.com
Sat Sep 15 22:08:52 EDT 2007
Hi
> Monomorphism restriction? Replacing fold with foldRegsUsed would work
> because there's a type signature for foldRegsUsed.
That looks like it. Another solution would be:
> fold = foldRegsUsed
becomes:
> fold x = foldRegsUsed x
Now the monomorphism restriction doesn't kick in because fold has an
explicit argument.
Thanks
Neil
More information about the Haskell-Cafe
mailing list