Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Fumiaki Kinoshita
GHC
Commits
424cd45b
Commit
424cd45b
authored
Nov 02, 2001
by
simonpj
Browse files
[project @ 2001-11-02 09:54:42 by simonpj]
Test for record update failure
parent
16564aa3
Changes
3
Hide whitespace changes
Inline
Side-by-side
testsuite/tests/ghc-regress/typecheck/should_fail/all.T
View file @
424cd45b
...
...
@@ -100,3 +100,4 @@ test "tcfail099" { vtcf("") }
test "tcfail100" { vtcf("") }
test "tcfail101" { vtcf("") }
test "tcfail102" { vtcf("") }
testsuite/tests/ghc-regress/typecheck/should_fail/tcfail102.hs
0 → 100644
View file @
424cd45b
module
ShouldFail
where
import
Ratio
data
Integral
a
=>
P
a
=
P
{
p
::
a
}
f
::
Integral
a
=>
P
(
Ratio
a
)
->
P
(
Ratio
a
)
f
x
=
x
{
p
=
p
x
}
testsuite/tests/ghc-regress/typecheck/should_fail/tcfail102.stderr
0 → 100644
View file @
424cd45b
tcfail102.hs:8:
Could not deduce (Integral (Ratio a)) from the context (Integral a)
Probable fix:
Add (Integral (Ratio a)) to the type signature(s) for f
Or add an instance declaration for (Integral (Ratio a))
arising from a record update at tcfail102.hs:8
In the record update: x {p = p x}
In the definition of `f': x {p = p x}
Write
Preview
Supports
Markdown
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