- (define-checked-variable NAME INIT TYPENAME [BODY...])syntax
Wrapper around make-variable and checked-guard that defines the variable NAME to the variable.
NAME is an identifier.
INIT is some Scheme object.
TYPENAME is an identifier. The basename of a type predicate; see checked-guard.
BODY... as for checked-guard.
(use variable-item) (define-checked-variable scale * procedure) (scale 23) ;=> Error: (foo) "bad argument type - not a procedure" 23