From 80f8e0bb99ba34110b8e6c887975ba284ec88ddb Mon Sep 17 00:00:00 2001 From: Nikolay Yakimov Date: Thu, 10 Dec 2015 00:40:37 +0300 Subject: [PATCH] [Optparse] Browse, lint interactive commands --- src/GHCMod.hs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/GHCMod.hs b/src/GHCMod.hs index cf6f1ad..519b2ad 100644 --- a/src/GHCMod.hs +++ b/src/GHCMod.hs @@ -153,7 +153,8 @@ legacyInteractiveLoop symdbreq world = do res <- flip gcatches interactiveHandlers $ case dropWhileEnd isSpace cmd of "check" -> checkSyntax [arg] - "find" -> do + "lint" -> lint defaultLintOpts arg + "find" -> do db <- getDb symdbreq >>= checkDb symdbreq lookupSymbol arg db @@ -166,6 +167,7 @@ legacyInteractiveLoop symdbreq world = do "refine" -> locArgs' refine args "boot" -> boot + "browse" -> concat <$> browse defaultBrowseOpts `mapM` args "map-file" -> liftIO getFileSourceFromStdin >>= loadMappedFileSource arg