[Cl-darcs-cvs] r102 - cl-darcs/trunk

mhenoch at common-lisp.net mhenoch at common-lisp.net
Sat Mar 10 20:39:19 UTC 2007


Author: mhenoch
Date: Sat Mar 10 15:39:19 2007
New Revision: 102

Modified:
   cl-darcs/trunk/util.lisp
Log:
Fix off-by-ten error in HEX-TO-NUMBER


Modified: cl-darcs/trunk/util.lisp
==============================================================================
--- cl-darcs/trunk/util.lisp	(original)
+++ cl-darcs/trunk/util.lisp	Sat Mar 10 15:39:19 2007
@@ -47,9 +47,9 @@
     ((<= (char-code #\0) c (char-code #\9))
      (- c (char-code #\0)))
     ((<= (char-code #\A) c (char-code #\F))
-     (- c (char-code #\A)))
+     (+ 10 (- c (char-code #\A))))
     ((<= (char-code #\a) c (char-code #\f))
-     (- c (char-code #\a)))
+     (+ 10 (- c (char-code #\a))))
     (t
      (error "Invalid hex digit ~A." c))))
 



More information about the Cl-darcs-cvs mailing list