X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=docs%2Fusers_guide%2Fghci.xml;h=f56c079114e8438f16ea49b17853152162eaa54e;hb=c61001a6d252f2f260c271de30d76e64e4626c4f;hp=ae55203e944b2b03bd238a6a8e6da18c4543df8d;hpb=a1579a34bba86590e3656e5c7e88a78a9fb2f584;p=ghc-hetmet.git
diff --git a/docs/users_guide/ghci.xml b/docs/users_guide/ghci.xml
index ae55203..f56c079 100644
--- a/docs/users_guide/ghci.xml
+++ b/docs/users_guide/ghci.xml
@@ -49,6 +49,8 @@ Prelude>
:browse [*]<module> display the names defined by <module>
:cd <dir> change directory to <dir>
:def <cmd> <expr> define a command :<cmd>
+ :edit <file> edit file
+ :edit edit last module
:help, :? display this list of commands
:info [<name> ...] display information about the given names
:load <filename> ... load module(s) and their dependents
@@ -60,12 +62,13 @@ Prelude>
:set args <arg> ... set the arguments returned by System.getArgs
:set prog <progname> set the value returned by System.getProgName
:set prompt <prompt> set the prompt used in GHCi
+ :set editor <cmd> set the command used for :edit
:show modules show the currently loaded modules
:show bindings show the current bindings made at the prompt
:ctags [<file>] create tags file for Vi (default: "tags")
- :etags [<file>] create tags file for Emacs (defauilt: "TAGS")
+ :etags [<file>] create tags file for Emacs (default: "TAGS")
:type <expr> show the type of <expr>
:kind <type> show the kind of <type>
:undef <cmd> undefine user-defined command :<cmd>
@@ -1013,6 +1016,22 @@ Prelude> :. cmds.ghci
+ :edit file
+ :edit
+
+
+ Opens an editor to edit the file
+ file, or the most recently loaded
+ module if file is omitted. The
+ editor to invoke is taken from the EDITOR
+ environment variable, or a default editor on your system if
+ EDITOR is not set. You can change the
+ editor using :set editor.
+
+
+
+
+ :help:help
@@ -1178,6 +1197,16 @@ Prelude> :main foo bar
+ :seteditorcmd
+
+
+ Sets the command used by :edit to
+ cmd.
+
+
+
+
+ :setprogprog:set prog
@@ -1482,7 +1511,7 @@ Prelude> :set -fno-glasgow-exts
-
+ FAQ and Things To Watch Out For
@@ -1527,10 +1556,9 @@ Prelude> :set -fno-glasgow-exts
Concurrent threads don't carry on running when GHCi is
waiting for input.
- No, they don't. This is because the Haskell binding
- to the GNU readline library doesn't support reading from the
- terminal in a non-blocking way, which is required to work
- properly with GHC's concurrency model.
+ This should work, as long as your GHCi was built with
+ the switch, which is the default.
+ Consult whoever supplied your GHCi installation.
@@ -1557,6 +1585,13 @@ Prelude> :set -fno-glasgow-exts
+
+ I can't use Control-C to interrupt computations in
+ GHCi on Windows.
+
+ See .
+
+