Taught :breakpoint add to guess the module name if not given
[ghc-hetmet.git] / compiler / ghci / InteractiveUI.hs
index 0f02282..b5af439 100644 (file)
@@ -215,7 +215,7 @@ helpText =
  "\n" ++
  " Options for ':breakpoint':\n" ++
  "   list                                     list the current breakpoints\n" ++
- "   add Module line [col]                    add a new breakpoint\n" ++
+ "   add [Module] line [col]                    add a new breakpoint\n" ++
  "   del (breakpoint# | Module line [col])    delete a breakpoint\n" ++
  "   continue                                 continue execution\n"  ++
  "   stop                   Stop a computation and return to the top level\n" ++
@@ -1358,7 +1358,7 @@ wrapCompleter fun w =  do
 getCommonPrefix :: [String] -> String
 getCommonPrefix [] = ""
 getCommonPrefix (s:ss) = foldl common s ss
-  where common s "" = s
+  where common s "" = ""
        common "" s = ""
        common (c:cs) (d:ds)
           | c == d = c : common cs ds