on master help sign in
No need to check whether something referencing a repl name is repl-defined
commitfaf1d3976a1010618e4b026b98fa9c2994bbcfe2 authorAlyssa Carter <trillionalyssa@gmail.com> dateThu 31 Jul 2014, 18:52 (12 years ago) parentad184a9
1 file changed+1−2
src/Idris/REPL.hs+1−2
src/Idris/REPL.hs+1−2
@@ -755,10 +755,9 @@ process h fn (Undefine names) = undefine names
755755 undefClosure n =
756756 do replDefs <- idris_repl_defs `fmap` get
757757 callGraph <- whoCalls n
758− let users' = case lookup n callGraph of
758+ let users = case lookup n callGraph of
759759 Just ns -> ns
760760 Nothing -> fail ("Tried to undefine nonexistent name" ++ show n)
761− users = filter (`elem` replDefs) users'
762761 undefinedJustNow <- concat `fmap` mapM undefClosure users
763762 undefOne n
764763 return (n : undefinedJustNow)