Next: , Previous: Breakpoints and Stepping, Up: Debugging IDL Programs

5.4.4 Compiling Programs

In order to compile the current buffer under the IDLWAVE shell, press C-c C-d C-c (idlwave-save-and-run). This first saves the current buffer and then sends the command ‘.run path/to/file’ to the shell. You can also execute C-c C-d C-c from the shell buffer, in which case the most recently compiled buffer will be saved and re-compiled.

When developing or debugging a program, it is often necessary to execute the same command line many times. A convenient way to do this is C-c C-d C-y (idlwave-shell-execute-default-command-line). This command first resets IDL from a state of interrupted execution by closing all files and returning to the main interpreter level. Then a default command line is send to the shell. To edit the default command line, call idlwave-shell-execute-default-command-line with a prefix argument: C-u C-c C-d C-y. If no default command line has been set (or you give two prefix arguments), the last command on the comint input history is sent.

For quickly compiling and running the currently marked region as a main level program C-c C-d C-e (idlwave-shell-run-region) is very useful. A temporary file is created holding the contents of the current region (with END appended), and run from the shell.