mirror of
https://gitlab.com/embeddable-common-lisp/ecl.git
synced 2026-01-15 05:43:19 -08:00
Increase the safety settings of slot accessors so that they check the number of arguments they receive.
This commit is contained in:
parent
1d7ef44ed1
commit
f6893139ff
1 changed files with 4 additions and 4 deletions
|
|
@ -554,7 +554,7 @@ because it contains a reference to the undefined class~% ~A"
|
|||
`(si::instance-ref ,slotd #.(position 'location +slot-definition-slots+
|
||||
:key #'first))))
|
||||
(values #'(lambda (self)
|
||||
(declare (optimize (safety 0) (speed 3) (debug 0))
|
||||
(declare (optimize (safety 1) (speed 3) (debug 0))
|
||||
(standard-object self))
|
||||
(ensure-up-to-date-instance self)
|
||||
(let* ((class (si:instance-class self))
|
||||
|
|
@ -568,7 +568,7 @@ because it contains a reference to the undefined class~% ~A"
|
|||
value
|
||||
(values (slot-unbound (class-of self) self slot-name)))))
|
||||
#'(lambda (value self)
|
||||
(declare (optimize (safety 0) (speed 3) (debug 0))
|
||||
(declare (optimize (safety 1) (speed 3) (debug 0))
|
||||
(standard-object self))
|
||||
(ensure-up-to-date-instance self)
|
||||
(let* ((class (si:instance-class self))
|
||||
|
|
@ -583,12 +583,12 @@ because it contains a reference to the undefined class~% ~A"
|
|||
(declare (si::c-local)
|
||||
(fixnum slot-index))
|
||||
(values #'(lambda (self)
|
||||
(declare (optimize (safety 0) (speed 3) (debug 0))
|
||||
(declare (optimize (safety 1) (speed 3) (debug 0))
|
||||
(standard-object self))
|
||||
(ensure-up-to-date-instance self)
|
||||
(safe-instance-ref self index))
|
||||
#'(lambda (value self)
|
||||
(declare (optimize (safety 0) (speed 3) (debug 0))
|
||||
(declare (optimize (safety 1) (speed 3) (debug 0))
|
||||
(standard-object self))
|
||||
(ensure-up-to-date-instance self)
|
||||
(si:instance-set self index value))))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue