What I mean by debugging is the ability to navigate through errors after compilation.

I read that this can be done in AUCTeX with the command C-c [backtick]. I was wondering if there was a similar command in the major latex mode from latex-mode.el.


You can use the next-error and previous-error commands. By default next-error is bound to all of C-x [backtick] (note this the x instead of c), M-g n and M-g M-n; and previous-error is bound to M-g p and M-g M-p. Out of these my favorites are M-g M-n and M-g M-p.

By the way, all of those keybindings [1] also work with AucTeX (in addition to the AucTeX specific C-c [backtick] you mentioned). More generally, major modes are supposed to arrange for those same commands to work with whatever kind of "error" messages you might have to deal with in that mode. I put "error" in quotes because, for example, they also work with grep or with occur to navigate between occurrences of the search pattern. Definitely keybindings worth learning!

[1] AucTeX rebinds them to TeX-next-error and TeX-previous-error, instead of using the standard next-error and previous-error, but that's just a technicality.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.