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

Unified Diff: runtime/vm/flow_graph_builder.cc

Issue 30533004: Report correct error message in case of super invocation (fix issue 8208). (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 2 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/flow_graph_builder.h ('k') | runtime/vm/parser.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/flow_graph_builder.cc
===================================================================
--- runtime/vm/flow_graph_builder.cc (revision 29041)
+++ runtime/vm/flow_graph_builder.cc (working copy)
@@ -2746,7 +2746,8 @@
node->receiver(),
getter_name,
arguments,
- false); // Don't save last argument.
+ false, // Don't save last argument.
+ true); // Super invocation.
ReturnDefinition(call);
return;
} else {
@@ -2824,7 +2825,8 @@
node->receiver(),
setter_name,
arguments,
- result_is_needed); // Save last arg if result is needed.
+ result_is_needed, // Save last arg if result is needed.
+ true); // Super invocation.
} else {
// Throw a NoSuchMethodError.
ArgumentListNode* arguments = new ArgumentListNode(node->token_pos());
@@ -3180,7 +3182,8 @@
node->array(),
Symbols::IndexToken(),
arguments,
- false); // Don't save last arg.
+ false, // Don't save last arg.
+ true); // Super invocation.
ReturnDefinition(call);
return;
}
@@ -3241,7 +3244,8 @@
node->array(),
Symbols::AssignIndexToken(),
arguments,
- result_is_needed); // Save last arg if result is needed.
+ result_is_needed, // Save last arg if result is needed.
+ true); // Super invocation.
if (result_is_needed) {
Do(call);
// BuildStaticNoSuchMethodCall stores the value in expression_temp.
@@ -3622,7 +3626,8 @@
AstNode* receiver,
const String& method_name,
ArgumentListNode* method_arguments,
- bool save_last_arg) {
+ bool save_last_arg,
+ bool is_super_invocation) {
intptr_t args_pos = method_arguments->token_pos();
LocalVariable* temp = NULL;
if (save_last_arg) {
@@ -3632,7 +3637,8 @@
Parser::BuildNoSuchMethodArguments(args_pos,
method_name,
*method_arguments,
- temp);
+ temp,
+ is_super_invocation);
const Function& no_such_method_func = Function::ZoneHandle(
Resolver::ResolveDynamicAnyArgs(target_class, Symbols::NoSuchMethod()));
// We are guaranteed to find noSuchMethod of class Object.
« no previous file with comments | « runtime/vm/flow_graph_builder.h ('k') | runtime/vm/parser.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698