summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthew Pickering <matthewtpickering@gmail.com>2020-11-26 15:24:51 +0000
committerMatthew Pickering <matthewtpickering@gmail.com>2020-12-18 08:14:51 +0000
commitfbc4664841689bb4001dde069079af2198f5204a (patch)
tree123199d536d5cc72435eea7b5f5544b3c46f9949
parentdc22d60ed5b302275c9bd5342c03a4ab2ddab42f (diff)
downloadhaskell-fbc4664841689bb4001dde069079af2198f5204a.tar.gz
Some more comments
-rw-r--r--compiler/GHC/Types/IPE.hs13
1 files changed, 10 insertions, 3 deletions
diff --git a/compiler/GHC/Types/IPE.hs b/compiler/GHC/Types/IPE.hs
index fe43bbfe2b..5d8bf72513 100644
--- a/compiler/GHC/Types/IPE.hs
+++ b/compiler/GHC/Types/IPE.hs
@@ -11,12 +11,19 @@ import GHC.Types.Unique.Map
-- | A map from a 'Name' to the best approximate source position that
-- name arose from.
-type ClosureMap = UniqMap
- Name -- The binding
- (String, RealSrcSpan, String) -- The best approximate source position.
+type ClosureMap = UniqMap Name -- The binding
+ (String, RealSrcSpan, String)
+ -- The best approximate source position.
+ -- (rendered type, source position, source note
+ -- label)
-- | A map storing all the different uses of a specific data constructor and the
-- approximate source position that usage arose from.
+-- The `Int` is an incrementing identifier which distinguishes each usage
+-- of a constructor in a module. It is paired with the source position
+-- the constructor was used at, if possible and a string which names
+-- the source location. This is the same information as is the payload
+-- for the `GHC.Core.SourceNote` constructor.
type DCMap = UniqMap DataCon [(Int, Maybe (RealSrcSpan, String))]
data InfoTableProvMap = InfoTableProvMap