(gensym number) was restricted to fixnums, restrict it to
unsigned-byte, as per the standard.
(multiple-value-bind (prefix int)
(etypecase thing
(simple-string (values thing old))
- (fixnum (values "G" thing))
+ (unsigned-byte (values "G" thing))
(string (values (coerce thing 'simple-string) old)))
(declare (simple-string prefix))
(make-symbol (%make-symbol-name prefix int)))))
(set-pprint-dispatch 'string
(lambda (stream obj) (write-string "BAR-" stream)))
(assert (string= "FOO-" (gentemp "FOO-") :end2 4))))
+
+(with-test (:name (gensym-fixnum-restriction))
+ (gensym (1+ most-positive-fixnum)))