我对以下代码有疑问,
我有一个功能如下,
void deleteNode(struct myList ** root)
{
struct myList *temp;
temp = *root;
...//some conditions here
*root = *root->link; //this line gives an error
*root = temp->link; //this doesnt give any error
}
那么这两行有什么区别,对我来说看起来一样..错误是,
error #2112: Left operand of '->' has incompatible type 'struct myList * *'
谢谢 :)