tie disequality

Description

(deftest test-tie-disequality (is (= (run* [q] (nom/fresh [a b] (!= (nom/tie a a) 'hello))) '(_0))) (is (= (run* [q] (nom/fresh [a b] (!= (nom/tie a a) (nom/tie b b)))) ())))

Currently, the first causes an error, because IPersistentMap (which gets called because Tie is a record!) assumes that the the other term is also a record (that seems like a bug). If we revert the commit which makes Tie a record, this works.

The other one succeeds, when it should fail. This is regardless of whether Tie is a record or not.

Environment

None

Activity

Show:

Nada AminMarch 12, 2013 at 11:52 AM

quick fix in https://github.com/clojure/core.logic/commit/8af0f45f8d1cb515ec7a00e5acd751562a31bb37

for actually doing != modulo alpha equivalence requires the opposite of nom/hash.

Details

Assignee

Reporter

Priority

Created March 12, 2013 at 11:37 AM
Updated March 12, 2013 at 11:52 AM