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

Unified Diff: runtime/vm/parser.cc

Issue 1195573006: Handle field-invocation and method-extraction in the runtime when --lazy_dispatchers=false. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 years, 6 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 | « runtime/vm/object.cc ('k') | runtime/vm/resolver.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/parser.cc
diff --git a/runtime/vm/parser.cc b/runtime/vm/parser.cc
index 6cc8e5421676438b17b07fdde16c095f27fbaeca..42122484b09d41c2a75e0b2c65b175cbfbbe6526 100644
--- a/runtime/vm/parser.cc
+++ b/runtime/vm/parser.cc
@@ -46,6 +46,7 @@ DECLARE_FLAG(bool, throw_on_javascript_int_overflow);
DECLARE_FLAG(bool, warn_on_javascript_compatibility);
DEFINE_FLAG(bool, enable_mirrors, true,
"Disable to make importing dart:mirrors an error.");
+DECLARE_FLAG(bool, lazy_dispatchers);
// Quick access to the current isolate and zone.
#define I (isolate())
@@ -1330,6 +1331,8 @@ SequenceNode* Parser::ParseImplicitClosure(const Function& func,
SequenceNode* Parser::ParseMethodExtractor(const Function& func) {
TRACE_PARSER("ParseMethodExtractor");
+ ASSERT(FLAG_lazy_dispatchers);
+
ParamList params;
const intptr_t ident_pos = func.token_pos();
@@ -1402,6 +1405,7 @@ void Parser::BuildDispatcherScope(const Function& func,
SequenceNode* Parser::ParseNoSuchMethodDispatcher(const Function& func,
Array* default_values) {
TRACE_PARSER("ParseNoSuchMethodDispatcher");
+ ASSERT(FLAG_lazy_dispatchers);
ASSERT(func.IsNoSuchMethodDispatcher());
intptr_t token_pos = func.token_pos();
@@ -1459,6 +1463,7 @@ SequenceNode* Parser::ParseNoSuchMethodDispatcher(const Function& func,
SequenceNode* Parser::ParseInvokeFieldDispatcher(const Function& func,
Array* default_values) {
TRACE_PARSER("ParseInvokeFieldDispatcher");
+ ASSERT(FLAG_lazy_dispatchers);
ASSERT(func.IsInvokeFieldDispatcher());
intptr_t token_pos = func.token_pos();
« no previous file with comments | « runtime/vm/object.cc ('k') | runtime/vm/resolver.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698