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

Side by Side Diff: src/compiler.h

Issue 1301583005: Rename ParserInfo::function() and CompilationInfo::function() to literal(). (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 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 unified diff | Download patch
« no previous file with comments | « src/codegen.cc ('k') | src/compiler.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 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 "src/allocation.h" 8 #include "src/allocation.h"
9 #include "src/ast.h" 9 #include "src/ast.h"
10 #include "src/bailout-reason.h" 10 #include "src/bailout-reason.h"
(...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after
141 141
142 // ----------------------------------------------------------- 142 // -----------------------------------------------------------
143 // TODO(titzer): inline and delete accessors of ParseInfo 143 // TODO(titzer): inline and delete accessors of ParseInfo
144 // ----------------------------------------------------------- 144 // -----------------------------------------------------------
145 Handle<Script> script() const; 145 Handle<Script> script() const;
146 bool is_eval() const; 146 bool is_eval() const;
147 bool is_native() const; 147 bool is_native() const;
148 bool is_module() const; 148 bool is_module() const;
149 LanguageMode language_mode() const; 149 LanguageMode language_mode() const;
150 Handle<JSFunction> closure() const; 150 Handle<JSFunction> closure() const;
151 FunctionLiteral* function() const; 151 FunctionLiteral* literal() const;
152 Scope* scope() const; 152 Scope* scope() const;
153 bool MayUseThis() const; 153 bool MayUseThis() const;
154 Handle<Context> context() const; 154 Handle<Context> context() const;
155 Handle<SharedFunctionInfo> shared_info() const; 155 Handle<SharedFunctionInfo> shared_info() const;
156 bool has_shared_info() const; 156 bool has_shared_info() const;
157 bool has_context() const; 157 bool has_context() const;
158 bool has_literal() const;
159 bool has_scope() const;
158 // ----------------------------------------------------------- 160 // -----------------------------------------------------------
159 161
160 Isolate* isolate() const { 162 Isolate* isolate() const {
161 return isolate_; 163 return isolate_;
162 } 164 }
163 Zone* zone() { return zone_; } 165 Zone* zone() { return zone_; }
164 bool is_osr() const { return !osr_ast_id_.IsNone(); } 166 bool is_osr() const { return !osr_ast_id_.IsNone(); }
165 Handle<Code> code() const { return code_; } 167 Handle<Code> code() const { return code_; }
166 CodeStub* code_stub() const { return code_stub_; } 168 CodeStub* code_stub() const { return code_stub_; }
167 BailoutId osr_ast_id() const { return osr_ast_id_; } 169 BailoutId osr_ast_id() const { return osr_ast_id_; }
168 Handle<Code> unoptimized_code() const { return unoptimized_code_; } 170 Handle<Code> unoptimized_code() const { return unoptimized_code_; }
169 int opt_count() const { return opt_count_; } 171 int opt_count() const { return opt_count_; }
170 int num_parameters() const; 172 int num_parameters() const;
171 int num_parameters_including_this() const; 173 int num_parameters_including_this() const;
172 bool is_this_defined() const; 174 bool is_this_defined() const;
173 int num_heap_slots() const; 175 int num_heap_slots() const;
174 Code::Flags flags() const; 176 Code::Flags flags() const;
175 bool has_scope() const { return scope() != nullptr; }
176 177
177 void set_parameter_count(int parameter_count) { 178 void set_parameter_count(int parameter_count) {
178 DCHECK(IsStub()); 179 DCHECK(IsStub());
179 parameter_count_ = parameter_count; 180 parameter_count_ = parameter_count;
180 } 181 }
181 182
182 bool is_tracking_positions() const { return track_positions_; } 183 bool is_tracking_positions() const { return track_positions_; }
183 184
184 bool is_calling() const { 185 bool is_calling() const {
185 return GetFlag(kDeferredCalling) || GetFlag(kNonDeferredCalling); 186 return GetFlag(kDeferredCalling) || GetFlag(kNonDeferredCalling);
(...skipping 514 matching lines...) Expand 10 before | Expand all | Expand 10 after
700 Zone zone_; 701 Zone zone_;
701 size_t info_zone_start_allocation_size_; 702 size_t info_zone_start_allocation_size_;
702 base::ElapsedTimer timer_; 703 base::ElapsedTimer timer_;
703 704
704 DISALLOW_COPY_AND_ASSIGN(CompilationPhase); 705 DISALLOW_COPY_AND_ASSIGN(CompilationPhase);
705 }; 706 };
706 707
707 } } // namespace v8::internal 708 } } // namespace v8::internal
708 709
709 #endif // V8_COMPILER_H_ 710 #endif // V8_COMPILER_H_
OLDNEW
« no previous file with comments | « src/codegen.cc ('k') | src/compiler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698