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

Unified Diff: src/compiler.cc

Issue 2281543002: [compiler] Remove inclusion of inline header file. (Closed)
Patch Set: Created 4 years, 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/compiler.h ('k') | src/compiler/basic-block-instrumentor.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler.cc
diff --git a/src/compiler.cc b/src/compiler.cc
index 00c391e7f79638a1d697243e284b87e819a068d9..9e7592ee765f4daf56db7140009b1728644d01ec 100644
--- a/src/compiler.cc
+++ b/src/compiler.cc
@@ -177,6 +177,9 @@ bool CompilationInfo::ShouldSelfOptimize() {
!shared_info()->optimization_disabled();
}
+void CompilationInfo::ReopenHandlesInNewHandleScope() {
+ closure_ = Handle<JSFunction>(*closure_);
+}
bool CompilationInfo::has_simple_parameters() {
return scope()->has_simple_parameters();
@@ -238,6 +241,30 @@ bool CompilationInfo::ExpectsJSReceiverAsReceiver() {
return is_sloppy(parse_info()->language_mode()) && !parse_info()->is_native();
}
+bool CompilationInfo::has_native_context() const {
+ return !closure().is_null() && (closure()->native_context() != nullptr);
+}
+
+Context* CompilationInfo::native_context() const {
+ return has_native_context() ? closure()->native_context() : nullptr;
+}
+
+bool CompilationInfo::has_global_object() const { return has_native_context(); }
+
+JSGlobalObject* CompilationInfo::global_object() const {
+ return has_global_object() ? native_context()->global_object() : nullptr;
+}
+
+void CompilationInfo::AddInlinedFunction(
+ Handle<SharedFunctionInfo> inlined_function) {
+ inlined_functions_.push_back(InlinedFunctionHolder(
+ inlined_function, handle(inlined_function->code())));
+}
+
+Code::Kind CompilationInfo::output_code_kind() const {
+ return Code::ExtractKindFromFlags(code_flags_);
+}
+
// ----------------------------------------------------------------------------
// Implementation of CompilationJob
« no previous file with comments | « src/compiler.h ('k') | src/compiler/basic-block-instrumentor.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698