[add freevars instance for rules, clean up some code
John Meacham <john@repetae.net>**20051001005825] hunk ./E/LetFloat.hs 149
+--type Binds = [(FVarSet,Either (TVr,E) [(TVr,E)])]
hunk ./E/LetFloat.hs 164
+-- | seperate bindings based on whether they can be floated inward
+
hunk ./E/LetFloat.hs 167
-    [FVarSet]    -- ^ list of possible drop points
-    -> Binds     -- ^ list of bindings and their free variables
+    [FVarSet]           -- ^ list of possible drop points
+    -> Binds            -- ^ list of bindings and their free variables
hunk ./E/LetFloat.hs 172
-    --fs =  ( G.scc $  G.newGraph (concatMap fromScc fs')  (tvrNum . fst . fst) (Set.toList . snd) )
hunk ./E/LetFloat.hs 175
-        --  | nu == 0 = f bs -- not (any (`Set.member` allSet) (fvDecls b)) = f bs
+        | nu == 0 = f bs
hunk ./E/LetFloat.hs 182
-        fb = Set.toList $ fb'
hunk ./E/Rules.hs 102
+
+instance FreeVars Rule b => FreeVars ARules b where
+    freeVars (ARules rs) = freeVars rs
+
+instance FreeVars Rule (Set.Set TVr) where
+    freeVars rule = freeVars (ruleBody rule) Set.\\ freeVars (ruleArgs rule)
+