@@ -43,16 +43,6 @@ simple details example args_ flags_ callback =
43 do hPutStrLn stdout (Pkg.versionToString Compiler.version)
43 do hPutStrLn stdout (Pkg.versionToString Compiler.version)
44 Exit.exitSuccess
44 Exit.exitSuccess
46− "autocomplete" : n : chunks ->
47− case Read.readMaybe n of
52− do suggestions <- fst $ Chomp.chomp (Just index) chunks args_ flags_
53− hPutStr stdout (unlines suggestions)
57 if elem "--help" chunks then
47 if elem "--help" chunks then
58 Error.exitWithHelp Nothing details example args_ flags_
48 Error.exitWithHelp Nothing details example args_ flags_
@@ -83,19 +73,8 @@ complex intro outro interfaces =
83 do hPutStrLn stdout (Pkg.versionToString Compiler.version)
73 do hPutStrLn stdout (Pkg.versionToString Compiler.version)
84 Exit.exitSuccess
74 Exit.exitSuccess
86− "autocomplete" : n : chunks ->
87− case Read.readMaybe n of
92− do suggestions <- complexSuggest interfaces index chunks
93− hPutStr stdout (unlines suggestions)
96 command : chunks ->
76 command : chunks ->
97− do maybeAutoComplete argStrings (complexSuggest interfaces)
98− case List.find (\iface -> toName iface == command) interfaces of
77+ do case List.find (\iface -> toName iface == command) interfaces of
99 Nothing ->
78 Nothing ->
100 Error.exitWithUnknown command (map toName interfaces)
79 Error.exitWithUnknown command (map toName interfaces)
@@ -116,8 +95,8 @@ complex intro outro interfaces =
116-- AUTO-COMPLETE
95-- AUTO-COMPLETE
119−maybeAutoComplete :: [String] -> (Int -> [String] -> IO [String]) -> IO ()
98+_maybeAutoComplete :: [String] -> (Int -> [String] -> IO [String]) -> IO ()
120−maybeAutoComplete argStrings getSuggestions =
99+_maybeAutoComplete argStrings getSuggestions =
121 if length argStrings /= 3 then
100 if length argStrings /= 3 then
122 return ()
101 return ()