Commit 3e35714a authored by simonpj@microsoft.com's avatar simonpj@microsoft.com
Browse files

Comments only

parent f6efe0c7
......@@ -477,7 +477,7 @@ data SpecInfo
VarSet -- Locally-defined free vars of *both* LHS and RHS
-- of rules. I don't think it needs to include the
-- ru_fn though.
-- Note [Rule dependency info]
-- Note [Rule dependency info] in OccurAnal
emptySpecInfo :: SpecInfo
emptySpecInfo = SpecInfo [] emptyVarSet
......@@ -500,16 +500,6 @@ setSpecInfoHead fn (SpecInfo rules fvs)
seqSpecInfo (SpecInfo rules fvs) = seqRules rules `seq` seqVarSet fvs
\end{code}
Note [Rule dependency info]
~~~~~~~~~~~~~~~~~~~~~~~~~~~
THe VarSet in a SpecInfo is used for dependency analysis in the
occurrence analyser. We must track free vars in *both* lhs and rhs. Why both?
Consider
x = y
RULE f x = 4
Then if we substitute y for x, we'd better do so in the
rule's LHS too, so we'd better ensure the dependency is respected
%************************************************************************
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment