summaryrefslogtreecommitdiff
path: root/testsuite/tests/rep-poly/RepPolyArgument.stderr
diff options
context:
space:
mode:
authorSimon Peyton Jones <simon.peytonjones@gmail.com>2023-03-06 10:50:47 +0000
committerSimon Peyton Jones <simon.peytonjones@gmail.com>2023-03-21 14:48:54 +0000
commitf0decae7121524790d5c907274bafac966839487 (patch)
tree96c712975be0ed889c0f3475c556981332da464a /testsuite/tests/rep-poly/RepPolyArgument.stderr
parent73d07c6e1986bd2b3516d4f009cc1e30ba804f06 (diff)
downloadhaskell-wip/T23051.tar.gz
Be more careful about quantificationwip/T23051
This MR is driven by #23051. It does several things: * It is guided by the generalisation plan described in #20686. But it is still far from a complete implementation of that plan. * Add Note [Inferred type with escaping kind] to GHC.Tc.Gen.Bind. This explains that we don't (yet, pending #20686) directly prevent generalising over escaping kinds. * In `GHC.Tc.Utils.TcMType.defaultTyVar` we default RuntimeRep and Multiplicity variables, beause we don't want to quantify over them. We want to do the same for a Concrete tyvar, but there is nothing sensible to default it to (unless it has kind RuntimeRep, in which case it'll be caught by an earlier case). So we promote instead. * Pure refactoring in GHC.Tc.Solver: * Rename decideMonoTyVars to decidePromotedTyVars, since that's what it does. * Move the actual promotion of the tyvars-to-promote from `defaultTyVarsAndSimplify` to `decidePromotedTyVars`. This is a no-op; just tidies up the code. E.g then we don't need to return the promoted tyvars from `decidePromotedTyVars`. * A little refactoring in `defaultTyVarsAndSimplify`, but no change in behaviour. * When making a TauTv unification variable into a ConcreteTv (in GHC.Tc.Utils.Concrete.makeTypeConcrete), preserve the occ-name of the type variable. This just improves error messages. * Kill off dead code: GHC.Tc.Utils.TcMType.newConcreteHole
Diffstat (limited to 'testsuite/tests/rep-poly/RepPolyArgument.stderr')
-rw-r--r--testsuite/tests/rep-poly/RepPolyArgument.stderr4
1 files changed, 2 insertions, 2 deletions
diff --git a/testsuite/tests/rep-poly/RepPolyArgument.stderr b/testsuite/tests/rep-poly/RepPolyArgument.stderr
index c6aaded15b..45c9474839 100644
--- a/testsuite/tests/rep-poly/RepPolyArgument.stderr
+++ b/testsuite/tests/rep-poly/RepPolyArgument.stderr
@@ -3,8 +3,8 @@ RepPolyArgument.hs:10:18: error: [GHC-55287]
• The argument ‘(undefined @(R @RuntimeRep))’ of ‘undefined’
does not have a fixed runtime representation.
Its type is:
- t0 :: TYPE c0
- Cannot unify ‘R’ with the type variable ‘c0’
+ t1 :: TYPE t0
+ Cannot unify ‘R’ with the type variable ‘t0’
because it is not a concrete ‘RuntimeRep’.
• In the first argument of ‘undefined’, namely
‘(undefined @(R @RuntimeRep))’