回复 2楼 succubus
我换了一下,可是错的更多!
e:\二叉树程序\bitreetraverse.h(1) : error C2065: 'BiTreeNode' : undeclared identifier
e:\二叉树程序\bitreetraverse.h(1) : error C2065: 't' : undeclared identifier
e:\二叉树程序\bitreetraverse.h(1) : error C2062: type 'void' unexpected
e:\二叉树程序\bitreetraverse.h(2) : error C2143: syntax error : missing ';' before '{'
e:\二叉树程序\bitreetraverse.h(2) : error C2447: missing function header (old-style formal list?)
e:\二叉树程序\bitreetraverse.h(10) : error C2062: type 'void' unexpected
e:\二叉树程序\bitreetraverse.h(11) : error C2143: syntax error : missing ';' before '{'
e:\二叉树程序\bitreetraverse.h(11) : error C2447: missing function header (old-style formal list?)
e:\二叉树程序\bitreetraverse.h(19) : error C2062: type 'void' unexpected
e:\二叉树程序\bitreetraverse.h(20) : error C2143: syntax error : missing ';' before '{'
e:\二叉树程序\bitreetraverse.h(20) : error C2447: missing function header (old-style formal list?)
e:\二叉树程序\bitreetraverse.h(28) : error C2065: 'root' : undeclared identifier
e:\二叉树程序\bitreetraverse.h(28) : error C2100: illegal indirection
e:\二叉树程序\bitreetraverse.h(29) : error C2448: '<Unknown>' : function-style initializer appears to be a function definition
e:\二叉树程序\bitree.h(6) : error C2378: 'BiTreeNode' : redefinition; symbol cannot be overloaded with a typedef
e:\二叉树程序\bitree.h(7) : error C2100: illegal indirection
e:\二叉树程序\bitree.h(8) : error C2448: '<Unknown>' : function-style initializer appears to be a function definition
e:\二叉树程序\bitree.h(13) : error C2143: syntax error : missing ';' before '*'
e:\二叉树程序\bitree.h(13) : error C2501: 'BiTreeNode' : missing storage-class or type specifiers
e:\二叉树程序\bitree.h(13) : error C2061: syntax error : identifier 'BiTreeNode'
e:\二叉树程序\bitree.h(14) : error C2501: 'InsertLeftNode' : missing storage-class or type specifiers
e:\二叉树程序\bitree.h(15) : error C2065: 's' : undeclared identifier
e:\二叉树程序\bitree.h(15) : error C2100: illegal indirection
e:\二叉树程序\bitree.h(16) : error C2065: 'curr' : undeclared identifier
e:\二叉树程序\bitree.h(17) : error C2227: left of '->leftChild' must point to class/struct/union
e:\二叉树程序\bitree.h(18) : error C2059: syntax error : ')'
e:\二叉树程序\bitree.h(19) : error C2227: left of '->data' must point to class/struct/union
e:\二叉树程序\bitree.h(19) : error C2065: 'x' : undeclared identifier
e:\二叉树程序\bitree.h(20) : error C2227: left of '->leftChild' must point to class/struct/union
e:\二叉树程序\bitree.h(21) : error C2227: left of '->rightChild' must point to class/struct/union
e:\二叉树程序\bitree.h(22) : error C2227: left of '->leftChild' must point to class/struct/union
e:\二叉树程序\bitree.h(23) : error C2227: left of '->leftChild' must point to class/struct/union
e:\二叉树程序\bitree.h(23) : error C2617: 'InsertLeftNode' : inconsistent return statement
e:\二叉树程序\bitree.h(13) : see declaration of 'InsertLeftNode'
e:\二叉树程序\bitree.h(25) : error C2143: syntax error : missing ';' before '*'
e:\二叉树程序\bitree.h(25) : error C2501: 'BiTreeNode' : missing storage-class or type specifiers
e:\二叉树程序\bitree.h(25) : error C2086: 'BiTreeNode' : redefinition
e:\二叉树程序\bitree.h(25) : error C2061: syntax error : identifier 'BiTreeNode'
e:\二叉树程序\bitree.h(26) : error C2501: 'InsertRightNode' : missing storage-class or type specifiers
e:\二叉树程序\bitree.h(27) : error C2100: illegal indirection
e:\二叉树程序\bitree.h(29) : error C2227: left of '->rightChild' must point to class/struct/union
e:\二叉树程序\bitree.h(30) : error C2059: syntax error : ')'
e:\二叉树程序\bitree.h(31) : error C2227: left of '->data' must point to class/struct/union
e:\二叉树程序\bitree.h(32) : error C2227: left of '->rightChild' must point to class/struct/union
e:\二叉树程序\bitree.h(33) : error C2227: left of '->leftChild' must point to class/struct/union
e:\二叉树程序\bitree.h(34) : error C2227: left of '->rightChild' must point to class/struct/union
e:\二叉树程序\bitree.h(35) : error C2227: left of '->rightChild' must point to class/struct/union
e:\二叉树程序\bitree.h(35) : error C2617: 'InsertRightNode' : inconsistent return statement
e:\二叉树程序\bitree.h(25) : see declaration of 'InsertRightNode'
e:\二叉树程序\bitree.h(38) : error C2143: syntax error : missing ';' before '*'
e:\二叉树程序\bitree.h(38) : error C2501: 'BiTreeNode' : missing storage-class or type specifiers
e:\二叉树程序\bitree.h(38) : error C2086: 'BiTreeNode' : redefinition
e:\二叉树程序\bitree.h(38) : error C2061: syntax error : identifier 'BiTreeNode'
e:\二叉树程序\bitree.h(39) : error C2501: 'DeleteLeftTree' : missing storage-class or type specifiers
e:\二叉树程序\bitree.h(40) : error C2227: left of '->leftChild' must point to class/struct/union
e:\二叉树程序\bitree.h(41) : error C2065: 'Destroy' : undeclared identifier
e:\二叉树程序\bitree.h(41) : error C2227: left of '->leftChild' must point to class/struct/union
e:\二叉树程序\bitree.h(42) : error C2227: left of '->leftChild' must point to class/struct/union
e:\二叉树程序\bitree.h(45) : error C2143: syntax error : missing ';' before '*'
e:\二叉树程序\bitree.h(45) : error C2501: 'BiTreeNode' : missing storage-class or type specifiers
e:\二叉树程序\bitree.h(45) : error C2086: 'BiTreeNode' : redefinition
e:\二叉树程序\bitree.h(45) : error C2061: syntax error : identifier 'BiTreeNode'
e:\二叉树程序\bitree.h(46) : error C2501: 'DeleteRightTree' : missing storage-class or type specifiers
e:\二叉树程序\bitree.h(47) : error C2227: left of '->rightChild' must point to class/struct/union
e:\二叉树程序\bitree.h(48) : error C2227: left of '->rightChild' must point to class/struct/union
e:\二叉树程序\bitree.h(49) : error C2227: left of '->rightChild' must point to class/struct/union
E:\二叉树程序\bitree.cpp(11) : error C2065: 'bt' : undeclared identifier
E:\二叉树程序\bitree.cpp(11) : error C2062: type 'int' unexpected
E:\二叉树程序\bitree.cpp(12) : error C2143: syntax error : missing ';' before '{'
E:\二叉树程序\bitree.cpp(12) : error C2447: missing function header (old-style formal list?)
E:\二叉树程序\bitree.cpp(26) : error C2065: 'p' : undeclared identifier
E:\二叉树程序\bitree.cpp(26) : error C2100: illegal indirection
E:\二叉树程序\bitree.cpp(26) : error C2065: 'pp' : undeclared identifier
E:\二叉树程序\bitree.cpp(26) : error C2100: illegal indirection
E:\二叉树程序\bitree.cpp(27) : error C2065: 'Initiate' : undeclared identifier
E:\二叉树程序\bitree.cpp(32) : error C2227: left of '->leftChild' must point to class/struct/union
E:\二叉树程序\bitree.cpp(32) : error C2660: 'InsertRightNode' : function does not take 2 parameters
E:\二叉树程序\bitree.cpp(36) : error C2065: 'PrintBiTree' : undeclared identifier
E:\二叉树程序\bitree.cpp(38) : error C2065: 'PreOrder' : undeclared identifier
E:\二叉树程序\bitree.cpp(38) : error C2227: left of '->leftChild' must point to class/struct/union
E:\二叉树程序\bitree.cpp(40) : error C2065: 'InOrder' : undeclared identifier
E:\二叉树程序\bitree.cpp(40) : error C2227: left of '->leftChild' must point to class/struct/union
E:\二叉树程序\bitree.cpp(42) : error C2065: 'PostOrder' : undeclared identifier
E:\二叉树程序\bitree.cpp(42) : error C2227: left of '->leftChild' must point to class/struct/union
执行 cl.exe 时出错.