View Full Version : Macro execution error handling

Scott Lambert
May 3rd, 2013, 02:53 PM

When there is an error in your macro, you get that happy message "Macro error in register r#"
and it shows the offending command.

I was thinking it would be good, if there was an Edit button (Show button ?) as well.
Basically, it would insert the register with the error into a free buffer and position the
cursor at the start of the offending command.

One could fix the error, then use the Misc execute buffer to test it, once it works, you would
use file save-as to replace the on-disk version with the working version.

A related idea is two new internal values: error_reg which would be set the last register to
cause an error. The second one would be error_pos which would be the file_pos of the start of
the offending command in error_reg. Custom macros then could be written to speed up the
debugging process.