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

Side by Side Diff: src/ast.cc

Issue 42008: Introduce a BreakTarget subclass of JumpTarget used to represent the... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: '' Created 11 years, 9 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 | « src/ast.h ('k') | src/codegen-arm.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2006-2008 the V8 project authors. All rights reserved. 1 // Copyright 2006-2008 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after
145 } 145 }
146 146
147 147
148 ObjectLiteral::Property::Property(bool is_getter, FunctionLiteral* value) { 148 ObjectLiteral::Property::Property(bool is_getter, FunctionLiteral* value) {
149 key_ = new Literal(value->name()); 149 key_ = new Literal(value->name());
150 value_ = value; 150 value_ = value;
151 kind_ = is_getter ? GETTER : SETTER; 151 kind_ = is_getter ? GETTER : SETTER;
152 } 152 }
153 153
154 154
155 void TargetCollector::AddTarget(JumpTarget* target) { 155 void TargetCollector::AddTarget(BreakTarget* target) {
156 // Add the label to the collector, but discard duplicates. 156 // Add the label to the collector, but discard duplicates.
157 int length = targets_->length(); 157 int length = targets_->length();
158 for (int i = 0; i < length; i++) { 158 for (int i = 0; i < length; i++) {
159 if (targets_->at(i) == target) return; 159 if (targets_->at(i) == target) return;
160 } 160 }
161 targets_->Add(target); 161 targets_->Add(target);
162 } 162 }
163 163
164 164
165 // ---------------------------------------------------------------------------- 165 // ----------------------------------------------------------------------------
(...skipping 315 matching lines...) Expand 10 before | Expand all | Expand 10 after
481 if (kInfinity - max_match_ < node_max_match) { 481 if (kInfinity - max_match_ < node_max_match) {
482 max_match_ = kInfinity; 482 max_match_ = kInfinity;
483 } else { 483 } else {
484 max_match_ += node->max_match(); 484 max_match_ += node->max_match();
485 } 485 }
486 } 486 }
487 } 487 }
488 488
489 489
490 } } // namespace v8::internal 490 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/ast.h ('k') | src/codegen-arm.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698