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

Side by Side Diff: src/hydrogen.cc

Issue 663683006: Implement ES6 Template Literals (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Prevent fall-through to template token handlers Created 6 years, 1 month 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
OLDNEW
1 // Copyright 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/hydrogen.h" 5 #include "src/hydrogen.h"
6 6
7 #include <sstream> 7 #include <sstream>
8 8
9 #include "src/v8.h" 9 #include "src/v8.h"
10 10
(...skipping 5443 matching lines...) Expand 10 before | Expand all | Expand 10 after
5454 5454
5455 void HOptimizedGraphBuilder::VisitLiteral(Literal* expr) { 5455 void HOptimizedGraphBuilder::VisitLiteral(Literal* expr) {
5456 DCHECK(!HasStackOverflow()); 5456 DCHECK(!HasStackOverflow());
5457 DCHECK(current_block() != NULL); 5457 DCHECK(current_block() != NULL);
5458 DCHECK(current_block()->HasPredecessor()); 5458 DCHECK(current_block()->HasPredecessor());
5459 HConstant* instr = New<HConstant>(expr->value()); 5459 HConstant* instr = New<HConstant>(expr->value());
5460 return ast_context()->ReturnInstruction(instr, expr->id()); 5460 return ast_context()->ReturnInstruction(instr, expr->id());
5461 } 5461 }
5462 5462
5463 5463
5464 void HOptimizedGraphBuilder::VisitTemplateLiteral(TemplateLiteral* expr) {
5465 return Bailout(kTemplateLiteral);
5466 }
5467
5468
5464 void HOptimizedGraphBuilder::VisitRegExpLiteral(RegExpLiteral* expr) { 5469 void HOptimizedGraphBuilder::VisitRegExpLiteral(RegExpLiteral* expr) {
5465 DCHECK(!HasStackOverflow()); 5470 DCHECK(!HasStackOverflow());
5466 DCHECK(current_block() != NULL); 5471 DCHECK(current_block() != NULL);
5467 DCHECK(current_block()->HasPredecessor()); 5472 DCHECK(current_block()->HasPredecessor());
5468 Handle<JSFunction> closure = function_state()->compilation_info()->closure(); 5473 Handle<JSFunction> closure = function_state()->compilation_info()->closure();
5469 Handle<FixedArray> literals(closure->literals()); 5474 Handle<FixedArray> literals(closure->literals());
5470 HRegExpLiteral* instr = New<HRegExpLiteral>(literals, 5475 HRegExpLiteral* instr = New<HRegExpLiteral>(literals,
5471 expr->pattern(), 5476 expr->pattern(),
5472 expr->flags(), 5477 expr->flags(),
5473 expr->literal_index()); 5478 expr->literal_index());
(...skipping 7194 matching lines...) Expand 10 before | Expand all | Expand 10 after
12668 if (ShouldProduceTraceOutput()) { 12673 if (ShouldProduceTraceOutput()) {
12669 isolate()->GetHTracer()->TraceHydrogen(name(), graph_); 12674 isolate()->GetHTracer()->TraceHydrogen(name(), graph_);
12670 } 12675 }
12671 12676
12672 #ifdef DEBUG 12677 #ifdef DEBUG
12673 graph_->Verify(false); // No full verify. 12678 graph_->Verify(false); // No full verify.
12674 #endif 12679 #endif
12675 } 12680 }
12676 12681
12677 } } // namespace v8::internal 12682 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/harmony-templates.js ('k') | src/messages.js » ('j') | src/parser.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698