Unification persistent data structure
Open
- Dominant language
- Go
- Stars
- 3k
- Forks
- 157
- PR merge metrics
- No merged PRs in 30d
Description
Hello,
what does the comment mean here? you want a persistent map instead of allocating one each time?
```Go
// Not a built-in predicate. Call lookupFn.
lookupFn(p, func(fact ast.Atom) error {
// TODO: This could be made a lot more efficient by using a persistent
// data structure for composing the unionfind substitutions.
if newSubst, err := unionfind.UnifyTermsExtend(p.Args, fact.Args, subst); err == nil {
solutions = append(solutions, newSubst)
}
return nil
})
return solutions, nil
```
Contributor guide
Assessment
This issue has not been assessed yet.