[racket] cKanren question

From: Kevin Forchione (lysseus at gmail.com)
Date: Fri Nov 28 19:17:44 EST 2014

Why does cKanren return ‘() instead of ‘(#f), which is what The Reasoned Schemer seems to expect, for the following?

#lang racket

(require cKanren/miniKanren)

#;(run #f (q) fail)
(run #f (q) (== #t q))
#;(run #f (q) fail (== #t q))
#;(run #f (q) succeed (== #t q))
#;(run #f (r) succeed (== 'corn r))
#;(run #f (r) fail (== 'corn r))
(run #f (q) succeed (== #f q))

I get ‘(#t) for (run #f (q) succeed (== #t q)) which is what I’d expect. But running the above program only returns ‘() when unifying q with #f. 

Thaks!

-Kevin

Posted on the users mailing list.