【发布时间】:2013-05-10 10:18:14
【问题描述】:
我有一个链表
struct node {
data_t data;
node_t *next;
};
typedef struct {
node_t *head;
node_t *foot;
node_t *curr; // for iterator
unsigned int size;
} list_t;
有了这个结构,让我们说 我定义了一个列表
list_t* myList;
如何使用 GDB 打印整个链表?
【问题讨论】:
-
你可以写一个函数来打印列表并调用它stackoverflow.com/questions/1354731/…
标签: c++ debugging ubuntu data-structures gdb