Refactor GFI to treat command line files and the i command uniformly. Disable CSE by default in GFI.

This commit is contained in:
bjorn
2008-05-30 15:20:28 +00:00
parent bec9d06fae
commit aa010a84bd
3 changed files with 33 additions and 29 deletions

View File

@@ -1,5 +1,6 @@
module GF.Command.Interpreter (
CommandEnv (..),
mkCommandEnv,
interpretCommandLine
) where
@@ -21,6 +22,9 @@ data CommandEnv = CommandEnv {
commands :: Map.Map String CommandInfo
}
mkCommandEnv :: PGF -> CommandEnv
mkCommandEnv pgf = CommandEnv pgf (allCommands pgf)
interpretCommandLine :: CommandEnv -> String -> IO ()
interpretCommandLine env line = case (pCommandLine (myLexer line)) of
Ok CEmpty -> return ()