Changes in src/Parser/ExpressionNode.cc [0213af6:fbcde64]
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/Parser/ExpressionNode.cc
r0213af6 rfbcde64 10 10 // Created On : Sat May 16 13:17:07 2015 11 11 // Last Modified By : Peter A. Buhr 12 // Last Modified On : Wed May 17 21:31:01201713 // Update Count : 5 2712 // Last Modified On : Thu Mar 30 17:02:46 2017 13 // Update Count : 515 14 14 // 15 15 … … 207 207 } // build_field_name_fraction_constants 208 208 209 210 211 209 Expression * build_field_name_REALFRACTIONconstant( const std::string & str ) { 212 if ( str.find_first_not_of( "0123456789", 1 ) != string::npos ) throw SemanticError( "invalid tuple index " + str);210 assert( str[0] == '.' ); 213 211 Expression * ret = build_constantInteger( *new std::string( str.substr(1) ) ); 214 212 delete &str; … … 217 215 218 216 Expression * build_field_name_REALDECIMALconstant( const std::string & str ) { 219 if ( str[str.size()-1] != '.' ) throw SemanticError( "invalid tuple index " + str);217 assert( str[str.size()-1] == '.' ); 220 218 Expression * ret = build_constantInteger( *new std::string( str.substr( 0, str.size()-1 ) ) ); 221 219 delete &str;
Note: See TracChangeset
for help on using the changeset viewer.