Figure 3: The Emacs editor with an SML program
|
|
| Figure 4: The SML session window |
|
|
| Meta- | means: | hold down the “ Alt” or “ Alt function” key and press the key . |
| |
| means: | hold down the “Ctrl” key and press the key . |
|
| |
This a brief |
|
| |||
1. | Start Emacs by use of the emacs button in the | ||||
| *scratch* appears. Move the cursor to the Emacs window and click the left mouse | button | |||
| to select this window. Do not type your program in the *scratch* | window. |
| ||
2. | To create an SML program buffer for a program called “ gcd.sml”, type | ||||
| then gcd.sml, then press return. (Alternatively, use the Files menu.) |
| |||
| If the file | gcd.sml exists on disk already, it is loaded into Emacs. Otherwise a new empty | |||
| buffer is created. The suffix “ .sml” is important: it puts the buffer in Sml mode. |
| |||
3. | Type and edit your program in the SML program buffer. Editing commands are described in the | ||||
| reference card. |
|
|
| |
4. | Type | ||||
| menu.) |
|
|
|
|
5. | To load the program into an SML session, type | ||||
| Press return twice to answer the questions Ml command: mosml and Any args:. |
6