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

Unified Diff: runtime/vm/parser.cc

Issue 10854176: - Merge function lists when patching classes (no more duplicates). (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 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 | « runtime/vm/object.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/parser.cc
===================================================================
--- runtime/vm/parser.cc (revision 10747)
+++ runtime/vm/parser.cc (working copy)
@@ -2945,8 +2945,8 @@
ErrorMsg(classname_pos, "'%s' %s",
class_name.ToCString(),
is_patch ?
- "is already defined as interface" :
- "interface cannot be patched");
+ "interface cannot be patched" :
+ "is already defined as interface");
} else if (is_patch) {
String& patch = String::Handle(Symbols::New("patch "));
patch = String::Concat(patch, class_name);
@@ -3027,7 +3027,10 @@
} else {
// Lookup the patched class and apply the changes.
obj = library_.LookupObject(class_name);
- Class::Cast(obj).ApplyPatch(cls);
+ const char* err_msg = Class::Cast(obj).ApplyPatch(cls);
+ if (err_msg != NULL) {
+ ErrorMsg(classname_pos, "applying patch failed with '%s'", err_msg);
+ }
}
}
« no previous file with comments | « runtime/vm/object.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698