summaryrefslogtreecommitdiff
path: root/compiler/GHC/Core
diff options
context:
space:
mode:
Diffstat (limited to 'compiler/GHC/Core')
-rw-r--r--compiler/GHC/Core/Coercion.hs5
-rw-r--r--compiler/GHC/Core/TyCon.hs4
2 files changed, 5 insertions, 4 deletions
diff --git a/compiler/GHC/Core/Coercion.hs b/compiler/GHC/Core/Coercion.hs
index 235e8c65fb..98aa337026 100644
--- a/compiler/GHC/Core/Coercion.hs
+++ b/compiler/GHC/Core/Coercion.hs
@@ -1708,9 +1708,8 @@ has to do in its full generality. See #18413.
%************************************************************************
-}
--- | If @co :: T ts ~ rep_ty@ then:
---
--- > instNewTyCon_maybe T ts = Just (rep_ty, co)
+-- | If `instNewTyCon_maybe T ts = Just (rep_ty, co)`
+-- then `co :: T ts ~R# rep_ty`
--
-- Checks for a newtype, and for being saturated
instNewTyCon_maybe :: TyCon -> [Type] -> Maybe (Type, Coercion)
diff --git a/compiler/GHC/Core/TyCon.hs b/compiler/GHC/Core/TyCon.hs
index e50751c2a0..6514b68aaf 100644
--- a/compiler/GHC/Core/TyCon.hs
+++ b/compiler/GHC/Core/TyCon.hs
@@ -1184,7 +1184,9 @@ data AlgTyConRhs
-- See Note [Newtype eta]
nt_co :: CoAxiom Unbranched,
-- The axiom coercion that creates the @newtype@
- -- from the representation 'Type'.
+ -- from the representation 'Type'. The axiom witnesses
+ -- a representational coercion:
+ -- nt_co :: N ty1 ~R# rep_tys
-- See Note [Newtype coercions]
-- Invariant: arity = #tvs in nt_etad_rhs;