diff --git a/src/macros.lisp b/src/macros.lisp index fae82f5..0e9d9ca 100644 --- a/src/macros.lisp +++ b/src/macros.lisp @@ -134,7 +134,7 @@ CMBN-NON-ZERO-P Args: (cmbn) Tests if the combination CMBN is a non-null combination of any degree. ------------------------------------------------------------------------------" - `(cmbn-list ,cmbn)) + `(not (null (cmbn-list ,cmbn)))) (DEFMACRO CMBN-ZERO-P (cmbn) diff --git a/test/combinations-test.lisp b/test/combinations-test.lisp index c65e74b..c281e14 100644 --- a/test/combinations-test.lisp +++ b/test/combinations-test.lisp @@ -65,7 +65,7 @@ (is (equal (cat:cmbn-list comb) nil))) (is (null (cat:cmbn-non-zero-p (cat:cmbn 0)))) - (is (equal (cat:cmbn-non-zero-p (cat:cmbn 0 1 'a)) '((1 . a)))) + (is (cat:cmbn-non-zero-p (cat:cmbn 0 1 'a))) (is (cat:cmbn-zero-p (cat:cmbn 0))) (is (null (cat:cmbn-zero-p (cat:cmbn 0 1 'a)))))