summaryrefslogtreecommitdiff
path: root/test-suite/tests
diff options
context:
space:
mode:
authorAndy Wingo <wingo@pobox.com>2009-05-21 17:22:58 +0200
committerAndy Wingo <wingo@pobox.com>2009-05-21 17:22:58 +0200
commit30a5e062d022aafdb72cea648f3a4de0e72feb6d (patch)
tree0dfdce2bb8987db00142874418c42530ba9160a2 /test-suite/tests
parenta48358b38fed9486cebf7f8338dc05adc770fc0f (diff)
downloadguile-30a5e062d022aafdb72cea648f3a4de0e72feb6d.tar.gz
procedures in "drop" contexts can return unspecified values
* module/language/tree-il/compile-glil.scm (flatten): For applications in "drop" context, allow the procedure to return unspecified values (including 0 values). * test-suite/tests/tree-il.test ("application"): Adapt test. * module/srfi/srfi-18.scm (wrap): Clarify. * test-suite/tests/srfi-18.test: Fix so that the expression importing srfi-18 is expanded before the tests. However the tests are still failing, something about 0-valued returns...
Diffstat (limited to 'test-suite/tests')
-rw-r--r--test-suite/tests/srfi-18.test9
-rw-r--r--test-suite/tests/tree-il.test8
2 files changed, 12 insertions, 5 deletions
diff --git a/test-suite/tests/srfi-18.test b/test-suite/tests/srfi-18.test
index fa309e6ce..3c7090643 100644
--- a/test-suite/tests/srfi-18.test
+++ b/test-suite/tests/srfi-18.test
@@ -21,8 +21,13 @@
(define-module (test-suite test-srfi-18)
#:use-module (test-suite lib))
-(and (provided? 'threads)
- (use-modules (srfi srfi-18))
+;; two expressions so that the srfi-18 import is in effect for expansion
+;; of the rest
+(if (provided? 'threads)
+ (use-modules (srfi srfi-18)))
+
+(and
+ (provided? 'threads)
(with-test-prefix "current-thread"
diff --git a/test-suite/tests/tree-il.test b/test-suite/tests/tree-il.test
index 873051f03..724ea7960 100644
--- a/test-suite/tests/tree-il.test
+++ b/test-suite/tests/tree-il.test
@@ -68,10 +68,12 @@
(assert-tree-il->glil
(apply (toplevel foo) (const 1))
(program 0 0 0 0 () (toplevel ref foo) (const 1) (call goto/args 1)))
- (assert-tree-il->glil
+ (assert-tree-il->glil/pmatch
(begin (apply (toplevel foo) (const 1)) (void))
- (program 0 0 0 0 () (toplevel ref foo) (const 1) (call call 1)
- (call drop 1) (void) (call return 1)))
+ (program 0 0 0 0 () (toplevel ref foo) (const 1) (mv-call 1 ,l1)
+ (const 1) (label ,l2) (mv-bind () #f) (unbind)
+ (void) (call return 1))
+ (eq? l1 l2))
(assert-tree-il->glil
(apply (toplevel foo) (apply (toplevel bar)))
(program 0 0 0 0 () (toplevel ref foo) (toplevel ref bar) (call call 0)