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

Unified Diff: runtime/vm/parser.cc

Issue 14097006: A patch class must be given the same name as the class it is patching, otherwise (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 8 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 | « no previous file | runtime/vm/symbols.h » ('j') | 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 21232)
+++ runtime/vm/parser.cc (working copy)
@@ -3240,10 +3240,11 @@
// Preserve and reuse the original type parameters and bounds since the
// ones defined in the patch class will not be finalized.
orig_type_parameters = cls.type_parameters();
- String& patch = String::Handle(
- String::Concat(Symbols::PatchSpace(), class_name));
- patch = Symbols::New(patch);
- cls = Class::New(patch, script_, classname_pos);
+ // A patch class must be given the same name as the class it is patching,
+ // otherwise the generic signature classes it defines will not match the
+ // patched generic signature classes. Therefore, new signature classes
+ // will be introduced and the original ones will not get finalized.
+ cls = Class::New(class_name, script_, classname_pos);
cls.set_library(library_);
} else {
// Not patching a class, but it has been found. This must be one of the
« no previous file with comments | « no previous file | runtime/vm/symbols.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698