diff options
author | Mark Oteiza <mvoteiza@udel.edu> | 2017-09-12 11:08:00 -0400 |
---|---|---|
committer | Mark Oteiza <mvoteiza@udel.edu> | 2017-09-12 11:08:00 -0400 |
commit | 35c893ddaf21b93677850a69709b59630bb0feb7 (patch) | |
tree | 4b4a6f9755609940a542acbe639aefa295beb8d9 /doc/lispref/symbols.texi | |
parent | 2ae46b4c0dabfea80883a294dff16e0eb7182d30 (diff) | |
download | emacs-35c893ddaf21b93677850a69709b59630bb0feb7.tar.gz |
Move gensym to core Elisp
* doc/lispref/symbols.texi (Creating Symbols): Mention gensym right
after make-symbol.
* etc/NEWS: Mention.
* lisp/emacs-lisp/cl-macs.el (cl--gensym-counter): Alias to
gensym-counter.
(cl-gensym): Alias to gensym.
* lisp/emacs-lisp/cl.el: Remove gensym from list of aliases.
* lisp/emacs-lisp/edebug.el (edebug-make-enter-wrapper):
* lisp/emacs-lisp/ert-x.el (ert-with-message-capture):
(ert--expand-should-1, ert--expand-should):
(ert--should-error-handle-error):
* lisp/emacs-lisp/generator.el (cps--gensym):
* lisp/emacs-lisp/gv.el (setf):
* lisp/emacs-lisp/inline.el (inline--do-letlisteval):
* lisp/emacs-lisp/pcase.el (pcase--make-docstring, pcase-dolist):
(pcase--funcall, pcase--u1): Use gensym.
* lisp/subr.el (gensym-counter): New variable.
(gensym): New function, assimilated from cl-lib.
Diffstat (limited to 'doc/lispref/symbols.texi')
-rw-r--r-- | doc/lispref/symbols.texi | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/doc/lispref/symbols.texi b/doc/lispref/symbols.texi index e6ea8a1cc09..2d9ec6fda30 100644 --- a/doc/lispref/symbols.texi +++ b/doc/lispref/symbols.texi @@ -273,6 +273,13 @@ distinct uninterned symbol whose name is also @samp{foo}. @end example @end defun +@defun gensym &optional prefix +This function returns a symbol using @code{make-symbol}, whose name is +made by appending @code{gensym-counter} to @var{prefix}. The prefix +defaults to @code{"G"}. If @var{prefix} is a number, it replaces the +value of the counter. +@end defun + @defun intern name &optional obarray This function returns the interned symbol whose name is @var{name}. If there is no such symbol in the obarray @var{obarray}, @code{intern} |