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

Side by Side Diff: src/compiler.h

Issue 2156303002: Implement new Function.prototype.toString and fix CreateDynamicFunction parsing (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: fix async function constructor 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
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 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 #ifndef V8_COMPILER_H_ 5 #ifndef V8_COMPILER_H_
6 #define V8_COMPILER_H_ 6 #define V8_COMPILER_H_
7 7
8 #include <memory> 8 #include <memory>
9 9
10 #include "src/allocation.h" 10 #include "src/allocation.h"
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
83 // is left to the discretion of the compiler. 83 // is left to the discretion of the compiler.
84 // 84 //
85 // Please note this interface returns shared function infos. This means you 85 // Please note this interface returns shared function infos. This means you
86 // need to call Factory::NewFunctionFromSharedFunctionInfo before you have a 86 // need to call Factory::NewFunctionFromSharedFunctionInfo before you have a
87 // real function with a context. 87 // real function with a context.
88 88
89 // Create a (bound) function for a String source within a context for eval. 89 // Create a (bound) function for a String source within a context for eval.
90 MUST_USE_RESULT static MaybeHandle<JSFunction> GetFunctionFromEval( 90 MUST_USE_RESULT static MaybeHandle<JSFunction> GetFunctionFromEval(
91 Handle<String> source, Handle<SharedFunctionInfo> outer_info, 91 Handle<String> source, Handle<SharedFunctionInfo> outer_info,
92 Handle<Context> context, LanguageMode language_mode, 92 Handle<Context> context, LanguageMode language_mode,
93 ParseRestriction restriction, int eval_scope_position, int eval_position, 93 ParseRestriction restriction, int parameters_end_pos,
94 int line_offset = 0, int column_offset = 0, 94 int eval_scope_position, int eval_position, int line_offset = 0,
95 Handle<Object> script_name = Handle<Object>(), 95 int column_offset = 0, Handle<Object> script_name = Handle<Object>(),
96 ScriptOriginOptions options = ScriptOriginOptions()); 96 ScriptOriginOptions options = ScriptOriginOptions());
97 97
98 // Create a (bound) function for a String source within a context for eval. 98 // Create a (bound) function for a String source within a context for eval.
99 MUST_USE_RESULT static MaybeHandle<JSFunction> GetFunctionFromString( 99 MUST_USE_RESULT static MaybeHandle<JSFunction> GetFunctionFromString(
100 Handle<Context> context, Handle<String> source, 100 Handle<Context> context, Handle<String> source,
101 ParseRestriction restriction); 101 ParseRestriction restriction, int parameters_end_pos);
102 102
103 // Create a shared function info object for a String source within a context. 103 // Create a shared function info object for a String source within a context.
104 static Handle<SharedFunctionInfo> GetSharedFunctionInfoForScript( 104 static Handle<SharedFunctionInfo> GetSharedFunctionInfoForScript(
105 Handle<String> source, Handle<Object> script_name, int line_offset, 105 Handle<String> source, Handle<Object> script_name, int line_offset,
106 int column_offset, ScriptOriginOptions resource_options, 106 int column_offset, ScriptOriginOptions resource_options,
107 Handle<Object> source_map_url, Handle<Context> context, 107 Handle<Object> source_map_url, Handle<Context> context,
108 v8::Extension* extension, ScriptData** cached_data, 108 v8::Extension* extension, ScriptData** cached_data,
109 ScriptCompiler::CompileOptions compile_options, 109 ScriptCompiler::CompileOptions compile_options,
110 NativesFlag is_natives_code, bool is_module); 110 NativesFlag is_natives_code, bool is_module);
111 111
(...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after
222 state_ = State::kFailed; 222 state_ = State::kFailed;
223 } 223 }
224 return status; 224 return status;
225 } 225 }
226 }; 226 };
227 227
228 } // namespace internal 228 } // namespace internal
229 } // namespace v8 229 } // namespace v8
230 230
231 #endif // V8_COMPILER_H_ 231 #endif // V8_COMPILER_H_
OLDNEW
« no previous file with comments | « src/builtins/builtins-global.cc ('k') | src/compiler.cc » ('j') | src/objects.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698