|
From: <net...@us...> - 2003-12-16 13:24:23
|
Update of /cvsroot/cpptool/rfta/src/rftaparser
In directory sc8-pr-cvs1:/tmp/cvs-serv24992/rfta/src/rftaparser
Modified Files:
NonSemanticBlanker.cpp
Log Message:
-- small interface change for blanker
-- comments
Index: NonSemanticBlanker.cpp
===================================================================
RCS file: /cvsroot/cpptool/rfta/src/rftaparser/NonSemanticBlanker.cpp,v
retrieving revision 1.6
retrieving revision 1.7
diff -C2 -d -r1.6 -r1.7
*** NonSemanticBlanker.cpp 8 Nov 2002 07:46:49 -0000 1.6
--- NonSemanticBlanker.cpp 16 Dec 2003 13:24:20 -0000 1.7
***************
*** 7,11 ****
NonSemanticBlanker::NonSemanticBlanker( const std::string &textToBlank,
std::string &blanked,
! PPDirectiveListener &ppDirectiveParser )
: blanked_( blanked )
, ppDirectiveParser_( ppDirectiveParser )
--- 7,11 ----
NonSemanticBlanker::NonSemanticBlanker( const std::string &textToBlank,
std::string &blanked,
! PPDirectiveListenerPtr ppDirectiveParser )
: blanked_( blanked )
, ppDirectiveParser_( ppDirectiveParser )
***************
*** 118,122 ****
}
! ppDirectiveParser_.parseDirective( start, current );
int length = current - start;
--- 118,122 ----
}
! ppDirectiveParser_->parseDirective( start, current );
int length = current - start;
***************
*** 146,150 ****
}
else
! blanksStringsAndPreprocessorDirectives();
}
}
--- 146,150 ----
}
else
! blanksStringsAndPreprocessorDirectives();
}
}
***************
*** 154,189 ****
NonSemanticBlanker::blanksStringsAndPreprocessorDirectives( )
{
! char c(*current_);
switch ( c )
! {
! case ' ':
! ++current_;
! break;
! case '\t':
! blanked_[ current_++ - textStart_ ] = ' ';
! break;
! case '\n':
! case '\r':
! current_ = blanksNewLine( current_ );
! newLine_ = true;
! break;
! case '"':
! current_ = blanksString( current_, '"' );
! break;
! case '\'':
! current_ = blanksString( current_, '\'' );
! break;
! case '#':
! if ( newLine_ )
! {
! current_ = blanksPreprocessorDirective( current_ );
! break;
! }
! // missing break, this is correct
! default:
! newLine_ = false;
! ++current_;
! break;
! }
}
--- 154,189 ----
NonSemanticBlanker::blanksStringsAndPreprocessorDirectives( )
{
! char c(*current_);
switch ( c )
! {
! case ' ':
! ++current_;
! break;
! case '\t':
! blanked_[ current_++ - textStart_ ] = ' ';
! break;
! case '\n':
! case '\r':
! current_ = blanksNewLine( current_ );
! newLine_ = true;
! break;
! case '"':
! current_ = blanksString( current_, '"' );
! break;
! case '\'':
! current_ = blanksString( current_, '\'' );
! break;
! case '#':
! if ( newLine_ )
! {
! current_ = blanksPreprocessorDirective( current_ );
! break;
! }
! // missing break, this is correct
! default:
! newLine_ = false;
! ++current_;
! break;
! }
}
|