on master help sign in
Merge pull request #3352 from jfdm/structural-changes

Some internal structural Changes.

commit50ad8a7f6203da943090caee74d828ea707183fb authorNiklas Larsson <metaniklas@gmail.com> dateThu 11 Aug 2016, 21:26 (10 years ago) parent44539ec7973024
10 files changed+249−228
idris.cabal+1 main/Main.hs−1 src/Idris/AbsSyntax.hs+125 src/Idris/AbsSyntaxTree.hs+12−82 src/Idris/CmdOptions.hs+11−4 src/Idris/Coverage.hs+2−2 src/Idris/Package/Common.hs+3−4 src/Idris/REPL.hs+17−134 src/Idris/REPL/Commands.hs+76 src/Idris/REPL/Parser.hs+2−1
idris.cabal+1
@@ -206,6 +206,7 @@ Library
206206 , Idris.Reflection
207207 , Idris.REPL
208208 , Idris.REPL.Parser
209+ , Idris.REPL.Commands
209210 , Idris.Transforms
210211 , Idris.TypeSearch
211212 , Idris.Unlit
main/Main.hs−1
@@ -6,7 +6,6 @@ import Control.Monad ( when )
66
77import Idris.AbsSyntax
88import Idris.REPL
9−-- import Idris.Imports
109import Idris.Error
1110import Idris.CmdOptions
1211import Idris.Info
src/Idris/AbsSyntax.hs+125
@@ -47,6 +47,8 @@ import Debug.Trace
4747
4848import System.IO.Error(isUserError, ioeGetErrorString, tryIOError)
4949
50+import Network (PortID(PortNumber))
51+
5052import Util.Pretty
5153import Util.ScreenSize
5254import Util.System
@@ -2496,3 +2498,126 @@ mkUniqueNames env shadows tm
24962498 mkUniq ql nmap (PUnquote tm) = fmap PUnquote (mkUniq (ql - 1) nmap tm)
24972499
24982500 mkUniq ql nmap tm = descendM (mkUniq ql nmap) tm
2501+
2502+
2503+getFile :: Opt -> Maybe String
2504+getFile (Filename str) = Just str
2505+getFile _ = Nothing
2506+
2507+getBC :: Opt -> Maybe String
2508+getBC (BCAsm str) = Just str
2509+getBC _ = Nothing
2510+
2511+getOutput :: Opt -> Maybe String
2512+getOutput (Output str) = Just str
2513+getOutput _ = Nothing
2514+
2515+getIBCSubDir :: Opt -> Maybe String
2516+getIBCSubDir (IBCSubDir str) = Just str
2517+getIBCSubDir _ = Nothing
2518+
2519+getImportDir :: Opt -> Maybe String
2520+getImportDir (ImportDir str) = Just str
2521+getImportDir _ = Nothing
2522+
2523+getPkgDir :: Opt -> Maybe String
2524+getPkgDir (Pkg str) = Just str
2525+getPkgDir _ = Nothing
2526+
2527+getPkg :: Opt -> Maybe (Bool, String)
2528+getPkg (PkgBuild str) = Just (False, str)
2529+getPkg (PkgInstall str) = Just (True, str)
2530+getPkg _ = Nothing
2531+
2532+getPkgClean :: Opt -> Maybe String
2533+getPkgClean (PkgClean str) = Just str
2534+getPkgClean _ = Nothing
2535+
2536+getPkgREPL :: Opt -> Maybe String
2537+getPkgREPL (PkgREPL str) = Just str
2538+getPkgREPL _ = Nothing
2539+
2540+getPkgCheck :: Opt -> Maybe String
2541+getPkgCheck (PkgCheck str) = Just str
2542+getPkgCheck _ = Nothing
2543+
2544+-- | Returns None if given an Opt which is not PkgMkDoc
2545+-- Otherwise returns Just x, where x is the contents of PkgMkDoc
2546+getPkgMkDoc :: Opt -- ^ Opt to extract
2547+ -> Maybe String -- ^ Result
2548+getPkgMkDoc (PkgMkDoc str) = Just str
2549+getPkgMkDoc _ = Nothing
2550+
2551+getPkgTest :: Opt -- ^ the option to extract
2552+ -> Maybe String -- ^ the package file to test
2553+getPkgTest (PkgTest f) = Just f
2554+getPkgTest _ = Nothing
2555+
2556+getCodegen :: Opt -> Maybe Codegen
2557+getCodegen (UseCodegen x) = Just x
2558+getCodegen _ = Nothing
2559+
2560+getCodegenArgs :: Opt -> Maybe String
2561+getCodegenArgs (CodegenArgs args) = Just args
2562+getCodegenArgs _ = Nothing
2563+
2564+getConsoleWidth :: Opt -> Maybe ConsoleWidth
2565+getConsoleWidth (UseConsoleWidth x) = Just x
2566+getConsoleWidth _ = Nothing
2567+
2568+
2569+getExecScript :: Opt -> Maybe String
2570+getExecScript (InterpretScript expr) = Just expr
2571+getExecScript _ = Nothing
2572+
2573+getPkgIndex :: Opt -> Maybe FilePath
2574+getPkgIndex (PkgIndex file) = Just file
2575+getPkgIndex _ = Nothing
2576+
2577+getEvalExpr :: Opt -> Maybe String
2578+getEvalExpr (EvalExpr expr) = Just expr
2579+getEvalExpr _ = Nothing
2580+
2581+getOutputTy :: Opt -> Maybe OutputType
2582+getOutputTy (OutputTy t) = Just t
2583+getOutputTy _ = Nothing
2584+
2585+getLanguageExt :: Opt -> Maybe LanguageExt
2586+getLanguageExt (Extension e) = Just e
2587+getLanguageExt _ = Nothing
2588+
2589+getTriple :: Opt -> Maybe String
2590+getTriple (TargetTriple x) = Just x
2591+getTriple _ = Nothing
2592+
2593+getCPU :: Opt -> Maybe String
2594+getCPU (TargetCPU x) = Just x
2595+getCPU _ = Nothing
2596+
2597+getOptLevel :: Opt -> Maybe Int
2598+getOptLevel (OptLevel x) = Just x
2599+getOptLevel _ = Nothing
2600+
2601+getOptimisation :: Opt -> Maybe (Bool,Optimisation)
2602+getOptimisation (AddOpt p) = Just (True, p)
2603+getOptimisation (RemoveOpt p) = Just (False, p)
2604+getOptimisation _ = Nothing
2605+
2606+getColour :: Opt -> Maybe Bool
2607+getColour (ColourREPL b) = Just b
2608+getColour _ = Nothing
2609+
2610+getClient :: Opt -> Maybe String
2611+getClient (Client x) = Just x
2612+getClient _ = Nothing
2613+
2614+-- Get the first valid port
2615+getPort :: [Opt] -> Maybe PortID
2616+getPort [] = Nothing
2617+getPort (Port p:xs)
2618+ | all (`elem` ['0'..'9']) p = Just (PortNumber $ fromIntegral (read p))
2619+ | otherwise = getPort xs
2620+getPort (_:xs) = getPort xs
2621+
2622+opt :: (Opt -> Maybe a) -> [Opt] -> [a]
2623+opt = mapMaybe
src/Idris/AbsSyntaxTree.hs+12−82
@@ -433,77 +433,6 @@ data IRFormat = IBCFormat | JSONFormat deriving (Show, Eq, Generic)
433433
434434data HowMuchDocs = FullDocs | OverviewDocs
435435
436−-- | REPL commands
437−data Command = Quit
438− | Help
439− | Eval PTerm
440− | NewDefn [PDecl] -- ^ Each 'PDecl' should be either a type declaration (at most one) or a clause defining the same name.
441− | Undefine [Name]
442− | Check PTerm
443− | Core PTerm
444− | DocStr (Either Name Const) HowMuchDocs
445− | TotCheck Name
446− | Reload
447− | Watch
448− | Load FilePath (Maybe Int) -- up to maximum line number
449− | ChangeDirectory FilePath
450− | ModImport String
451− | Edit
452− | Compile Codegen String
453− | Execute PTerm
454− | ExecVal PTerm
455− | Metavars
456− | Prove Bool Name -- ^ If false, use prover, if true, use elab shell
457− | AddProof (Maybe Name)
458− | RmProof Name
459− | ShowProof Name
460− | Proofs
461− | Universes
462− | LogLvl Int
463− | LogCategory [LogCat]
464− | Spec PTerm
465− | WHNF PTerm
466− | TestInline PTerm
467− | Defn Name
468− | Missing Name
469− | DynamicLink FilePath
470− | ListDynamic
471− | Pattelab PTerm
472− | Search [String] PTerm
473− | CaseSplitAt Bool Int Name
474− | AddClauseFrom Bool Int Name
475− | AddProofClauseFrom Bool Int Name
476− | AddMissing Bool Int Name
477− | MakeWith Bool Int Name
478− | MakeCase Bool Int Name
479− | MakeLemma Bool Int Name
480− | DoProofSearch Bool -- update file
481− Bool -- recursive search
482− Int -- depth
483− Name -- top level name
484− [Name] -- hints
485− | SetOpt Opt
486− | UnsetOpt Opt
487− | NOP
488− | SetColour ColourType IdrisColour
489− | ColourOn
490− | ColourOff
491− | ListErrorHandlers
492− | SetConsoleWidth ConsoleWidth
493− | SetPrinterDepth (Maybe Int)
494− | Apropos [String] String
495− | WhoCalls Name
496− | CallsWho Name
497− | Browse [String]
498− | MakeDoc String -- IdrisDoc
499− | Warranty
500− | PrintDef Name
501− | PPrint OutputFmt Int PTerm
502− | TransformInfo Name
503− -- Debugging commands
504− | DebugInfo Name
505− | DebugUnify PTerm PTerm
506−
507436data OutputFmt = HTMLOutput | LaTeXOutput
508437
509438-- | Recognised logging categories for the Idris compiler.
@@ -544,6 +473,18 @@ loggingCatsStr = unlines
544473 , (strLogCat IIBC)
545474 ]
546475
476+
477+data ElabShellCmd = EQED
478+ | EAbandon
479+ | EUndo
480+ | EProofState
481+ | EProofTerm
482+ | EEval PTerm
483+ | ECheck PTerm
484+ | ESearch PTerm
485+ | EDocStr (Either Name Const)
486+ deriving (Show, Eq)
487+
547488data Opt = Filename String
548489 | Quiet
549490 | NoBanner
@@ -613,17 +554,6 @@ data Opt = Filename String
613554 | NoOldTacticDeprecationWarnings -- ^ Don't show deprecation warnings for old-style tactics
614555 deriving (Show, Eq, Generic)
615556
616−data ElabShellCmd = EQED
617− | EAbandon
618− | EUndo
619− | EProofState
620− | EProofTerm
621− | EEval PTerm
622− | ECheck PTerm
623− | ESearch PTerm
624− | EDocStr (Either Name Const)
625− deriving (Show, Eq)
626−
627557-- Parsed declarations
628558
629559data Fixity = Infixl { prec :: Int }
src/Idris/CmdOptions.hs+11−4
@@ -1,15 +1,22 @@
11{-|
22Module : Idris.CmdOptions
3−Description : CLI for the Idris executable.
4−Copyright :
3+Description : A parser for the CmdOptions for the Idris executable.
54License : BSD3
65Maintainer : The Idris Community.
76-}
87{-# LANGUAGE Arrows #-}
9−module Idris.CmdOptions where
8+module Idris.CmdOptions
9+ (
10+ module Idris.CmdOptions
11+ , opt
12+ , getClient, getPkg, getPkgCheck, getPkgClean, getPkgMkDoc
13+ , getPkgREPL, getPkgTest, getPort, getIBCSubDir
14+ ) where
1015
1116import Idris.AbsSyntaxTree
12−import Idris.REPL
17+import Idris.AbsSyntax (opt, getClient, getPkg, getPkgCheck, getPkgClean, getPkgMkDoc
18+ , getPkgREPL, getPkgTest, getPort, getIBCSubDir)
19+-- import Idris.REPL
1320import Idris.Info (getIdrisVersion)
1421
1522import IRTS.CodegenCommon
src/Idris/Coverage.hs+2−2
@@ -489,7 +489,7 @@ verifyTotality (fc, n)
489489
490490 case getPartial ist [] ns of
491491 Nothing -> return ()
492− Just bad -> do let t' = Partial (Other bad)
492+ Just bad -> do let t' = Partial (Other bad)
493493 logCoverage 2 $ "Set to " ++ show t'
494494 setTotality n t'
495495 addIBC (IBCTotal n t')
@@ -503,7 +503,7 @@ verifyTotality (fc, n)
503503
504504 getPartial ist [] [] = Nothing
505505 getPartial ist bad [] = Just bad
506− getPartial ist bad (n : ns)
506+ getPartial ist bad (n : ns)
507507 = case lookupTotalExact n (tt_ctxt ist) of
508508 Just (Partial _) -> getPartial ist (n : bad) ns
509509 _ -> getPartial ist bad ns
src/Idris/Package/Common.hs+3−4
@@ -1,15 +1,14 @@
11{-|
22Module : Idris.Package.Common
33Description : Data structures common to all `iPKG` file formats.
4−Copyright :
54License : BSD3
65Maintainer : The Idris Community.
76-}
87module Idris.Package.Common where
98
10−import Idris.Core.TT
11−import Idris.REPL
12−import Idris.AbsSyntaxTree
9+import Idris.Core.TT (Name)
10+
11+import Idris.AbsSyntaxTree (Opt(..))
1312
1413-- | Description of an Idris package.
1514data PkgDesc = PkgDesc {
src/Idris/REPL.hs+17−134
@@ -9,10 +9,8 @@ Maintainer : The Idris Community.
99 PatternGuards, CPP #-}
1010
1111module Idris.REPL(
12− getClient, getPkg, getPkgCheck, getPkgClean, getPkgMkDoc
13− , getPkgREPL, getPkgTest, getPort, getIBCSubDir
14− , idris, idrisMain, loadInputs
15− , opt, runClient, runMain
12+ idris, idrisMain, loadInputs
13+ , runClient, runMain
1614 ) where
1715
1816import Idris.AbsSyntax
@@ -47,6 +45,7 @@ import Idris.TypeSearch (searchByType)
4745import Idris.IBC (loadPkgIndex, writePkgIndex)
4846
4947import Idris.REPL.Browse (namesInNS, namespacesInNS)
48+import Idris.REPL.Commands
5049
5150import Idris.ElabDecls
5251import Idris.Elab.Type
@@ -226,9 +225,10 @@ processNetCmd orig i h fn cmd
226225 IdeMode n _ -> ist {idris_outputmode = IdeMode n h}
227226
228227-- | Run a command on the server on localhost
229−runClient :: PortID -> String -> IO ()
228+runClient :: Maybe PortID -> String -> IO ()
230229runClient port str = withSocketsDo $ do
231− res <- X.try (connectTo "localhost" port)
230+ let port' = fromMaybe defaultPort port
231+ res <- X.try (connectTo "localhost" port')
232232 case res of
233233 Right h -> do
234234 hSetEncoding h utf8
@@ -1707,14 +1707,19 @@ idrisMain opts =
17071707 let cgFlags = opt getCodegenArgs opts
17081708
17091709 -- Now set/unset specifically chosen optimisations
1710− sequence_ (opt getOptimisation opts)
1710+ let os = opt getOptimisation opts
1711+
1712+ mapM_ processOptimisation os
1713+
17111714 script <- case opt getExecScript opts of
17121715 [] -> return Nothing
17131716 x:y:xs -> do iputStrLn "More than one interpreter expression found."
17141717 runIO $ exitWith (ExitFailure 1)
17151718 [expr] -> return (Just expr)
17161719 let immediate = opt getEvalExpr opts
1717− let port = getPort opts
1720+ let port = case getPort opts of
1721+ Nothing -> defaultPort
1722+ Just p -> p
17181723
17191724 when (DefaultTotal `elem` opts) $ do i <- getIState
17201725 putIState (i { default_total = DefaultCheckingTotal })
@@ -1829,6 +1834,10 @@ idrisMain opts =
18291834 makeOption ErrContext = setErrContext True
18301835 makeOption _ = return ()
18311836
1837+ processOptimisation :: (Bool,Optimisation) -> Idris ()
1838+ processOptimisation (True, p) = addOptimise p
1839+ processOptimisation (False, p) = removeOptimise p
1840+
18321841 addPkgDir :: String -> Idris ()
18331842 addPkgDir p = do ddir <- runIO getIdrisLibDir
18341843 addImportDir (ddir </> p)
@@ -1882,133 +1891,7 @@ initScript = do script <- runIO $ getIdrisInitScript
18821891 Success (Right cmd ) -> process [] cmd
18831892 Success (Left err) -> runIO $ print err
18841893
1885−getFile :: Opt -> Maybe String
1886−getFile (Filename str) = Just str
1887−getFile _ = Nothing
18881894
1889−getBC :: Opt -> Maybe String
1890−getBC (BCAsm str) = Just str
1891−getBC _ = Nothing
1892−
1893−getOutput :: Opt -> Maybe String
1894−getOutput (Output str) = Just str
1895−getOutput _ = Nothing
1896−
1897−getIBCSubDir :: Opt -> Maybe String
1898−getIBCSubDir (IBCSubDir str) = Just str
1899−getIBCSubDir _ = Nothing
1900−
1901−getImportDir :: Opt -> Maybe String
1902−getImportDir (ImportDir str) = Just str
1903−getImportDir _ = Nothing
1904−
1905−getPkgDir :: Opt -> Maybe String
1906−getPkgDir (Pkg str) = Just str
1907−getPkgDir _ = Nothing
1908−
1909−getPkg :: Opt -> Maybe (Bool, String)
1910−getPkg (PkgBuild str) = Just (False, str)
1911−getPkg (PkgInstall str) = Just (True, str)
1912−getPkg _ = Nothing
1913−
1914−getPkgClean :: Opt -> Maybe String
1915−getPkgClean (PkgClean str) = Just str
1916−getPkgClean _ = Nothing
1917−
1918−getPkgREPL :: Opt -> Maybe String
1919−getPkgREPL (PkgREPL str) = Just str
1920−getPkgREPL _ = Nothing
1921−
1922−getPkgCheck :: Opt -> Maybe String
1923−getPkgCheck (PkgCheck str) = Just str
1924−getPkgCheck _ = Nothing
1925−
1926−-- | Returns None if given an Opt which is not PkgMkDoc
1927−-- Otherwise returns Just x, where x is the contents of PkgMkDoc
1928−getPkgMkDoc :: Opt -- ^ Opt to extract
1929− -> Maybe String -- ^ Result
1930−getPkgMkDoc (PkgMkDoc str) = Just str
1931−getPkgMkDoc _ = Nothing
1932−
1933−getPkgTest :: Opt -- ^ the option to extract
1934− -> Maybe String -- ^ the package file to test
1935−getPkgTest (PkgTest f) = Just f
1936−getPkgTest _ = Nothing
1937−
1938−getCodegen :: Opt -> Maybe Codegen
1939−getCodegen (UseCodegen x) = Just x
1940−getCodegen _ = Nothing
1941−
1942−getCodegenArgs :: Opt -> Maybe String
1943−getCodegenArgs (CodegenArgs args) = Just args
1944−getCodegenArgs _ = Nothing
1945−
1946−getConsoleWidth :: Opt -> Maybe ConsoleWidth
1947−getConsoleWidth (UseConsoleWidth x) = Just x
1948−getConsoleWidth _ = Nothing
1949−
1950−
1951−getExecScript :: Opt -> Maybe String
1952−getExecScript (InterpretScript expr) = Just expr
1953−getExecScript _ = Nothing
1954−
1955−getPkgIndex :: Opt -> Maybe FilePath
1956−getPkgIndex (PkgIndex file) = Just file
1957−getPkgIndex _ = Nothing
1958−
1959−getEvalExpr :: Opt -> Maybe String
1960−getEvalExpr (EvalExpr expr) = Just expr
1961−getEvalExpr _ = Nothing
1962−
1963−getOutputTy :: Opt -> Maybe OutputType
1964−getOutputTy (OutputTy t) = Just t
1965−getOutputTy _ = Nothing
1966−
1967−getLanguageExt :: Opt -> Maybe LanguageExt
1968−getLanguageExt (Extension e) = Just e
1969−getLanguageExt _ = Nothing
1970−
1971−getTriple :: Opt -> Maybe String
1972−getTriple (TargetTriple x) = Just x
1973−getTriple _ = Nothing
1974−
1975−getCPU :: Opt -> Maybe String
1976−getCPU (TargetCPU x) = Just x
1977−getCPU _ = Nothing
1978−
1979−getOptLevel :: Opt -> Maybe Int
1980−getOptLevel (OptLevel x) = Just x
1981−getOptLevel _ = Nothing
1982−
1983−getOptimisation :: Opt -> Maybe (Idris ())
1984−getOptimisation (AddOpt p) = Just $ addOptimise p
1985−getOptimisation (RemoveOpt p) = Just $ removeOptimise p
1986−getOptimisation _ = Nothing
1987−
1988−getColour :: Opt -> Maybe Bool
1989−getColour (ColourREPL b) = Just b
1990−getColour _ = Nothing
1991−
1992−getClient :: Opt -> Maybe String
1993−getClient (Client x) = Just x
1994−getClient _ = Nothing
1995−
1996−-- Get the first valid port
1997−getPort :: [Opt] -> PortID
1998−getPort [] = defaultPort
1999−getPort (Port p:xs)
2000− | all (`elem` ['0'..'9']) p = PortNumber $ fromIntegral (read p)
2001− | otherwise = getPort xs
2002−getPort (_:xs) = getPort xs
2003−
2004−opt :: (Opt -> Maybe a) -> [Opt] -> [a]
2005−opt = mapMaybe
2006−
2007−{-
2008−ver = showVersion version ++ suffix
2009− where
2010− suffix = if gitHash =="" then "" else "-" ++ gitHash
2011−-}
20121895defaultPort :: PortID
20131896defaultPort = PortNumber (fromIntegral 4294)
20141897
src/Idris/REPL/Commands.hsnew file+76
@@ -0,0 +1,76 @@
1+module Idris.REPL.Commands where
2+
3+import Idris.Core.TT
4+import Idris.Colours
5+import Idris.AbsSyntaxTree
6+
7+-- | REPL commands
8+data Command = Quit
9+ | Help
10+ | Eval PTerm
11+ | NewDefn [PDecl] -- ^ Each 'PDecl' should be either a type declaration (at most one) or a clause defining the same name.
12+ | Undefine [Name]
13+ | Check PTerm
14+ | Core PTerm
15+ | DocStr (Either Name Const) HowMuchDocs
16+ | TotCheck Name
17+ | Reload
18+ | Watch
19+ | Load FilePath (Maybe Int) -- up to maximum line number
20+ | ChangeDirectory FilePath
21+ | ModImport String
22+ | Edit
23+ | Compile Codegen String
24+ | Execute PTerm
25+ | ExecVal PTerm
26+ | Metavars
27+ | Prove Bool Name -- ^ If false, use prover, if true, use elab shell
28+ | AddProof (Maybe Name)
29+ | RmProof Name
30+ | ShowProof Name
31+ | Proofs
32+ | Universes
33+ | LogLvl Int
34+ | LogCategory [LogCat]
35+ | Spec PTerm
36+ | WHNF PTerm
37+ | TestInline PTerm
38+ | Defn Name
39+ | Missing Name
40+ | DynamicLink FilePath
41+ | ListDynamic
42+ | Pattelab PTerm
43+ | Search [String] PTerm
44+ | CaseSplitAt Bool Int Name
45+ | AddClauseFrom Bool Int Name
46+ | AddProofClauseFrom Bool Int Name
47+ | AddMissing Bool Int Name
48+ | MakeWith Bool Int Name
49+ | MakeCase Bool Int Name
50+ | MakeLemma Bool Int Name
51+ | DoProofSearch Bool -- update file
52+ Bool -- recursive search
53+ Int -- depth
54+ Name -- top level name
55+ [Name] -- hints
56+ | SetOpt Opt
57+ | UnsetOpt Opt
58+ | NOP
59+ | SetColour ColourType IdrisColour
60+ | ColourOn
61+ | ColourOff
62+ | ListErrorHandlers
63+ | SetConsoleWidth ConsoleWidth
64+ | SetPrinterDepth (Maybe Int)
65+ | Apropos [String] String
66+ | WhoCalls Name
67+ | CallsWho Name
68+ | Browse [String]
69+ | MakeDoc String -- IdrisDoc
70+ | Warranty
71+ | PrintDef Name
72+ | PPrint OutputFmt Int PTerm
73+ | TransformInfo Name
74+ -- Debugging commands
75+ | DebugInfo Name
76+ | DebugUnify PTerm PTerm
src/Idris/REPL/Parser.hs+2−1
@@ -1,7 +1,6 @@
11{-|
22Module : Idris.REPL.Parser
33Description : Parser for the REPL commands.
4−Copyright :
54License : BSD3
65Maintainer : The Idris Community.
76-}
@@ -21,6 +20,8 @@ import Idris.Core.TT
2120import Idris.Help
2221import qualified Idris.Parser as P
2322
23+import Idris.REPL.Commands
24+
2425import Control.Applicative
2526import Control.Monad.State.Strict
2627