[LOGIC-138] Allow tying multiple noms in one binder Created: 10/Jun/13 Updated: 10/Jun/13
|Reporter:||Tom Jack||Assignee:||David Nolen|
I think it may be useful to be able to tie multiple noms in one binder, with or without significant order.
A couple use cases I've thought of so far:
Lambdas in a non-currying language. Here order matters.
My original use case, free/quantified variables in logical formulas. Order doesn't matter (note the second body has its noms swapped).
I have a draft implementation here: https://github.com/tomjack/core.logic/compare/ties
Possible issues with this implementation:
|Comment by David Nolen [ 10/Jun/13 3:37 PM ]|
I really don't think the set bit is necessary, the vector syntax is fine. Also avoid needing to bring IWalkTerm back for sets. And yes, tie? should work in either case.
|Comment by Tom Jack [ 10/Jun/13 3:55 PM ]|
I'd think not.
Do you mean that order should always matter (take out the permutations stuff), or that it should never matter (don't use ties for cases like the above)?
|Comment by David Nolen [ 10/Jun/13 4:07 PM ]|
Ah hm, good point. Will think on it some more.