summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVibhav Pant <vibhavp@gmail.com>2017-04-22 21:51:43 +0530
committerVibhav Pant <vibhavp@gmail.com>2017-04-22 22:08:16 +0530
commit66dc8dd6d13d37ef23b52873293d95d87dca497f (patch)
tree60b9174b9848ee38f7554b45e585cf5dda376cdf
parent1c91bc9221d12618c9fb5507561dd35b7e392cb6 (diff)
downloademacs-66dc8dd6d13d37ef23b52873293d95d87dca497f.tar.gz
Add cond test cases for singleton clauses.
* test/lisp/emacs-lisp/bytecomp-tests.el: Add test cond forms where the default clause is a single non-nil expression.
-rw-r--r--test/lisp/emacs-lisp/bytecomp-tests.el8
1 files changed, 7 insertions, 1 deletions
diff --git a/test/lisp/emacs-lisp/bytecomp-tests.el b/test/lisp/emacs-lisp/bytecomp-tests.el
index d0b97907389..e8feec31d26 100644
--- a/test/lisp/emacs-lisp/bytecomp-tests.el
+++ b/test/lisp/emacs-lisp/bytecomp-tests.el
@@ -280,7 +280,13 @@
(while l
a (setq l nil))
'correct)
- (t 'incorrect))))
+ (t 'incorrect)))
+ (let ((a))
+ (cond ((eq a 'foo) 'incorrect)
+ (t)))
+ (let ((a))
+ (cond ((eq a 'foo) 'incorrect)
+ ('correct))))
"List of expression for test.
Each element will be executed by interpreter and with
bytecompiled code, and their results compared.")