ns-allinone-2.35/rap/raplist.cc
void List::Prepend(void *item)
{
  ListElement *element = new ListElement(item, 0);
  
  if (IsEmpty()) 
    {				// List is empty
      first = element;
      last = element;
    } 
  else 
    {				// else put it before first
      element->next = first;
      first = element;
    }

  size++;
}
//----------------------------------------------------------------------
// List::Prepend
//      Put an "item" on the front of the List.
//      
//	Allocate a ListElement to keep track of the item.
//      If the List is empty, then this will be the only element.
//	Otherwise, put it at the beginning.
//
//	"item" is the thing to put on the List, it can be a pointer to 
//		anything.
//----------------------------------------------------------------------
:Prepend
Put an "item" on the front of the List.

Allocate a ListElement to keep track of the item.
If the List is empty, then this will be the only element.
Otherwise, put it at the beginning.

"item" is the thing to put on the List, it can be a pointer to
anything.
: Prepend Put an " item " on the front of the List . Allocate a ListElement to keep track of the item . If the List is empty then this will be the only element . Otherwise put it at the beginning . " item " is the thing to put on the List it can be a pointer to anything .
void List::Prepend(void *item)
{
  ListElement *element = new ListElement(item, 0);
  if (IsEmpty()) 
    {				
      first = element;
      last = element;
    } 
  else 
    {				
      element->next = first;
      first = element;
    }
  size++;
}
void List :: Prepend ( void * item ) { ListElement * element = new ListElement ( item , 0 ) ; if ( IsEmpty ( ) ) { first = element ; last = element ; } else { element -> next = first ; first = element ; } size ++ ; }
List::Prepend
Put an "item" on the front of the List.
List :: Prepend Put an " item " on the front of the List .
// List is empty // else put it before first