Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(23)

Side by Side Diff: runtime/vm/parser.cc

Issue 10540040: Inline setters, getters, various cleanups & restructuring. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « runtime/vm/object_test.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #include "vm/parser.h" 5 #include "vm/parser.h"
6 6
7 #include "vm/bigint_operations.h" 7 #include "vm/bigint_operations.h"
8 #include "vm/class_finalizer.h" 8 #include "vm/class_finalizer.h"
9 #include "vm/compiler.h" 9 #include "vm/compiler.h"
10 #include "vm/compiler_stats.h" 10 #include "vm/compiler_stats.h"
(...skipping 6104 matching lines...) Expand 10 before | Expand all | Expand 10 after
6115 *expr = right_node; 6115 *expr = right_node;
6116 return left_node; 6116 return left_node;
6117 } 6117 }
6118 return *expr; 6118 return *expr;
6119 } 6119 }
6120 6120
6121 6121
6122 // Ensure that the expression temp is allocated for nodes that may need it. 6122 // Ensure that the expression temp is allocated for nodes that may need it.
6123 AstNode* Parser::CreateAssignmentNode(AstNode* original, AstNode* rhs) { 6123 AstNode* Parser::CreateAssignmentNode(AstNode* original, AstNode* rhs) {
6124 AstNode* result = original->MakeAssignmentNode(rhs); 6124 AstNode* result = original->MakeAssignmentNode(rhs);
6125 if ((result != NULL) && result->IsStoreIndexedNode()) { 6125 if ((result != NULL) &&
6126 (result->IsStoreIndexedNode() || result->IsInstanceSetterNode())) {
6126 EnsureExpressionTemp(); 6127 EnsureExpressionTemp();
6127 } 6128 }
6128 return result; 6129 return result;
6129 } 6130 }
6130 6131
6131 6132
6132 AstNode* Parser::ParseExpr(bool require_compiletime_const) { 6133 AstNode* Parser::ParseExpr(bool require_compiletime_const) {
6133 TRACE_PARSER("ParseExpr"); 6134 TRACE_PARSER("ParseExpr");
6134 const intptr_t expr_pos = token_index_; 6135 const intptr_t expr_pos = token_index_;
6135 AstNode* expr = ParseConditionalExpr(); 6136 AstNode* expr = ParseConditionalExpr();
(...skipping 2397 matching lines...) Expand 10 before | Expand all | Expand 10 after
8533 void Parser::SkipQualIdent() { 8534 void Parser::SkipQualIdent() {
8534 ASSERT(IsIdentifier()); 8535 ASSERT(IsIdentifier());
8535 ConsumeToken(); 8536 ConsumeToken();
8536 if (CurrentToken() == Token::kPERIOD) { 8537 if (CurrentToken() == Token::kPERIOD) {
8537 ConsumeToken(); // Consume the kPERIOD token. 8538 ConsumeToken(); // Consume the kPERIOD token.
8538 ExpectIdentifier("identifier expected after '.'"); 8539 ExpectIdentifier("identifier expected after '.'");
8539 } 8540 }
8540 } 8541 }
8541 8542
8542 } // namespace dart 8543 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/vm/object_test.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698