0.pre7.50:
[sbcl.git] / src / code / symbol.lisp
index 5bf53d8..5182924 100644 (file)
        (%primitive sb!c:make-other-immediate-type 0 sb!vm:unbound-marker-type))
   variable)
 
+#!+(or x86 mips) ;; only backends for which a symbol-hash vop exists
 (defun symbol-hash (symbol)
   #!+sb-doc
   "Return the built-in hash value for symbol."
   (symbol-hash symbol))
 
+#!-(or x86 mips)
+(defun symbol-hash (symbol)
+  #!+sb-doc
+  "Return the built-in hash value for symbol."
+  (%sxhash-simple-string (symbol-name symbol)))
+
+
 (defun symbol-function (variable)
   #!+sb-doc
   "VARIABLE must evaluate to a symbol. This symbol's current definition
@@ -89,8 +97,7 @@
 (defun make-symbol (string)
   #!+sb-doc
   "Make and return a new symbol with the STRING as its print name."
-  #!-gengc (make-symbol string)
-  #!+gengc (%make-symbol (random most-positive-fixnum) string))
+  (make-symbol string))
 
 (defun get (symbol indicator &optional (default nil))
   #!+sb-doc
 
 (defun getf (place indicator &optional (default ()))
   #!+sb-doc
-  "Searches the property list stored in Place for an indicator EQ to Indicator.
-  If one is found, the corresponding value is returned, else the Default is
-  returned."
+  "Search the property list stored in Place for an indicator EQ to INDICATOR.
+  If one is found, return the corresponding value, else return DEFAULT."
   (do ((plist place (cddr plist)))
       ((null plist) default)
     (cond ((atom (cdr plist))
 
 (defun get-properties (place indicator-list)
   #!+sb-doc
-  "Like GETF, except that Indicator-List is a list of indicators which will
-  be looked for in the property list stored in Place. Three values are
+  "Like GETF, except that INDICATOR-LIST is a list of indicators which will
+  be looked for in the property list stored in PLACE. Three values are
   returned, see manual for details."
   (do ((plist place (cddr plist)))
       ((null plist) (values nil nil nil))
 
 (defun keywordp (object)
   #!+sb-doc
-  "Returns true if Object is a symbol in the keyword package."
+  "Return true if Object is a symbol in the \"KEYWORD\" package."
   (and (symbolp object)
        (eq (symbol-package object) *keyword-package*)))
 \f
 (defvar *gentemp-counter* 0)
 (declaim (type unsigned-byte *gentemp-counter*))
 
-(defun gentemp (&optional (prefix "T") (package *package*))
+(defun gentemp (&optional (prefix "T") (package (sane-package)))
   #!+sb-doc
-  "Creates a new symbol interned in package Package with the given Prefix."
+  "Creates a new symbol interned in package PACKAGE with the given PREFIX."
   (declare (type string prefix))
   (loop
     (let ((*print-base* 10)