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

Unified Diff: runtime/vm/class_finalizer.cc

Issue 12355002: Fix order of mixin application during class finalization (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 10 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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/class_finalizer.cc
===================================================================
--- runtime/vm/class_finalizer.cc (revision 19153)
+++ runtime/vm/class_finalizer.cc (working copy)
@@ -1215,6 +1215,12 @@
if (!super_class.IsNull()) {
FinalizeClass(super_class);
}
+ if (cls.mixin() != Type::null()) {
+ // Copy instance methods and fields from the mixin class.
+ // This has to happen before the check whether the methods of
+ // the class conflict with inherited methods.
+ ApplyMixin(cls);
+ }
// Finalize type parameters before finalizing the super type.
FinalizeTypeParameters(cls);
// Finalize super type.
@@ -1248,12 +1254,6 @@
FinalizeType(cls, sig_type, kCanonicalizeWellFormed);
return;
}
- if (cls.mixin() != Type::null()) {
- // Copy instance methods and fields from the mixin class.
- // This has to happen before the check whether the methods of
- // the class conflict with inherited methods.
- ApplyMixin(cls);
- }
// Finalize interface types (but not necessarily interface classes).
Array& interface_types = Array::Handle(cls.interfaces());
AbstractType& interface_type = AbstractType::Handle();
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698