Update of /cvsroot/cpptool/rfta/src/rftaparser
In directory sc8-pr-cvs1:/tmp/cvs-serv5073/rfta/src/rftaparser
Modified Files:
UnparsedDeclaratorMutatorTest.cpp
Log Message:
-- declarator mutator splits scope identifier
Index: UnparsedDeclaratorMutatorTest.cpp
===================================================================
RCS file: /cvsroot/cpptool/rfta/src/rftaparser/UnparsedDeclaratorMutatorTest.cpp,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** UnparsedDeclaratorMutatorTest.cpp 6 Sep 2003 21:34:00 -0000 1.1
--- UnparsedDeclaratorMutatorTest.cpp 15 Sep 2003 09:13:31 -0000 1.2
***************
*** 123,128 ****
{
Testing::KeyedString source;
! source << "((*";
! source.addKeyed("IDENT","::hello") << ") const = 0";
SourceASTNodePtr sourceAST = RFTA_ASSERT_DECLARATOR_MUTATOR_PASS( source );
--- 123,128 ----
{
Testing::KeyedString source;
! source << "((* ::";
! source.addKeyed("IDENT","hello") << ") const = 0";
SourceASTNodePtr sourceAST = RFTA_ASSERT_DECLARATOR_MUTATOR_PASS( source );
***************
*** 146,150 ****
Testing::KeyedString source;
source << "((*";
! source.addKeyed("IDENT","hello::hello2::hello3") << ") const = 0";
SourceASTNodePtr sourceAST = RFTA_ASSERT_DECLARATOR_MUTATOR_PASS( source );
--- 146,153 ----
Testing::KeyedString source;
source << "((*";
! // declaration: "hello::hello2::hello3" (three identifiers will be registered !)
! source.addKeyed("IDENT1","hello") << "::";
! source.addKeyed("IDENT2","hello2") << "::";
! source.addKeyed("IDENT3","hello3") << ") const = 0";
SourceASTNodePtr sourceAST = RFTA_ASSERT_DECLARATOR_MUTATOR_PASS( source );
***************
*** 155,164 ****
0,
source.length() );
! RFTA_ASSERT_EQUAL( 1, node->getChildCount() );
RFTA_ASSERT_NODE_HAS( node->getChildAt(0),
ASTNodeTypes::localScopeIdentifier,
! source.getKeyedIndex("IDENT",0),
! source.getKeyedLen ("IDENT",0) );
}
--- 158,175 ----
0,
source.length() );
! RFTA_ASSERT_EQUAL( 3, node->getChildCount() );
RFTA_ASSERT_NODE_HAS( node->getChildAt(0),
ASTNodeTypes::localScopeIdentifier,
! source.getKeyedIndex("IDENT1",0),
! source.getKeyedLen ("IDENT1",0) );
! RFTA_ASSERT_NODE_HAS( node->getChildAt(1),
! ASTNodeTypes::localScopeIdentifier,
! source.getKeyedIndex("IDENT2",0),
! source.getKeyedLen ("IDENT2",0) );
! RFTA_ASSERT_NODE_HAS( node->getChildAt(2),
! ASTNodeTypes::localScopeIdentifier,
! source.getKeyedIndex("IDENT3",0),
! source.getKeyedLen ("IDENT3",0) );
}
|