source: trunk/source/tests/ansi-tests/multiple-value-call.lsp @ 8991

Last change on this file since 8991 was 8991, checked in by gz, 12 years ago

Check in the gcl ansi test suite (original, in preparation for making local changes)

File size: 781 bytes
Line 
1;-*- Mode:     Lisp -*-
2;;;; Author:   Paul Dietz
3;;;; Created:  Fri Oct 18 23:35:07 2002
4;;;; Contains: Tests of MULTIPLE-VALUE-CALL, MULTIPLE-VALUE-LIST
5
6(in-package :cl-test)
7
8(deftest multiple-value-call.1
9  (multiple-value-call #'+ (values 1 2) (values) 3 (values 4 5 6))
10  21)
11
12(deftest multiple-value-call.2
13  (multiple-value-call 'list)
14  nil)
15
16(deftest multiple-value-call.3
17  (multiple-value-call 'list (floor 13 4))
18  (3 1))
19
20;;; Macros are expanded in the appropriate environment
21
22(deftest multiple-value-call.4
23  (macrolet
24   ((%m (z) z))
25   (multiple-value-call (expand-in-current-env (%m #'list)) (values 1 2)))
26  (1 2))
27
28(deftest multiple-value-call.5
29  (macrolet
30   ((%m (z) z))
31   (multiple-value-call 'list (expand-in-current-env (%m (values 1 2)))))
32  (1 2))
33
34
Note: See TracBrowser for help on using the repository browser.