687 size_t index |
687 size_t index |
688 ) { |
688 ) { |
689 return list->cl->at(list, index); |
689 return list->cl->at(list, index); |
690 } |
690 } |
691 |
691 |
|
692 |
|
693 /** |
|
694 * Sets the element at the specified index in the list |
|
695 * |
|
696 * @param list the list to set the element in |
|
697 * @param index the index to set the element at |
|
698 * @param elem element to set |
|
699 * @retval zero on success |
|
700 * @retval non-zero when index is out of bounds |
|
701 */ |
|
702 cx_attr_nonnull |
|
703 int cxListSet( |
|
704 CxList *list, |
|
705 size_t index, |
|
706 const void *elem |
|
707 ); |
|
708 |
692 /** |
709 /** |
693 * Returns an iterator pointing to the item at the specified index. |
710 * Returns an iterator pointing to the item at the specified index. |
694 * |
711 * |
695 * The returned iterator is position-aware. |
712 * The returned iterator is position-aware. |
696 * |
713 * |