diff options
Diffstat (limited to 'docs/users_guide')
| -rw-r--r-- | docs/users_guide/glasgow_exts.rst | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/docs/users_guide/glasgow_exts.rst b/docs/users_guide/glasgow_exts.rst index 781a10691e..c86f30d00b 100644 --- a/docs/users_guide/glasgow_exts.rst +++ b/docs/users_guide/glasgow_exts.rst @@ -9395,7 +9395,8 @@ Here is an example of a constrained kind: :: The declarations above are accepted. However, if we add ``MkOther :: T Int``, we get an error that the equality constraint is not satisfied; ``Int`` is not a type literal. Note that explicitly quantifying with ``forall a`` is -not necessary here. +necessary in order for ``T`` to typecheck +(see :ref:`complete-kind-signatures`). The kind ``Type`` ----------------- @@ -10351,13 +10352,13 @@ function that can *never* be called, such as this one: :: f :: (Int ~ Bool) => a -> a Sometimes :extension:`AllowAmbiguousTypes` does not mix well with :extension:`RankNTypes`. -For example: :: +For example: :: foo :: forall r. (forall i. (KnownNat i) => r) -> r foo f = f @1 boo :: forall j. (KnownNat j) => Int boo = .... - + h :: Int h = foo boo @@ -10367,7 +10368,7 @@ the type variables `j` and `i`. Unlike the previous examples, it is not currently possible to resolve the ambiguity manually by using :extension:`TypeApplications`. - + .. note:: *A historical note.* GHC used to impose some more restrictive and less principled conditions on type signatures. For type |
