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

Unified Diff: dart/lib/compiler/implementation/closure.dart

Issue 10823311: Clean up state handling in ClassElement. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge
Patch Set: Rebased 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 | « no previous file | dart/lib/compiler/implementation/elements/elements.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: dart/lib/compiler/implementation/closure.dart
diff --git a/dart/lib/compiler/implementation/closure.dart b/dart/lib/compiler/implementation/closure.dart
index b8fd77a5ebb8483d946b144bd31eda54fb1feea6..d70f23eaa41124006722f9f73f43f3975873aa8c 100644
--- a/dart/lib/compiler/implementation/closure.dart
+++ b/dart/lib/compiler/implementation/closure.dart
@@ -66,14 +66,8 @@ class ClosureClassElement extends ClassElement {
// By assigning a fresh class-id we make sure that the hashcode
// is unique, but also emit closure classes after all other
// classes (since the emitter sorts classes by their id).
- compiler.getNextFreeClassId()) {
- // We assign twice to [supertypeLoadState] as it contains asserts
- // which enforce certain sequence of transitions.
- supertypeLoadState = ClassElement.STATE_STARTED;
- supertypeLoadState = ClassElement.STATE_DONE;
- // Same as for [supertypeLoadState] above.
- resolutionState = ClassElement.STATE_STARTED;
- resolutionState = ClassElement.STATE_DONE;
+ compiler.getNextFreeClassId(),
+ ClassElement.STATE_DONE) {
compiler.closureClass.ensureResolved(compiler);
supertype = compiler.closureClass.computeType(compiler);
interfaces = const EmptyLink<Type>();
« no previous file with comments | « no previous file | dart/lib/compiler/implementation/elements/elements.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698