I am currently writing an R package and using compiled C++ code through the Rcpp
package in R (Rcpp makes the interaction of R and C++ code easier for a non-program
It's not all that easy, unfortunately. You need to jump between ESS, gdb (ie gud in Emacs) and R. The best description is probably still win Writing R Extensions, however there was a recent thread on the ESS mailing list that discusses this too (and note that some replies came in outside the thread so do look at the mailing list archive too).