This predicate is a more primitive version of copy_term/2 and does not imply a particular handling of attributed variables. Instead it copies the attributed variables as normal variables, and returns the AttrVars list as a means to define the copying of attributed variables separately. AttrVars is a list of pairs [<attributed variable>|<variable>] which maps the attributed variables in OldTerm to the corresponding fresh variables in NewTerm. By processing this list, the variables can be instantiated to whatever the user defines as the copy of the attributed variable.
Note that copy_term/2 is implemented as
copy_term(X, Y) :- copy_term(X, Y, Metas), apply_copy_term_handlers(Metas).
[eclipse 1]: set_flag(output_mode, "QPMV"). yes. [eclipse 3]: copy_term(s(a,X{a},Y, Z{b}), Copy, Metas). X = X_m234{a} Y = Y_g224 Z = Z_m212{b} Copy = s(a, _g282, Y_g288, _g292) Metas = [[Z_m212{b}|_g292], [X_m234{a}|_g282]] yes.