public override Literal MakeVarsAnnon(Unifier un) { if (annotations != null) { IListTerm lt = annotations; while (!(lt.Count == 0)) { ITerm ta = lt.GetTerm(); if (ta.IsVar()) { lt.SetTerm(VarToReplace(ta, un)); } else if (ta.GetType() == typeof(Structure)) { ((Structure)ta).MakeVarsAnnon(un); } if (lt.IsTail() && lt.GetNext().IsVar()) { lt.SetNext(VarToReplace(lt.GetNext(), un)); break; } lt = lt.GetNext(); } } return(base.MakeVarsAnnon(un)); }
public void Dispose() { if (current != null && nextLT != null) { current.SetTerm(nextLT.GetTerm()); current.SetNext(nextLT.GetNext()); nextLT = current; } }