<< Back to previous view

[LOGIC-69] prep does not properly recurse terms Created: 19/Nov/12  Updated: 28/Jul/13  Resolved: 21/Nov/12

Status: Closed
Project: core.logic
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Defect Priority: Major
Reporter: David Nolen Assignee: David Nolen
Resolution: Completed Votes: 0
Labels: None

Attachments: Text File logic69.patch     Text File logic69.patch    
Patch: Code and Test

(prep {:a {:b ?c} :d ?d})

?c is not walked according to Kevin Lynagh. This should also handle complex map keys.

Comment by Kevin Lynagh [ 21/Nov/12 12:09 AM ]

Also available here: https://github.com/lynaghk/core.logic/tree/walk-recursive

Comment by Kevin Lynagh [ 21/Nov/12 12:13 AM ]

This patch adds prewalk recursion to IWalkTerm for map/record keys and values, seqs, and vectors.
Note that logic vars within map keys isn't going to unify in the current implementation, and probably isn't a sensible thing to do anyway. Prewalk of map keys is just so that people can use core.logic's walk implementation over clojure.walk to use the IUninitialized protocol.

Comment by Kevin Lynagh [ 21/Nov/12 12:17 AM ]

(Patch updated to walk map keys. I couldn't figure out how to remove old patch in JIRA.)

Comment by David Nolen [ 21/Nov/12 8:57 AM ]

fixed, http://github.com/clojure/core.logic/commit/bd65104ec3fda79790655d4be8a9be436f2c0d54

Generated at Tue Jan 16 01:44:44 CST 2018 using JIRA 4.4#649-r158309.