From: <bl...@us...> - 2003-04-26 21:13:39
|
Update of /cvsroot/cpptool/rfta/src/rftaparser In directory sc8-pr-cvs1:/tmp/cvs-serv10364/src/rftaparser Modified Files: rftaparser.dsp Added Files: CPPParser.cpp Log Message: * added CPPParser, interface to the rftaparser library --- NEW FILE: CPPParser.cpp --- #include "stdafx.h" #include <rfta/parser/CPPParser.h> #include <rfta/parser/NonSemanticBlanker.h> #include <rfta/parser/MaxLODMutator.h> #include <rfta/parser/DeclarationListParser.h> #include <rfta/parser/ParseContext.h> #include <rfta/parser/ParserError.h> namespace Refactoring { CPPParser::CPPParser( const std::string &source ) { NullPPDirectiveListener nullListener; std::string blankedSource; NonSemanticBlanker blanker( source, blankedSource, nullListener ); blanker.blank(); sourceNode_ = SourceASTNode::create( blankedSource, source ); } SourceASTNodePtr CPPParser::getSourceNode() const { return sourceNode_; } void CPPParser::parseForFunctionBodyAt( int position ) { } void CPPParser::parseForFunctionDeclarations() { } void CPPParser::parseAll() { ParseContext context( sourceNode_ ); DeclarationListParser parser( context, sourceNode_->getBlankedSourceStart(), sourceNode_->getBlankedSourceEnd() ); try { if ( !parser.tryParse() ) { } // should report error in some way... MaxLODMutator mutator; mutator.mutate( sourceNode_, sourceNode_ ); } catch ( ParserError & ) { // should report error in some way... } } } // namespace Refactoring Index: rftaparser.dsp =================================================================== RCS file: /cvsroot/cpptool/rfta/src/rftaparser/rftaparser.dsp,v retrieving revision 1.39 retrieving revision 1.40 diff -C2 -d -r1.39 -r1.40 *** rftaparser.dsp 26 Apr 2003 13:13:37 -0000 1.39 --- rftaparser.dsp 26 Apr 2003 21:13:35 -0000 1.40 *************** *** 130,133 **** --- 130,137 ---- # Begin Source File + SOURCE=..\..\include\xtl\Forwards.h + # End Source File + # Begin Source File + SOURCE=..\..\include\xtl\IntrusiveCount.h # End Source File *************** *** 1304,1307 **** --- 1308,1323 ---- SOURCE=..\..\deplib\boostcvs\libs\filesystem\src\path_posix_windows.cpp # SUBTRACT CPP /YX /Yc /Yu + # End Source File + # End Group + # Begin Group "Interface" + + # PROP Default_Filter "" + # Begin Source File + + SOURCE=.\CPPParser.cpp + # End Source File + # Begin Source File + + SOURCE=..\..\include\rfta\parser\CPPParser.h # End Source File # End Group |