git.iko.soy/rowtype-yoga/purescript-native
on golang help sign in
Fix tab completion in psci for explictly exported modules
commit23098233e249c41bf3b6ddd963a4f97a9a4a5e99 authorPhil Freeman <paf31@cantab.net> dateThu 3 Apr 2014, 15:47 (13 years ago) parent9358e4e
1 file changed+4−3
psci/Main.hs+4−3
psci/Main.hs+4−3
@@ -176,9 +176,10 @@ completion = completeWord Nothing " \t\n\r" findCompletions
176176 getDeclName Nothing (P.ValueDeclaration ident _ _ _ _) = Just ident
177177 getDeclName (Just exts) (P.ValueDeclaration ident _ _ _ _) | isExported = Just ident
178178 where
179− isExported = flip any exts $ \e -> case e of
180− P.ValueRef ident' -> ident == ident'
181− _ -> False
179+ isExported = any exports exts
180+ exports (P.ValueRef ident') = ident == ident'
181+ exports (P.PositionedDeclarationRef _ r) = exports r
182+ exports _ = False
182183 getDeclName exts (P.PositionedDeclaration _ d) = getDeclName exts d
183184 getDeclName _ _ = Nothing
184185 names :: [P.Module] -> [String]