- Timestamp:
- Jul 15, 2017, 7:34:05 PM (7 years ago)
- Branches:
- ADT, aaron-thesis, arm-eh, ast-experimental, cleanup-dtors, deferred_resn, demangler, enum, forall-pointer-decay, jacob/cs343-translation, jenkins-sandbox, master, new-ast, new-ast-unique-expr, new-env, no_list, persistent-indexer, pthread-emulation, qualifiedEnum, resolv-new, with_gc
- Children:
- dc2b4d6
- Parents:
- 478b1d0
- Location:
- src
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
src/CodeGen/OperatorTable.cc
r478b1d0 re5f2a67 10 10 // Created On : Mon May 18 07:44:20 2015 11 11 // Last Modified By : Peter A. Buhr 12 // Last Modified On : Tue Dec 13 14:33:05 201613 // Update Count : 1 012 // Last Modified On : Sat Jul 15 17:12:22 2017 13 // Update Count : 15 14 14 // 15 15 … … 35 35 { "++?", "++", "_operator_preincr", OT_PREFIXASSIGN }, 36 36 { "--?", "--", "_operator_predecr", OT_PREFIXASSIGN }, 37 { "?\\?", "\\", "_operator_exponential", OT_INFIX }, 37 38 { "?*?", "*", "_operator_multiply", OT_INFIX }, 38 39 { "?/?", "/", "_operator_divide", OT_INFIX }, … … 52 53 { "?|?", "|", "_operator_bitor", OT_INFIX }, 53 54 { "?=?", "=", "_operator_assign", OT_INFIXASSIGN }, 55 { "?\\=?", "\\=", "_operator_expassign", OT_INFIXASSIGN }, 54 56 { "?*=?", "*=", "_operator_multassign", OT_INFIXASSIGN }, 55 57 { "?/=?", "/=", "_operator_divassign", OT_INFIXASSIGN }, -
src/Parser/ExpressionNode.cc
r478b1d0 re5f2a67 10 10 // Created On : Sat May 16 13:17:07 2015 11 11 // Last Modified By : Peter A. Buhr 12 // Last Modified On : Wed Jun 28 21:08:15201713 // Update Count : 54 212 // Last Modified On : Sat Jul 15 16:09:04 2017 13 // Update Count : 549 14 14 // 15 15 … … 231 231 } 232 232 233 // Must harmonize with OperKinds. 233 234 static const char *OperName[] = { 234 235 // diadic 235 "SizeOf", "AlignOf", "OffsetOf", "?+?", "?-?", "? *?", "?/?", "?%?", "||", "&&",236 "SizeOf", "AlignOf", "OffsetOf", "?+?", "?-?", "?\\?", "?*?", "?/?", "?%?", "||", "&&", 236 237 "?|?", "?&?", "?^?", "Cast", "?<<?", "?>>?", "?<?", "?>?", "?<=?", "?>=?", "?==?", "?!=?", 237 "?=?", "?@=?", "? *=?", "?/=?", "?%=?", "?+=?", "?-=?", "?<<=?", "?>>=?", "?&=?", "?^=?", "?|=?",238 "?=?", "?@=?", "?\\=?", "?*=?", "?/=?", "?%=?", "?+=?", "?-=?", "?<<=?", "?>>=?", "?&=?", "?^=?", "?|=?", 238 239 "?[?]", "...", 239 240 // monadic -
src/Parser/ParseNode.h
r478b1d0 re5f2a67 9 9 // Author : Rodolfo G. Esteves 10 10 // Created On : Sat May 16 13:28:16 2015 11 // Last Modified By : Andrew Beach12 // Last Modified On : Fri Jul 14 16:56:00201713 // Update Count : 78 011 // Last Modified By : Peter A. Buhr 12 // Last Modified On : Sat Jul 15 16:00:48 2017 13 // Update Count : 785 14 14 // 15 15 … … 141 141 }; 142 142 143 // Must harmonize with OperName. 143 144 enum class OperKinds { 144 145 // diadic 145 SizeOf, AlignOf, OffsetOf, Plus, Minus, Mul, Div, Mod, Or, And,146 SizeOf, AlignOf, OffsetOf, Plus, Minus, Exp, Mul, Div, Mod, Or, And, 146 147 BitOr, BitAnd, Xor, Cast, LShift, RShift, LThan, GThan, LEThan, GEThan, Eq, Neq, 147 Assign, AtAssn, MulAssn, DivAssn, ModAssn, PlusAssn, MinusAssn, LSAssn, RSAssn, AndAssn, ERAssn, OrAssn,148 Assign, AtAssn, ExpAssn, MulAssn, DivAssn, ModAssn, PlusAssn, MinusAssn, LSAssn, RSAssn, AndAssn, ERAssn, OrAssn, 148 149 Index, Range, 149 150 // monadic -
src/Parser/lex.ll
r478b1d0 re5f2a67 10 10 * Created On : Sat Sep 22 08:58:10 2001 11 11 * Last Modified By : Peter A. Buhr 12 * Last Modified On : Sat Jul 15 08:31:47201713 * Update Count : 54 112 * Last Modified On : Sat Jul 15 15:46:34 2017 13 * Update Count : 542 14 14 */ 15 15 … … 337 337 "-" { ASCIIOP_RETURN(); } 338 338 "*" { ASCIIOP_RETURN(); } 339 "\\" { ASCIIOP_RETURN(); } // CFA, exponentiation 339 340 "/" { ASCIIOP_RETURN(); } 340 341 "%" { ASCIIOP_RETURN(); } 341 "\\" { ASCIIOP_RETURN(); } // CFA, exponentiation342 342 "^" { ASCIIOP_RETURN(); } 343 343 "~" { ASCIIOP_RETURN(); } … … 362 362 "+=" { NAMEDOP_RETURN(PLUSassign); } 363 363 "-=" { NAMEDOP_RETURN(MINUSassign); } 364 "\\=" { NAMEDOP_RETURN(EXPassign); } // CFA, exponentiation 364 365 "*=" { NAMEDOP_RETURN(MULTassign); } 365 366 "/=" { NAMEDOP_RETURN(DIVassign); } 366 367 "%=" { NAMEDOP_RETURN(MODassign); } 367 "\\=" { NAMEDOP_RETURN(MODassign); } // CFA, exponentiation368 368 "&=" { NAMEDOP_RETURN(ANDassign); } 369 369 "|=" { NAMEDOP_RETURN(ORassign); } -
src/Parser/parser.yy
r478b1d0 re5f2a67 10 10 // Created On : Sat Sep 1 20:22:55 2001 11 11 // Last Modified By : Peter A. Buhr 12 // Last Modified On : Sat Jul 15 09:46:26201713 // Update Count : 245 112 // Last Modified On : Sat Jul 15 15:59:50 2017 13 // Update Count : 2454 14 14 // 15 15 … … 151 151 %token ELLIPSIS // ... 152 152 153 %token MULTassign DIVassign MODassign // *= /= %=/153 %token EXPassign MULTassign DIVassign MODassign // \= *= /= %= 154 154 %token PLUSassign MINUSassign // += -= 155 155 %token LSassign RSassign // <<= >>= … … 577 577 cast_expression 578 578 | exponential_expression '\\' cast_expression 579 { $$ = new ExpressionNode( build_binary_val( OperKinds:: Mod, $1, $3 ) ); }579 { $$ = new ExpressionNode( build_binary_val( OperKinds::Exp, $1, $3 ) ); } 580 580 ; 581 581 … … 685 685 '=' { $$ = OperKinds::Assign; } 686 686 | ATassign { $$ = OperKinds::AtAssn; } 687 | EXPassign { $$ = OperKinds::ExpAssn; } 687 688 | MULTassign { $$ = OperKinds::MulAssn; } 688 689 | DIVassign { $$ = OperKinds::DivAssn; }
Note: See TracChangeset
for help on using the changeset viewer.