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

Side by Side Diff: src/builtins/builtins-function.cc

Issue 2502293002: Reland of [refactoring] Split CodeAssemblerState out of CodeAssembler (Closed)
Patch Set: fix Created 4 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
« no previous file with comments | « src/builtins/builtins-date.cc ('k') | src/builtins/builtins-generator.cc » ('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 2016 the V8 project authors. All rights reserved. 1 // Copyright 2016 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/builtins/builtins.h" 5 #include "src/builtins/builtins.h"
6 #include "src/builtins/builtins-utils.h" 6 #include "src/builtins/builtins-utils.h"
7 7
8 #include "src/compiler.h" 8 #include "src/compiler.h"
9 #include "src/string-builder.h" 9 #include "src/string-builder.h"
10 10
(...skipping 265 matching lines...) Expand 10 before | Expand all | Expand 10 after
276 return *JSFunction::ToString(Handle<JSFunction>::cast(receiver)); 276 return *JSFunction::ToString(Handle<JSFunction>::cast(receiver));
277 } 277 }
278 THROW_NEW_ERROR_RETURN_FAILURE( 278 THROW_NEW_ERROR_RETURN_FAILURE(
279 isolate, NewTypeError(MessageTemplate::kNotGeneric, 279 isolate, NewTypeError(MessageTemplate::kNotGeneric,
280 isolate->factory()->NewStringFromAsciiChecked( 280 isolate->factory()->NewStringFromAsciiChecked(
281 "Function.prototype.toString"))); 281 "Function.prototype.toString")));
282 } 282 }
283 283
284 // ES6 section 19.2.3.6 Function.prototype [ @@hasInstance ] ( V ) 284 // ES6 section 19.2.3.6 Function.prototype [ @@hasInstance ] ( V )
285 void Builtins::Generate_FunctionPrototypeHasInstance( 285 void Builtins::Generate_FunctionPrototypeHasInstance(
286 CodeStubAssembler* assembler) { 286 compiler::CodeAssemblerState* state) {
287 using compiler::Node; 287 using compiler::Node;
288 CodeStubAssembler assembler(state);
288 289
289 Node* f = assembler->Parameter(0); 290 Node* f = assembler.Parameter(0);
290 Node* v = assembler->Parameter(1); 291 Node* v = assembler.Parameter(1);
291 Node* context = assembler->Parameter(4); 292 Node* context = assembler.Parameter(4);
292 Node* result = assembler->OrdinaryHasInstance(context, f, v); 293 Node* result = assembler.OrdinaryHasInstance(context, f, v);
293 assembler->Return(result); 294 assembler.Return(result);
294 } 295 }
295 296
296 } // namespace internal 297 } // namespace internal
297 } // namespace v8 298 } // namespace v8
OLDNEW
« no previous file with comments | « src/builtins/builtins-date.cc ('k') | src/builtins/builtins-generator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698