annotate test/bytecomp-testsuite.el @ 110410:f2e111723c3a

Merge changes made in Gnus trunk. Reimplement nnimap, and do tweaks to the rest of the code to support that. * gnus-int.el (gnus-finish-retrieve-group-infos) (gnus-retrieve-group-data-early): New functions. * gnus-range.el (gnus-range-nconcat): New function. * gnus-start.el (gnus-get-unread-articles): Support early retrieval of data. (gnus-read-active-for-groups): Support finishing the early retrieval of data. * gnus-sum.el (gnus-summary-move-article): Pass the move-to group name if the move is internal, so that nnimap can do fast internal moves. * gnus.el (gnus-article-special-mark-lists): Add uid/active tuples, for nnimap usage. * nnimap.el: Rewritten. * nnmail.el (nnmail-inhibit-default-split-group): New internal variable to allow the mail splitting to not return a default group. This is useful for nnimap, which will leave unmatched mail in the inbox. * utf7.el (utf7-encode): Autoload. Implement shell connection. * nnimap.el (nnimap-open-shell-stream): New function. (nnimap-open-connection): Use it. Get the number of lines by using BODYSTRUCTURE. (nnimap-transform-headers): Get the number of lines in each message. (nnimap-retrieve-headers): Query for BODYSTRUCTURE so that we get the number of lines. Not all servers return UIDNEXT. Work past this problem. Remove junk from end of file. Fix typo in "bogus" section. Make capabilties be case-insensitive. Require cl when compiling. Don't bug out if the LIST command doesn't have any parameters. 2010-09-17 Knut Anders Hatlen <kahatlen@gmail.com> (tiny change) * nnimap.el (nnimap-get-groups): Don't bug out if the LIST command doesn't have any parameters. (mm-text-html-renderer): Document gnus-article-html. 2010-09-17 Julien Danjou <julien@danjou.info> (tiny fix) * mm-decode.el (mm-text-html-renderer): Document gnus-article-html. * dgnushack.el: Define netrc-credentials. If the user doesn't have a /etc/services, supply some sensible port defaults. Have `unseen-or-unread' select an unread unseen article first. (nntp-open-server): Return whether the open was successful or not. Throughout all files, replace (save-excursion (set-buffer ...)) with (with-current-buffer ... ). Save result so that it doesn't say "failed" all the time. Add ~/.authinfo to the default, since that's probably most useful for users. Don't use the "finish" method when we're reading from the agent. Add some more nnimap-relevant agent stuff to nnagent.el. * nnimap.el (nnimap-with-process-buffer): Removed. Revert one line that was changed by mistake in the last checkin. (nnimap-open-connection): Don't error out when we can't make a connection nnimap-related changes to avoid bugging out if we can't contact a server. * gnus-start.el (gnus-get-unread-articles): Don't try to scan groups from methods that are denied. * nnimap.el (nnimap-possibly-change-group): Return nil if we can't log in. (nnimap-finish-retrieve-group-infos): Make sure we're not waiting for nothing. * gnus-sum.el (gnus-select-newsgroup): Indent.
author Katsumi Yamaoka <yamaoka@jpl.org>
date Sat, 18 Sep 2010 10:02:19 +0000
parents 1d1d5d9bd884
children 376148b31b5e
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
100068
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
1 ;;; bytecomp-testsuite.el
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
2
106815
1d1d5d9bd884 Add 2010 to copyright years.
Glenn Morris <rgm@gnu.org>
parents: 100950
diff changeset
3 ;; Copyright (C) 2008, 2009, 2010 Free Software Foundation, Inc.
100068
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
4
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
5 ;; Author: Shigeru Fukaya <shigeru.fukaya@gmail.com>
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
6 ;; Created: November 2008
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
7 ;; Keywords: internal
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
8 ;; Human-Keywords: internal
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
9
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
10 ;; This file is part of GNU Emacs.
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
11
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
12 ;; GNU Emacs is free software: you can redistribute it and/or modify
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
13 ;; it under the terms of the GNU General Public License as published by
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
14 ;; the Free Software Foundation, either version 3 of the License, or
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
15 ;; (at your option) any later version.
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
16
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
17 ;; GNU Emacs is distributed in the hope that it will be useful,
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
18 ;; but WITHOUT ANY WARRANTY; without even the implied warranty of
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
19 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
20 ;; GNU General Public License for more details.
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
21
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
22 ;; You should have received a copy of the GNU General Public License
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
23 ;; along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>.
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
24
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
25 ;;; Commentary:
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
26
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
27 ;;; Code:
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
28 (defconst byte-opt-testsuite-arith-data
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
29 '(
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
30 ;; some functional tests
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
31 (let ((a most-positive-fixnum) (b 1) (c 1.0)) (+ a b c))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
32 (let ((a most-positive-fixnum) (b -2) (c 1.0)) (- a b c))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
33 (let ((a most-positive-fixnum) (b 2) (c 1.0)) (* a b c))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
34 (let ((a 3) (b 2) (c 1.0)) (/ a b c))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
35 (let ((a (+ 1 (expt 2 -64))) (b (expt 2 -65))) (+ a -1 b))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
36 (let ((a (+ 1 (expt 2 -64))) (b (expt 2 -65))) (- a 1 (- b)))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
37 (let ((a (expt 2 -1074)) (b 0.125)) (* a 8 b))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
38 (let ((a 1.0)) (* a 0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
39 (let ((a 1.0)) (* a 2.0 0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
40 (let ((a 1.0)) (/ 0 a))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
41 (let ((a 1.0)) (/ 3 a 2))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
42 (let ((a most-positive-fixnum) (b 2.0)) (* a 2 b))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
43 (let ((a 3) (b 2)) (/ a b 1.0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
44 (/ 3 -1)
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
45 (+ 4 3 2 1)
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
46 (+ 4 3 2.0 1)
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
47 (- 4 3 2 1) ; not new, for reference
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
48 (- 4 3 2.0 1) ; not new, for reference
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
49 (* 4 3 2 1)
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
50 (* 4 3 2.0 1)
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
51 (/ 4 3 2 1)
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
52 (/ 4 3 2.0 1)
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
53 (let ((a 3) (b 2)) (+ a b 1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
54 (let ((a 3) (b 2)) (+ a b -1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
55 (let ((a 3) (b 2)) (- a b 1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
56 (let ((a 3) (b 2)) (- a b -1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
57 (let ((a 3) (b 2)) (+ a b a 1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
58 (let ((a 3) (b 2)) (+ a b a -1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
59 (let ((a 3) (b 2)) (- a b a 1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
60 (let ((a 3) (b 2)) (- a b a -1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
61 (let ((a 3) (b 2)) (* a b -1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
62 (let ((a 3) (b 2)) (* a -1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
63 (let ((a 3) (b 2)) (/ a b 1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
64 (let ((a 3) (b 2)) (/ (+ a b) 1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
65
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
66 ;; coverage test
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
67 (let ((a 3) (b 2) (c 1.0)) (+))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
68 (let ((a 3) (b 2) (c 1.0)) (+ 2))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
69 (let ((a 3) (b 2) (c 1.0)) (+ 2 0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
70 (let ((a 3) (b 2) (c 1.0)) (+ 2 0.0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
71 (let ((a 3) (b 2) (c 1.0)) (+ 2.0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
72 (let ((a 3) (b 2) (c 1.0)) (+ 2.0 0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
73 (let ((a 3) (b 2) (c 1.0)) (+ 2.0 0.0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
74 (let ((a 3) (b 2) (c 1.0)) (+ 0 2))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
75 (let ((a 3) (b 2) (c 1.0)) (+ 0 2.0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
76 (let ((a 3) (b 2) (c 1.0)) (+ 0.0 2))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
77 (let ((a 3) (b 2) (c 1.0)) (+ 0.0 2.0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
78 (let ((a 3) (b 2) (c 1.0)) (+ a))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
79 (let ((a 3) (b 2) (c 1.0)) (+ a 0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
80 (let ((a 3) (b 2) (c 1.0)) (+ a 0.0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
81 (let ((a 3) (b 2) (c 1.0)) (+ 0 a))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
82 (let ((a 3) (b 2) (c 1.0)) (+ 0.0 a))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
83 (let ((a 3) (b 2) (c 1.0)) (+ c 0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
84 (let ((a 3) (b 2) (c 1.0)) (+ c 0.0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
85 (let ((a 3) (b 2) (c 1.0)) (+ 0 c))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
86 (let ((a 3) (b 2) (c 1.0)) (+ 0.0 c))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
87 (let ((a 3) (b 2) (c 1.0)) (+ a b 0 c 0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
88 (let ((a 3) (b 2) (c 1.0)) (+ 0 a))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
89 (let ((a 3) (b 2) (c 1.0)) (+ 0 a b))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
90 (let ((a 3) (b 2) (c 1.0)) (+ 0 a b c))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
91 (let ((a 3) (b 2) (c 1.0)) (+ 1 2 3))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
92 (let ((a 3) (b 2) (c 1.0)) (+ 3.0 2.0 1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
93 (let ((a 3) (b 2) (c 1.0)) (+ 3.0 2.0 1 4))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
94 (let ((a 3) (b 2) (c 1.0)) (+ a 1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
95 (let ((a 3) (b 2) (c 1.0)) (+ a -1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
96 (let ((a 3) (b 2) (c 1.0)) (+ 1 a))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
97 (let ((a 3) (b 2) (c 1.0)) (+ -1 a))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
98 (let ((a 3) (b 2) (c 1.0)) (+ c 1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
99 (let ((a 3) (b 2) (c 1.0)) (+ c -1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
100 (let ((a 3) (b 2) (c 1.0)) (+ 1 c))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
101 (let ((a 3) (b 2) (c 1.0)) (+ -1 c))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
102 (let ((a 3) (b 2) (c 1.0)) (+ a b 0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
103 (let ((a 3) (b 2) (c 1.0)) (+ a b 1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
104 (let ((a 3) (b 2) (c 1.0)) (+ a b -1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
105 (let ((a 3) (b 2) (c 1.0)) (+ a b 2))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
106 (let ((a 3) (b 2) (c 1.0)) (+ 1 a b c))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
107 (let ((a 3) (b 2) (c 1.0)) (+ a b c 0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
108 (let ((a 3) (b 2) (c 1.0)) (+ a b c 1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
109 (let ((a 3) (b 2) (c 1.0)) (+ a b c -1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
110
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
111 (let ((a 3) (b 2) (c 1.0)) (-))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
112 (let ((a 3) (b 2) (c 1.0)) (- 2))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
113 (let ((a 3) (b 2) (c 1.0)) (- 2 0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
114 (let ((a 3) (b 2) (c 1.0)) (- 2 0.0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
115 (let ((a 3) (b 2) (c 1.0)) (- 2.0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
116 (let ((a 3) (b 2) (c 1.0)) (- 2.0 0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
117 (let ((a 3) (b 2) (c 1.0)) (- 2.0 0.0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
118 (let ((a 3) (b 2) (c 1.0)) (- 0 2))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
119 (let ((a 3) (b 2) (c 1.0)) (- 0 2.0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
120 (let ((a 3) (b 2) (c 1.0)) (- 0.0 2))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
121 (let ((a 3) (b 2) (c 1.0)) (- 0.0 2.0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
122 (let ((a 3) (b 2) (c 1.0)) (- a))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
123 (let ((a 3) (b 2) (c 1.0)) (- a 0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
124 (let ((a 3) (b 2) (c 1.0)) (- a 0.0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
125 (let ((a 3) (b 2) (c 1.0)) (- 0 a))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
126 (let ((a 3) (b 2) (c 1.0)) (- 0.0 a))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
127 (let ((a 3) (b 2) (c 1.0)) (- c 0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
128 (let ((a 3) (b 2) (c 1.0)) (- c 0.0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
129 (let ((a 3) (b 2) (c 1.0)) (- 0 c))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
130 (let ((a 3) (b 2) (c 1.0)) (- 0.0 c))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
131 (let ((a 3) (b 2) (c 1.0)) (- a b 0 c 0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
132 (let ((a 3) (b 2) (c 1.0)) (- 0 a))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
133 (let ((a 3) (b 2) (c 1.0)) (- 0 a b))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
134 (let ((a 3) (b 2) (c 1.0)) (- 0 a b c))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
135 (let ((a 3) (b 2) (c 1.0)) (- 1 2 3))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
136 (let ((a 3) (b 2) (c 1.0)) (- 3.0 2.0 1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
137 (let ((a 3) (b 2) (c 1.0)) (- 3.0 2.0 1 4))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
138 (let ((a 3) (b 2) (c 1.0)) (- a 1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
139 (let ((a 3) (b 2) (c 1.0)) (- a -1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
140 (let ((a 3) (b 2) (c 1.0)) (- 1 a))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
141 (let ((a 3) (b 2) (c 1.0)) (- -1 a))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
142 (let ((a 3) (b 2) (c 1.0)) (- c 1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
143 (let ((a 3) (b 2) (c 1.0)) (- c -1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
144 (let ((a 3) (b 2) (c 1.0)) (- 1 c))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
145 (let ((a 3) (b 2) (c 1.0)) (- -1 c))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
146 (let ((a 3) (b 2) (c 1.0)) (- a b 0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
147 (let ((a 3) (b 2) (c 1.0)) (- a b 1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
148 (let ((a 3) (b 2) (c 1.0)) (- a b -1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
149 (let ((a 3) (b 2) (c 1.0)) (- a b 2))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
150 (let ((a 3) (b 2) (c 1.0)) (- 1 a b c))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
151 (let ((a 3) (b 2) (c 1.0)) (- a b c 0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
152 (let ((a 3) (b 2) (c 1.0)) (- a b c 1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
153 (let ((a 3) (b 2) (c 1.0)) (- a b c -1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
154
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
155 (let ((a 3) (b 2) (c 1.0)) (*))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
156 (let ((a 3) (b 2) (c 1.0)) (* 2))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
157 (let ((a 3) (b 2) (c 1.0)) (* 2 0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
158 (let ((a 3) (b 2) (c 1.0)) (* 2 0.0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
159 (let ((a 3) (b 2) (c 1.0)) (* 2.0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
160 (let ((a 3) (b 2) (c 1.0)) (* 2.0 0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
161 (let ((a 3) (b 2) (c 1.0)) (* 2.0 0.0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
162 (let ((a 3) (b 2) (c 1.0)) (* 0 2))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
163 (let ((a 3) (b 2) (c 1.0)) (* 0 2.0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
164 (let ((a 3) (b 2) (c 1.0)) (* 0.0 2))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
165 (let ((a 3) (b 2) (c 1.0)) (* 0.0 2.0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
166 (let ((a 3) (b 2) (c 1.0)) (* a))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
167 (let ((a 3) (b 2) (c 1.0)) (* a 0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
168 (let ((a 3) (b 2) (c 1.0)) (* a 0.0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
169 (let ((a 3) (b 2) (c 1.0)) (* 0 a))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
170 (let ((a 3) (b 2) (c 1.0)) (* 0.0 a))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
171 (let ((a 3) (b 2) (c 1.0)) (* c 0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
172 (let ((a 3) (b 2) (c 1.0)) (* c 0.0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
173 (let ((a 3) (b 2) (c 1.0)) (* 0 c))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
174 (let ((a 3) (b 2) (c 1.0)) (* 0.0 c))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
175 (let ((a 3) (b 2) (c 1.0)) (* a b 0 c 0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
176 (let ((a 3) (b 2) (c 1.0)) (* 0 a))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
177 (let ((a 3) (b 2) (c 1.0)) (* 0 a b))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
178 (let ((a 3) (b 2) (c 1.0)) (* 0 a b c))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
179 (let ((a 3) (b 2) (c 1.0)) (* 1 2 3))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
180 (let ((a 3) (b 2) (c 1.0)) (* 3.0 2.0 1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
181 (let ((a 3) (b 2) (c 1.0)) (* 3.0 2.0 1 4))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
182 (let ((a 3) (b 2) (c 1.0)) (* a 1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
183 (let ((a 3) (b 2) (c 1.0)) (* a -1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
184 (let ((a 3) (b 2) (c 1.0)) (* 1 a))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
185 (let ((a 3) (b 2) (c 1.0)) (* -1 a))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
186 (let ((a 3) (b 2) (c 1.0)) (* c 1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
187 (let ((a 3) (b 2) (c 1.0)) (* c -1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
188 (let ((a 3) (b 2) (c 1.0)) (* 1 c))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
189 (let ((a 3) (b 2) (c 1.0)) (* -1 c))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
190 (let ((a 3) (b 2) (c 1.0)) (* a b 0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
191 (let ((a 3) (b 2) (c 1.0)) (* a b 1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
192 (let ((a 3) (b 2) (c 1.0)) (* a b -1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
193 (let ((a 3) (b 2) (c 1.0)) (* a b 2))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
194 (let ((a 3) (b 2) (c 1.0)) (* 1 a b c))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
195 (let ((a 3) (b 2) (c 1.0)) (* a b c 0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
196 (let ((a 3) (b 2) (c 1.0)) (* a b c 1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
197 (let ((a 3) (b 2) (c 1.0)) (* a b c -1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
198
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
199 (let ((a 3) (b 2) (c 1.0)) (/))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
200 (let ((a 3) (b 2) (c 1.0)) (/ 2))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
201 (let ((a 3) (b 2) (c 1.0)) (/ 2 0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
202 (let ((a 3) (b 2) (c 1.0)) (/ 2 0.0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
203 (let ((a 3) (b 2) (c 1.0)) (/ 2.0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
204 (let ((a 3) (b 2) (c 1.0)) (/ 2.0 0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
205 (let ((a 3) (b 2) (c 1.0)) (/ 2.0 0.0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
206 (let ((a 3) (b 2) (c 1.0)) (/ 0 2))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
207 (let ((a 3) (b 2) (c 1.0)) (/ 0 2.0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
208 (let ((a 3) (b 2) (c 1.0)) (/ 0.0 2))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
209 (let ((a 3) (b 2) (c 1.0)) (/ 0.0 2.0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
210 (let ((a 3) (b 2) (c 1.0)) (/ a))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
211 (let ((a 3) (b 2) (c 1.0)) (/ a 0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
212 (let ((a 3) (b 2) (c 1.0)) (/ a 0.0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
213 (let ((a 3) (b 2) (c 1.0)) (/ 0 a))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
214 (let ((a 3) (b 2) (c 1.0)) (/ 0.0 a))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
215 (let ((a 3) (b 2) (c 1.0)) (/ c 0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
216 (let ((a 3) (b 2) (c 1.0)) (/ c 0.0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
217 (let ((a 3) (b 2) (c 1.0)) (/ 0 c))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
218 (let ((a 3) (b 2) (c 1.0)) (/ 0.0 c))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
219 (let ((a 3) (b 2) (c 1.0)) (/ a b 0 c 0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
220 (let ((a 3) (b 2) (c 1.0)) (/ 0 a))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
221 (let ((a 3) (b 2) (c 1.0)) (/ 0 a b))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
222 (let ((a 3) (b 2) (c 1.0)) (/ 0 a b c))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
223 (let ((a 3) (b 2) (c 1.0)) (/ 1 2 3))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
224 (let ((a 3) (b 2) (c 1.0)) (/ 3.0 2.0 1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
225 (let ((a 3) (b 2) (c 1.0)) (/ 3.0 2.0 1 4))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
226 (let ((a 3) (b 2) (c 1.0)) (/ a 1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
227 (let ((a 3) (b 2) (c 1.0)) (/ a -1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
228 (let ((a 3) (b 2) (c 1.0)) (/ 1 a))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
229 (let ((a 3) (b 2) (c 1.0)) (/ -1 a))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
230 (let ((a 3) (b 2) (c 1.0)) (/ c 1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
231 (let ((a 3) (b 2) (c 1.0)) (/ c -1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
232 (let ((a 3) (b 2) (c 1.0)) (/ 1 c))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
233 (let ((a 3) (b 2) (c 1.0)) (/ -1 c))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
234 (let ((a 3) (b 2) (c 1.0)) (/ a b 0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
235 (let ((a 3) (b 2) (c 1.0)) (/ a b 1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
236 (let ((a 3) (b 2) (c 1.0)) (/ a b -1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
237 (let ((a 3) (b 2) (c 1.0)) (/ a b 2))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
238 (let ((a 3) (b 2) (c 1.0)) (/ 1 a b c))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
239 (let ((a 3) (b 2) (c 1.0)) (/ a b c 0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
240 (let ((a 3) (b 2) (c 1.0)) (/ a b c 1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
241 (let ((a 3) (b 2) (c 1.0)) (/ a b c -1)))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
242 "List of expression for test.
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
243 Each element will be executed by interpreter and with
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
244 bytecompiled code, and their results are compared.")
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
245
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
246
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
247 (defun bytecomp-testsuite-run ()
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
248 "Run bytecomp test suite."
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
249 (interactive)
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
250 (with-output-to-temp-buffer "*bytecomp test*"
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
251 (byte-opt-testsuite--run-arith)
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
252 (message "All byte-opt tests finished successfully.")))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
253
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
254
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
255 (defun byte-opt-testsuite--run-arith (&optional arg)
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
256 "Unit test for byte-opt arithmetic operations.
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
257 Subtests signal errors if something goes wrong."
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
258 (interactive "P")
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
259 (let ((print-escape-nonascii t)
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
260 (print-escape-newlines t)
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
261 (print-quoted t)
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
262 v0 v1
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
263 indent-tabs-mode
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
264 (patterns byte-opt-testsuite-arith-data))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
265 (mapc
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
266 (lambda (pat)
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
267 (condition-case nil
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
268 (setq v0 (eval pat))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
269 (error (setq v0 nil)))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
270 (condition-case nil
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
271 (setq v1 (funcall (byte-compile (list 'lambda nil pat))))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
272 (error (setq v1 nil)))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
273 (princ (format "%s" pat))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
274 (if (equal v0 v1)
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
275 (princ (format " --> %s, OK\n" v1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
276 (princ (format " --> %s, NG\n" v0))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
277 (princ (format " --> %s\n" v1))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
278 (error "Arithmetic test failed!")))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
279 patterns)))
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
280
8b4be139c4a4 New file.
Chong Yidong <cyd@stupidchicken.com>
parents:
diff changeset
281 (provide 'byte-opt-testsuite)
100087
5b2580356bc3 Add arch tagline
Miles Bader <miles@gnu.org>
parents: 100068
diff changeset
282
5b2580356bc3 Add arch tagline
Miles Bader <miles@gnu.org>
parents: 100068
diff changeset
283 ;; arch-tag: 01cb2664-5e7f-4213-ace0-91447d70b7dc