summaryrefslogtreecommitdiff
path: root/compiler
diff options
context:
space:
mode:
authorMatthew Pickering <matthewtpickering@gmail.com>2016-08-03 17:06:42 +0100
committerMatthew Pickering <matthewtpickering@gmail.com>2016-08-03 17:06:42 +0100
commita13fda71b02cdaa840f8040b392777272a0d7794 (patch)
treea5c1ab78246ba85efaacfd8077984986de2da87c /compiler
parent7a8ef01920731f0afa45f3589fcb4a89d5eb125c (diff)
downloadhaskell-a13fda71b02cdaa840f8040b392777272a0d7794.tar.gz
Clarify comment on makeCorePair
Diffstat (limited to 'compiler')
-rw-r--r--compiler/deSugar/DsBinds.hs9
1 files changed, 6 insertions, 3 deletions
diff --git a/compiler/deSugar/DsBinds.hs b/compiler/deSugar/DsBinds.hs
index f5211d209c..8c05f43012 100644
--- a/compiler/deSugar/DsBinds.hs
+++ b/compiler/deSugar/DsBinds.hs
@@ -349,9 +349,12 @@ dsHsBind _ (PatSynBind{}) = panic "dsHsBind: PatSynBind"
-- | This is where we apply INLINE and INLINABLE pragmas. All we need to
--- do is to attach the unfolding information to the Id. When the interface
--- files are created, unfoldings are only attached if the information is
--- present.
+-- do is to attach the unfolding information to the Id.
+--
+-- Other decisions about whether to inline are made in
+-- `calcUnfoldingGuidance` but the decision about whether to then expose
+-- the unfolding in the interface file is made in `TidyPgm.addExternal`
+-- using this information.
------------------------
makeCorePair :: DynFlags -> Id -> Bool -> Arity -> CoreExpr -> (Id, CoreExpr)
makeCorePair dflags gbl_id is_default_method dict_arity rhs