| 772 | |
| 773 | |
| 774 | void list::format_print(ofstream& output) const |
| 775 | { |
| 776 | |
| 777 | #ifdef DL_LIST |
| 778 | |
| 779 | element* iter=start->next; |
| 780 | |
| 781 | #endif // DL_LIST |
| 782 | |
| 783 | #ifdef SL_LIST |
| 784 | |
| 785 | element *iter=start; |
| 786 | |
| 787 | #endif // SL_LIST |
| 788 | |
| 789 | if(iter==NULL) |
| 790 | { |
| 791 | cerr<<"\nWARNING: void list::print(ofstream&) const:\n" |
| 792 | "cannot print corrupt list"<<endl; |
| 793 | output<<"\nWARNING: void list::print(oftream&) const:\ncannot print " |
| 794 | "corrupt list"<<endl; |
| 795 | return; |
| 796 | } |
| 797 | |
| 798 | while(iter->next!=NULL) |
| 799 | { |
| 800 | iter->entry->format_print(output); |
| 801 | iter=iter->next; |
| 802 | } |
| 803 | } |
| 804 | |
| 805 | |
| 806 |
no outgoing calls
no test coverage detected