comparator in IS macro not evaluated
dkochmanski opened this issue · comments
Daniel Kochmanski commented
It is a subject of autoquoting, i.e
(is = 3 (+ 1 2))
(is (lambda (a b) (= a b)) 3 (+ 1 2))
but that does not work well with expressions that evaluate to a function, i.e
(is (rcurry #'member :test 'equalp) '(1 2 3) (iota 1 3))
autoquoting is a matter of fact, so requiring now to write
(is '= 3 (+ 1 2))
will break existing tests, so perhaps the comparator should be evaluated only when it is not an atom?
Yukari Hafner commented
I don't remember all the ways the autoquoting is used, but that sounds like the most sensible solution, yeah. I'll try to look into it.