diff lisp/cl.el @ 2071:0f60caa73962

[xemacs-hg @ 2004-05-11 11:33:08 by stephent] gensym docstring <87r7tryzla.fsf@tleepslib.sk.tsukuba.ac.jp> set-eol-detection fix <87vfj3yzs8.fsf@tleepslib.sk.tsukuba.ac.jp> etags.el tests <87zn8fz03v.fsf@tleepslib.sk.tsukuba.ac.jp>
author stephent
date Tue, 11 May 2004 11:33:22 +0000
parents 9c872f33ecbe
children f557693c61de
line wrap: on
line diff
--- a/lisp/cl.el	Mon May 10 21:50:25 2004 +0000
+++ b/lisp/cl.el	Tue May 11 11:33:22 2004 +0000
@@ -319,7 +319,10 @@
 
 (defun gensym (&optional arg)
   "Generate a new uninterned symbol.
-The name is made by appending a number to PREFIX, default \"G\"."
+The name is made by appending a number to a prefix.  If ARG is a string, it
+is the prefix, otherwise the prefix defaults to \"G\".  If ARG is an integer,
+the internal counter is reset to that number before creating the name.
+There is no way to specify both using this function."
   (let ((prefix (if (stringp arg) arg "G"))
 	(num (if (integerp arg) arg
 	       (prog1 *gensym-counter*
@@ -328,7 +331,8 @@
 
 (defun gentemp (&optional arg)
   "Generate a new interned symbol with a unique name.
-The name is made by appending a number to PREFIX, default \"G\"."
+The name is made by appending a number to ARG, default \"G\".
+If ARG is not a string, it is ignored."
   (let ((prefix (if (stringp arg) arg "G"))
 	name)
     (while (intern-soft (setq name (format "%s%d" prefix *gensym-counter*)))