William Harold Newman | 3 Jun 2002 20:23
Picon

CVS: sbcl/src/code target-sxhash.lisp,1.6,1.7

Update of /cvsroot/sbcl/sbcl/src/code
In directory usw-pr-cvs1:/tmp/cvs-serv26681/src/code

Modified Files:
	target-sxhash.lisp 
Log Message:
0.7.4.13:
	closed bug 68: "working as designed" (since CSR points out
		that the existence of CHANGE-CLASS makes it unsafe for
		SXHASH to hash STANDARD-OBJECTs based on class names,
		and there's no other obvious way for SXHASH to generate
		nontrivial hash values for STANDARD-OBJECTs)
	closed bug 71, since it hasn't existed for some time (DECLAIM
		OPTIMIZE SPEED works now.)

Index: target-sxhash.lisp
===================================================================
RCS file: /cvsroot/sbcl/sbcl/src/code/target-sxhash.lisp,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -d -r1.6 -r1.7
--- target-sxhash.lisp	12 Dec 2001 18:33:41 -0000	1.6
+++ target-sxhash.lisp	3 Jun 2002 18:23:56 -0000	1.7
 <at>  <at>  -145,6 +145,13  <at>  <at> 
 		    (logxor 422371266
 			    (sxhash ; through DEFTRANSFORM
 			     (class-name (layout-class (%instance-layout x)))))
+		    ;; Nice though it might be to return a nontrivial
+		    ;; hash value for other instances (especially
+		    ;; STANDARD-OBJECTs) there seems to be no good way
+		    ;; to do so. We can't even do the CLASS-NAME trick
+		    ;; (as used above for STRUCTURE-OBJECT) because
+		    ;; then CHANGE-CLASS would cause SXHASH values to
+		    ;; change, ouch! -- WHN recording wisdom of CSR
 		    309518995))
 	       (symbol (sxhash x)) ; through DEFTRANSFORM
 	       (array

_______________________________________________________________

Don't miss the 2002 Sprint PCS Application Developer's Conference
August 25-28 in Las Vegas -- http://devcon.sprintpcs.com/adp/index.cfm

Gmane