summaryrefslogtreecommitdiff
path: root/test/src/data-tests.el
diff options
context:
space:
mode:
authorTom Tromey <tom@tromey.com>2018-07-07 14:22:44 -0600
committerTom Tromey <tom@tromey.com>2018-07-12 22:12:27 -0600
commita770fb44288c75fa2b0471ceaf00bf741376e40f (patch)
tree263136cf11b50104797d7642247b87fab2814ded /test/src/data-tests.el
parentc7e393bc4130c871a92fef7e9ac0c7c1832aa614 (diff)
downloademacs-a770fb44288c75fa2b0471ceaf00bf741376e40f.tar.gz
Make logcount handle bignums
* src/data.c (Flogcount): Handle bignums. * test/src/data-tests.el (data-tests-logcount): New test.
Diffstat (limited to 'test/src/data-tests.el')
-rw-r--r--test/src/data-tests.el3
1 files changed, 3 insertions, 0 deletions
diff --git a/test/src/data-tests.el b/test/src/data-tests.el
index dd6ce196f96..561b7bd9ca6 100644
--- a/test/src/data-tests.el
+++ b/test/src/data-tests.el
@@ -587,4 +587,7 @@ comparing the subr with a much slower lisp implementation."
(should (< (1- most-negative-fixnum) most-negative-fixnum))
(should (fixnump (1- (1+ most-positive-fixnum)))))
+(ert-deftest data-tests-logcount ()
+ (should (= (logcount (read "#xffffffffffffffffffffffffffffffff")) 128)))
+
;;; data-tests.el ends here