Previous: , Up: Access to procedure and operator definitions   [Contents][Index]


11.3 Support for tag files

A REDUCE mode submenu provides rapid access to some of the main facilities for finding a procedure definition via a tag file. Two commands (and submenu options) facilitate tagging the REDUCE files in one directory or in a directory and all its sub-directories. The former is useful for tagging all the files associated with a single project or package; the latter for tagging all REDUCE packages in a single tag file.

Once a TAGS file has been generated, the standard Emacs xref interface is available to find identifier references, in particular the command xref-find-definitions, which is also available via the REDUCE mode submenu. See Find Identifier References in GNU Emacs Manual.

The tagging commands use the standard Emacs etags program, which should be available in the Emacs bin directory. REDUCE mode uses the value of the option reduce-etags-directory, which should be appropriate by default, but if not can be customized. (It is not required that the Emacs bin directory be in your execution path, but if it is you can optionally set reduce-etags-directory to nil.)

M-.
M-x xref-find-definitions

Show the definitions of the identifier at point. With a prefix argument, or if there’s no identifier at point, prompt for the identifier.

M-x reduce-tagify-dir

Generate a REDUCE TAGS file for (all .red files in) the specified directory, by default the current directory. The TAGS file goes in the specified directory.

M-x reduce-tagify-dir-recursively

Generate a REDUCE TAGS file for (all .red files in) the specified directory, by default the current directory, and all its subdirectories. The single TAGS file goes in the specified directory.


Previous: Imenu support, Up: Access to procedure and operator definitions   [Contents][Index]