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 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.)
Show the definitions of the identifier at point. With a prefix argument, or if there’s no identifier at point, prompt for the identifier.
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.
Generate a REDUCE TAGS file for (all .red
files in) the
specified directory, by default the current directory, and its
sub-directories to the specified depth. The depth defaults to 2,
which means the specified directory and each of its immediate
sub-directories, but no deeper sub-directories. Specifying a depth
less than or equal to 0 means all sub-directories with no limit. This
may fail on the REDUCE packages directory because it attempts to tag
too many files. The single TAGS file goes in the specified directory.