272 {
274 {
275 *this = anotherMonom;
276 }
277 else
278 {
279 if (anotherMonom.ListHead)
280 {
282 *anotherIterator = anotherMonom.ListHead;
283
284 while (*iterator && anotherIterator)
285 {
286 if ((*iterator)->Value == anotherIterator->Value)
287 {
288 iterator = &((*iterator)->Next);
289 anotherIterator = anotherIterator->Next;
290 }
291 else if ((*iterator)->Value > anotherIterator->Value)
292 {
293 iterator = &((*iterator)->Next);
294 }
295 else
296 {
298 newNode->Value = anotherIterator->Value;
299 newNode->Next = *iterator;
300 *iterator = newNode;
302
303 iterator = &(newNode->Next);
304 anotherIterator = anotherIterator->Next;
305 }
306 }
307
308 while (anotherIterator)
309 {
311 (*iterator)->Value = anotherIterator->Value;
313
314 iterator = &((*iterator)->Next);
315 anotherIterator = anotherIterator->Next;
316 }
317 }
318 }
319
320 return *this;
321 }
Singly linked-list node of a Monom's variable list, with a per-class slab allocator.