projects
/
ghc-hetmet.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
bc28236
)
[project @ 2005-02-09 14:02:31 by simonpj]
author
simonpj
<unknown>
Wed, 9 Feb 2005 14:02:31 +0000
(14:02 +0000)
committer
simonpj
<unknown>
Wed, 9 Feb 2005 14:02:31 +0000
(14:02 +0000)
Add comment
ghc/compiler/typecheck/TcSimplify.lhs
patch
|
blob
|
history
diff --git
a/ghc/compiler/typecheck/TcSimplify.lhs
b/ghc/compiler/typecheck/TcSimplify.lhs
index
cf22d42
..
4c0ca4b
100644
(file)
--- a/
ghc/compiler/typecheck/TcSimplify.lhs
+++ b/
ghc/compiler/typecheck/TcSimplify.lhs
@@
-1844,11
+1844,11
@@
We have to be careful here. If we are *given* d1:Ord a,
and want to deduce (d2:C [a]) where
class Ord a => C a where
and want to deduce (d2:C [a]) where
class Ord a => C a where
- instance Ord a => C [a] where ...
+ instance Ord [a] => C [a] where ...
-Then we'll use the instance decl to deduce C [a] and then add the
+Then we'll use the instance decl to deduce C [a] from Ord [a], and then add the
superclasses of C [a] to avails. But we must not overwrite the binding
superclasses of C [a] to avails. But we must not overwrite the binding
-for d1:Ord a (which is given) with a superclass selection or we'll just
+for Ord [a] (which is obtained from Ord a) with a superclass selection or we'll just
build a loop!
Here's another variant, immortalised in tcrun020
build a loop!
Here's another variant, immortalised in tcrun020