Dropping when-not (because its unless)
This commit is contained in:
parent
5b69379de1
commit
7e00aac988
4
d-.scm
4
d-.scm
@ -6,7 +6,6 @@
|
|||||||
~>>
|
~>>
|
||||||
as~>
|
as~>
|
||||||
if-not
|
if-not
|
||||||
when-not
|
|
||||||
if-let
|
if-let
|
||||||
for
|
for
|
||||||
partial
|
partial
|
||||||
@ -42,9 +41,6 @@
|
|||||||
(define-syntax-rule (if-not pred body ...)
|
(define-syntax-rule (if-not pred body ...)
|
||||||
(if (not pred) body ...))
|
(if (not pred) body ...))
|
||||||
|
|
||||||
(define-syntax-rule (when-not pred body ...)
|
|
||||||
(when (not pred) body ...))
|
|
||||||
|
|
||||||
(define-syntax-rule (if-let ([ident test]) expr ...)
|
(define-syntax-rule (if-let ([ident test]) expr ...)
|
||||||
(let ([ident test])
|
(let ([ident test])
|
||||||
(if ident
|
(if ident
|
||||||
|
6
test.scm
6
test.scm
@ -30,12 +30,6 @@
|
|||||||
(define-test "test"
|
(define-test "test"
|
||||||
(assert-equal 'a (if-not #f 'a 'b))))
|
(assert-equal 'a (if-not #f 'a 'b))))
|
||||||
|
|
||||||
(define-test-suite "when-not"
|
|
||||||
(define-test "positive-case"
|
|
||||||
(assert-equal 'return (when-not #f 'do-some-stuff 'return)))
|
|
||||||
(define-test "negative-case"
|
|
||||||
(assert-unspecified (when-not #t 'do-some-stuff 'return))))
|
|
||||||
|
|
||||||
(define-test-suite "for"
|
(define-test-suite "for"
|
||||||
(define-test "permutation"
|
(define-test "permutation"
|
||||||
(define value (for ([i (iota 2)]
|
(define value (for ([i (iota 2)]
|
||||||
|
Loading…
Reference in New Issue
Block a user