Fix w/c to handle expression form of with-contract, and disable internal contracts.
original commit: 684ae395e648f22e38f1fa55aa6c0f48a60fbd5e
This commit is contained in:
commit
15b1f6378b
|
@ -161,7 +161,7 @@ at least theoretically.
|
|||
|
||||
|
||||
;; turn contracts on and off - off by default for performance.
|
||||
(define-for-syntax enable-contracts? #t)
|
||||
(define-for-syntax enable-contracts? #f)
|
||||
(provide (for-syntax enable-contracts?) p/c w/c cnt d-s/c d/c d/c/p)
|
||||
|
||||
(define-syntax-rule (d/c/p (name . args) c . body)
|
||||
|
@ -190,6 +190,8 @@ at least theoretically.
|
|||
(make-rename-transformer #'with-contract)
|
||||
(lambda (stx)
|
||||
(syntax-parse stx
|
||||
[(_ name (~or #:results #:result) spec . body)
|
||||
#'(let () . body)]
|
||||
[(_ name specs . body)
|
||||
#'(begin . body)]))))
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user