* fixed some bugs revealed by Paul Dietz' test suite:
** INCF, DECF and REMF evaluate their place form as specified in
CLtS 5.1.3.
+ ** FORMATTER expands ~{ iteration directives with V or #
+ parameters correctly.
changes in sbcl-0.8.17 relative to sbcl-0.8.16:
* new feature: a build-time option (controlled by the :SB-UNICODE
(throw 'need-orig-args nil))
(let ((*up-up-and-out-allowed* colonp))
(expand-directive-list (subseq directives 0 posn)))))
- (compute-loop-aux (count)
+ (compute-loop (count)
(when atsignp
(setf *only-simple-args* nil))
`(loop
,@(when closed-with-colon
'((when (null args)
(return))))))
- (compute-loop ()
- (if params
- (expand-bind-defaults ((count nil)) params
- (compute-loop-aux count))
- (compute-loop-aux nil)))
- (compute-block ()
+ (compute-block (count)
(if colonp
`(block outside-loop
- ,(compute-loop))
- (compute-loop)))
- (compute-bindings ()
+ ,(compute-loop count))
+ (compute-loop count)))
+ (compute-bindings (count)
(if atsignp
- (compute-block)
- `(let* ((orig-args ,(expand-next-arg))
- (args orig-args))
- (declare (ignorable orig-args args))
- ,(let ((*expander-next-arg-macro* 'expander-next-arg)
- (*only-simple-args* nil)
- (*orig-args-available* t))
- (compute-block))))))
- (values (if (zerop posn)
- `(let ((inside-string ,(expand-next-arg)))
- ,(compute-bindings))
- (compute-bindings))
+ (compute-block count)
+ `(let* ((orig-args ,(expand-next-arg))
+ (args orig-args))
+ (declare (ignorable orig-args args))
+ ,(let ((*expander-next-arg-macro* 'expander-next-arg)
+ (*only-simple-args* nil)
+ (*orig-args-available* t))
+ (compute-block count))))))
+ (values (if params
+ (expand-bind-defaults ((count nil)) params
+ (if (zerop posn)
+ `(let ((inside-string ,(expand-next-arg)))
+ ,(compute-bindings count))
+ (compute-bindings count)))
+ (if (zerop posn)
+ `(let ((inside-string ,(expand-next-arg)))
+ ,(compute-bindings nil))
+ (compute-bindings nil)))
(nthcdr (1+ posn) directives))))))
(def-complex-format-directive #\} ()
(let ((dticks 0)
(dconsing 0)
(inner-enclosed-profiles 0))
+ (declare (optimize (safety 0)))
(declare (type unsigned-byte dticks dconsing))
(declare (type unsigned-byte inner-enclosed-profiles))
(aver (typep dticks 'unsigned-byte))
(pcounter-or-fixnum->integer *enclosed-profiles*))
(let ((net-dticks (fastbig- dticks *enclosed-ticks*)))
(fastbig-incf-pcounter-or-fixnum ticks net-dticks))
- (let ((net-dconsing (fastbig- dconsing
- (pcounter-or-fixnum->integer
- *enclosed-consing*))))
+ (let ((net-dconsing (fastbig-
+ (fastbig- dconsing
+ (pcounter-or-fixnum->integer
+ *enclosed-consing*))
+ ;; three variables with value
+ ;; cells two bytes each.
+ (* 3 2 sb-vm:n-word-bytes))))
(fastbig-incf-pcounter-or-fixnum consing net-dconsing))
(fastbig-incf-pcounter-or-fixnum profiles
inner-enclosed-profiles))))