Use of String Utilities in the edtdbg Debugging Tool
The internal code of the edtdbg
debugging tool, which will be discussed in Section 13.4, makes heavy use of string utilities. A typical example of such usage is the dgbsendeditcmd()
function:
# send command to editor dbgsendeditcmd <- function(cmd) { syscmd <- paste("vim --remote-send ",cmd," --servername ",vimserver,sep="") system(syscmd) }
What is going on here? The main point is that edtdbg
sends remote commands to the Vim text editor. For instance, if you are running Vim with a server name of 168
and you want the cursor in Vim to move to line 12, you could type this into a terminal (shell) window:
vim --remote-send 12G --servername 168
The effect would be the same as if you had physically ...
Get The Art of R Programming now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.