From: Baptiste L. <bl...@us...> - 2004-08-18 20:55:57
|
Update of /cvsroot/cpptool/CppParser/src/pycppparser In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv8517 Modified Files: node.cpp Log Message: * optimized node loading Index: node.cpp =================================================================== RCS file: /cvsroot/cpptool/CppParser/src/pycppparser/node.cpp,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** node.cpp 18 Aug 2004 19:05:59 -0000 1.2 --- node.cpp 18 Aug 2004 20:55:48 -0000 1.3 *************** *** 70,75 **** list childrenState = extract<list>( state[1] ); int childrenCount = len( childrenState ); for ( int index = 0; index < childrenCount; ++index ) ! node.appendChild( extract<Parser::NodePtr>( childrenState[index] ) ); } }; --- 70,78 ---- list childrenState = extract<list>( state[1] ); int childrenCount = len( childrenState ); + Parser::Nodes nodes; for ( int index = 0; index < childrenCount; ++index ) ! nodes.push_back( extract<Parser::NodePtr>( childrenState[index] ) ); ! ! node.setChildren( nodes ); } }; |