diff options
| author | Tom Tromey | 2018-07-07 14:22:44 -0600 |
|---|---|---|
| committer | Tom Tromey | 2018-07-12 22:12:27 -0600 |
| commit | a770fb44288c75fa2b0471ceaf00bf741376e40f (patch) | |
| tree | 263136cf11b50104797d7642247b87fab2814ded /test/src/data-tests.el | |
| parent | c7e393bc4130c871a92fef7e9ac0c7c1832aa614 (diff) | |
| download | emacs-a770fb44288c75fa2b0471ceaf00bf741376e40f.tar.gz emacs-a770fb44288c75fa2b0471ceaf00bf741376e40f.zip | |
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.el | 3 |
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." | |||
| 587 | (should (< (1- most-negative-fixnum) most-negative-fixnum)) | 587 | (should (< (1- most-negative-fixnum) most-negative-fixnum)) |
| 588 | (should (fixnump (1- (1+ most-positive-fixnum))))) | 588 | (should (fixnump (1- (1+ most-positive-fixnum))))) |
| 589 | 589 | ||
| 590 | (ert-deftest data-tests-logcount () | ||
| 591 | (should (= (logcount (read "#xffffffffffffffffffffffffffffffff")) 128))) | ||
| 592 | |||
| 590 | ;;; data-tests.el ends here | 593 | ;;; data-tests.el ends here |