Index: src/parsing/rewriter.cc |
diff --git a/src/parsing/rewriter.cc b/src/parsing/rewriter.cc |
index 915a464bf455f6a8be063d1b128dcb52fca6ed17..09ee8f77f28bc92559ea2e9f19a2b7fc5cf7a823 100644 |
--- a/src/parsing/rewriter.cc |
+++ b/src/parsing/rewriter.cc |
@@ -51,7 +51,7 @@ class Processor: public AstVisitor { |
result_assigned_ = true; |
VariableProxy* result_proxy = factory()->NewVariableProxy(result_); |
return factory()->NewAssignment(Token::ASSIGN, result_proxy, value, |
- RelocInfo::kNoPosition); |
+ kNoSourcePosition); |
} |
// Inserts '.result = undefined' in front of the given statement. |
@@ -93,13 +93,12 @@ class Processor: public AstVisitor { |
Statement* Processor::AssignUndefinedBefore(Statement* s) { |
Expression* result_proxy = factory()->NewVariableProxy(result_); |
- Expression* undef = factory()->NewUndefinedLiteral(RelocInfo::kNoPosition); |
- Expression* assignment = factory()->NewAssignment( |
- Token::ASSIGN, result_proxy, undef, RelocInfo::kNoPosition); |
- Block* b = factory()->NewBlock(NULL, 2, false, RelocInfo::kNoPosition); |
+ Expression* undef = factory()->NewUndefinedLiteral(kNoSourcePosition); |
+ Expression* assignment = factory()->NewAssignment(Token::ASSIGN, result_proxy, |
+ undef, kNoSourcePosition); |
+ Block* b = factory()->NewBlock(NULL, 2, false, kNoSourcePosition); |
b->statements()->Add( |
- factory()->NewExpressionStatement(assignment, RelocInfo::kNoPosition), |
- zone()); |
+ factory()->NewExpressionStatement(assignment, kNoSourcePosition), zone()); |
b->statements()->Add(s, zone()); |
return b; |
} |
@@ -232,15 +231,13 @@ void Processor::VisitTryFinallyStatement(TryFinallyStatement* node) { |
Expression* backup_proxy = factory()->NewVariableProxy(backup); |
Expression* result_proxy = factory()->NewVariableProxy(result_); |
Expression* save = factory()->NewAssignment( |
- Token::ASSIGN, backup_proxy, result_proxy, RelocInfo::kNoPosition); |
+ Token::ASSIGN, backup_proxy, result_proxy, kNoSourcePosition); |
Expression* restore = factory()->NewAssignment( |
- Token::ASSIGN, result_proxy, backup_proxy, RelocInfo::kNoPosition); |
+ Token::ASSIGN, result_proxy, backup_proxy, kNoSourcePosition); |
node->finally_block()->statements()->InsertAt( |
- 0, factory()->NewExpressionStatement(save, RelocInfo::kNoPosition), |
- zone()); |
+ 0, factory()->NewExpressionStatement(save, kNoSourcePosition), zone()); |
node->finally_block()->statements()->Add( |
- factory()->NewExpressionStatement(restore, RelocInfo::kNoPosition), |
- zone()); |
+ factory()->NewExpressionStatement(restore, kNoSourcePosition), zone()); |
} |
is_set_ = set_after; |
Visit(node->try_block()); |
@@ -355,7 +352,7 @@ bool Rewriter::Rewrite(ParseInfo* info) { |
if (processor.HasStackOverflow()) return false; |
if (processor.result_assigned()) { |
- int pos = RelocInfo::kNoPosition; |
+ int pos = kNoSourcePosition; |
VariableProxy* result_proxy = |
processor.factory()->NewVariableProxy(result, pos); |
Statement* result_statement = |
@@ -383,8 +380,7 @@ bool Rewriter::Rewrite(Parser* parser, DoExpression* expr, |
if (!processor.result_assigned()) { |
AstNodeFactory* node_factory = processor.factory(); |
- Expression* undef = |
- node_factory->NewUndefinedLiteral(RelocInfo::kNoPosition); |
+ Expression* undef = node_factory->NewUndefinedLiteral(kNoSourcePosition); |
Statement* completion = node_factory->NewExpressionStatement( |
processor.SetResult(undef), expr->position()); |
body->Add(completion, factory->zone()); |