aboutsummaryrefslogtreecommitdiffhomepage
path: root/goto.h
AgeCommit message (Collapse)AuthorFilesLines
2012-11-20fixed rubout of macro invocations: goto tables and q-registers are allocated ↵Robin Haberkorn1-2/+8
on the C++ call stack and configured to not emit undo tokens this introduces additional logic but has the huge advantage that the tables can be freed after the macro invocation. if undo tokens were emitted, the tables had to be kept in the undo stack so they can be restored during rubout. this however would be both complicated and unnecessarily inefficient since the tables would reach their initial state during rubout and be deallocated anyways. * similar (but not strictly necessary optimizations) can be performed for macro invocations * also wrapper Q-Register setting/getting -> will allow a custom "*" register getter (e.g. calculates buffer position on the fly)
2012-11-20goto table cleanupRobin Haberkorn1-1/+4
2012-11-20make goto tables local to macro invocation: they are declared on the C++ ↵Robin Haberkorn1-2/+67
callstack since macro invocations result in nested macro_execute() calls otherwise a macro could set labels with program counters which are invalid in other macros/the command line
2012-11-16support different kinds of runtime errors (using C++ exceptions)Robin Haberkorn1-2/+2
* also added some additional range checks (e.g. X command)
2012-11-11added <n>O...$ GOTO commandRobin Haberkorn1-1/+7
2012-11-10use namespace "States" instead of "states" structureRobin Haberkorn1-0/+4
has several advantages * better to read * namespace can be "extended" from everywhere allowing the declaration of states in the files that implement them * include file mess could be cleaned up a bit
2012-11-08added commentsRobin Haberkorn1-0/+4
2012-11-08support line termination ($$) as immediate editing command + some fixesRobin Haberkorn1-0/+2
* separate function for immediate editing command processing * undo.clear() to remove and free all undo tokens without executing them * goto_table_clear() to remove and free all goto table entries
2012-11-08added missing transition table initialization for label stateRobin Haberkorn1-0/+3
2012-11-08added support for labels, including the goto label tableRobin Haberkorn1-0/+14
* uses BSD tree macros, might later be abstracted to a C++ table class