|
|
| ||||||
14 Use with emacs |
This section describes the Unix/Linux version. If you use Windows you should also read section 14.1 for the differences.
emacs provides a convenient environment for using rsltc. Its "compile" facility allows a user to see error messages in a separate window and just click on them (middle button) to go straight to the source of the error in the appropriate file. Additional tools, like VCG (section 8) and the SML run-time tool (section 9) can be invoked automatically or from a menu.
There are a number of files supplied with the tool that support use with emacs:
rsl-mode.el | syntax highlighting; RSL menu |
rsltc.el | rsltc interface |
rslconvert.el, tokenise.el | conversion to LaTeX |
(load "rsl-mode") (load "rslconvert")
This will load all the emacs files.
If the files are not in your emacs load-path, then you can use
load-file instead of load. You will have to load
all four files, and give a path name and
the .el
extension as part of the file name string, as in
(load-file "/home/me/rsltc.el") (load-file "/home/me/rsl-mode.el") (load-file "/home/me/tokenise.el") (load-file "/home/me/rslconvert.el")
You will find rslconvert.el useful if you use LaTeX for documentation. See section 17.
When rsl-mode.el is loaded and you open an RSL file (with extension .rsl) in emacs then you will find an RSL menu from which the rsltc tool components can be invoked.
Apart from the pretty printer, emacs will start a second window to display output. Errors and confidence conditions start with a file:line:column string and clicking with the middle mouse button on a line starting with this string places the cursor at the relevant position in that file in the first window.
The pretty-printer puts its output in the same buffer as the input, but does not save it, and offers an "undo" option to go back to the the state before pretty printing.
There is also a menu item to run the SML run-time system on the output from the SML translator. See also section 15.
When the "Draw module dependency graph" menu item is selected, emacs will automatically start the VCG tool on the output.
14 Use with emacs | ||||||||
|
|
|