solveForCaller

fun Solver.solveForCaller(goal: Struct, options: SolveOptions): Sequence<Solution>

Solves goal on behalf of a primitive, whose caller needs the bindings of all the variables of the goal.

The solutions of a query only bind its variables with a name, as for a query typed by a user: the bindings of the anonymous and wildcard ones (_, _Name), which are the caller's variables as much as the others, would be lost (and with them, for instance, the bindings a module makes inside the terms it is given). They are renamed for the query, and bound back in each solution.