4.3.6 Get first value

This operation is invalid if a list is empty. Otherwise, the firstvalue of the list node pointed to by first is returned. Without error checking, the implementation is as follows:

char List_getfirstvalue(struct List *pList)
{
  return ((struct _List *)pList)->first->firstvalue;
}



Copyright © 2006-09-27 by Tak Auyeung