diff options
| author | 2025-11-02 13:06:51 -0500 | |
|---|---|---|
| committer | 2025-11-02 13:06:51 -0500 | |
| commit | 4359571add4124b304b74e10f27dd567d0a82774 (patch) | |
| tree | 84744c1d67d820e63718d0d938716d116ecd6cb5 /lib/cuprate.define-test-application.scm | |
| parent | make macro generators, test on chibi. Currently broken in CHICKEN-5 due to a ... (diff) | |
add hack to support foment and CHICKEN 5.3.0
Diffstat (limited to 'lib/cuprate.define-test-application.scm')
| -rw-r--r-- | lib/cuprate.define-test-application.scm | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/lib/cuprate.define-test-application.scm b/lib/cuprate.define-test-application.scm new file mode 100644 index 0000000..f28eb37 --- /dev/null +++ b/lib/cuprate.define-test-application.scm @@ -0,0 +1,25 @@ +(define-syntax define-test-application + (syntax-rules () + ((_ name (args ...)) + (define-test-application "loop" name (args ...) () ())) + ((_ "loop" name ((default) args ...) (rest ...) ids) + (define-test-application "loop" name (args ...) + ((#f default) rest ...) ids)) + ((_ "loop" name (arg args ...) (rest ...) (ids ...)) + (define-test-application "loop" name (args ...) + ((arg tmp) rest ...) (tmp ids ...))) + ((_ "loop" name () stuff ids) + (define-test-application "reverse1" name stuff ids ())) + ((_ "reverse1" name (pair rest ...) ids (acc ...)) + (define-test-application "reverse1" name (rest ...) ids (pair acc ...))) + ((_ "reverse1" name () ids pairs) + (define-test-application "reverse2" name ids () pairs)) + ((_ "reverse2" name (id1 id2 ...) (acc ...) pairs) + (define-test-application "reverse2" name (id2 ...) (id1 acc ...) pairs)) + ((_ "reverse2" name () (ids ...) (pairs ...)) + (define-syntax name + (syntax-rules () + ((_ ids ...) (name #f ids ...)) + ((_ test-name ids ...) + (test-named-application test-name pairs ...))))))) + |
