Initial support for adding body from signature

This commit is contained in:
Alejandro Serrano
2014-06-10 21:34:05 +02:00
parent cedf59ace7
commit 323c1b5471
6 changed files with 104 additions and 2 deletions

View File

@@ -145,6 +145,7 @@ loop opt set mvar = do
"info" -> toGhcMod $ showInfo opt set arg
"type" -> toGhcMod $ showType opt set arg
"split" -> toGhcMod $ doSplit opt set arg
"sig" -> toGhcMod $ doSig opt set arg
"boot" -> bootIt set
"browse" -> browseIt set arg
"quit" -> return ("quit", False, set)
@@ -265,6 +266,16 @@ doSplit opt set fileArg = do
ret <- splits opt file (read line) (read column)
return (ret, True, set')
doSig :: Options
-> Set FilePath
-> FilePath
-> Ghc (String, Bool, Set FilePath)
doSig opt set fileArg = do
let [file, line, column] = words fileArg
set' <- newFileSet set file
ret <- sig opt file (read line) (read column)
return (ret, True, set')
----------------------------------------------------------------
bootIt :: Set FilePath