On Mon, Oct 6, 2008 at 10:27 PM, Jason Dagit [EMAIL PROTECTED] wrote:
Why is useful to replace forall with /\?
To make it look more like a capital lambda, just like \ is notation
for lambda. It's a lambda abstraction over a type instead of a value;
that's how polymorphism works in GHC's core
Originally I sent this to glasgow-haskell where I was hoping someone by the
name of Simon would comment on the error message. No one commented at all,
so I'm resending to haskell-cafe. Thanks!
I was wondering if someone could help me understand why reordering the
case statements changes the
2008/10/6 Jason Dagit [EMAIL PROTECTED]:
\begin{code}
badOrder :: (Sealed (p x)) - (forall b. (Sealed (q b))) - (Sealed (q x))
badOrder sx sy = case sy of
Sealed y - case sx of
Sealed x - Sealed (f x y)
\end{code}
\begin{code}
goodOrder ::
On Mon, Oct 6, 2008 at 1:56 PM, Ryan Ingram [EMAIL PROTECTED] wrote:
2008/10/6 Jason Dagit [EMAIL PROTECTED]:
\begin{code}
badOrder :: (Sealed (p x)) - (forall b. (Sealed (q b))) - (Sealed (q
x))
badOrder sx sy = case sy of
Sealed y - case sx of
On Mon, Oct 6, 2008 at 2:27 PM, Jason Dagit [EMAIL PROTECTED] wrote:
For what it's worth, in my real program where this came up, sy was created
by a recursive call like this:
I guess it should have been more like this:
blah :: Sealed (p x)
foo :: Sealed (q b)
foo = do
p - blah
q - foo