Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Alex D
GHC
Commits
f1080035
Commit
f1080035
authored
Jun 09, 2015
by
eir@cis.upenn.edu
Browse files
Testsuite wibble around decomposing newtypes.
This is actually an improvement. Yay!
parent
93f97be7
Changes
2
Hide whitespace changes
Inline
Side-by-side
testsuite/tests/typecheck/should_fail/T10285.stderr
View file @
f1080035
T10285.hs:8:17: error:
Could not deduce: a ~ b
Could not deduce: Coercible a b
arising from trying to show that the representations of
‘a’ and
‘b’ are the same
from the context: Coercible (N a) (N b)
bound by a pattern with constructor:
Coercion :: forall (k :: BOX) (a :: k) (b :: k).
...
...
testsuite/tests/typecheck/should_fail/T10534.stderr
View file @
f1080035
T10534a.hs:9:10: error:
Could not deduce: a ~ b
T10534a.hs:10:9: error:
Could not deduce: Coercible a b
arising from trying to show that the representations of
‘a’ and
‘b’ are the same
from the context: Coercible (DF a) (DF b)
bound by the type signature for:
silly :: Coercible (DF a) (DF b) => a -> b
...
...
@@ -11,12 +14,7 @@ T10534a.hs:9:10: error:
‘b’ is a rigid type variable bound by
the type signature for: silly :: Coercible (DF a) (DF b) => a -> b
at T10534a.hs:9:10
arising from trying to show that the representations of
‘DF a’ and
‘DF b’ are the same
Relevant role signatures: type role DF nominal
In the ambiguity check for the type signature for ‘silly’:
silly :: forall a b. Coercible (DF a) (DF b) => a -> b
To defer the ambiguity check to use sites, enable AllowAmbiguousTypes
In the type signature for ‘silly’:
silly :: Coercible (DF a) (DF b) => a -> b
Relevant bindings include
silly :: a -> b (bound at T10534a.hs:10:1)
In the expression: coerce
In an equation for ‘silly’: silly = coerce
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment