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

Unified Diff: runtime/vm/object.h

Issue 10205006: Mark types as instantiated or uninstantiated upon finalization. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 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 | « runtime/vm/class_finalizer.cc ('k') | runtime/vm/object.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/object.h
===================================================================
--- runtime/vm/object.h (revision 6893)
+++ runtime/vm/object.h (working copy)
@@ -885,9 +885,12 @@
return OFFSET_OF(RawType, type_class_);
}
virtual bool IsFinalized() const {
- return raw_ptr()->type_state_ == RawType::kFinalized;
+ return
+ (raw_ptr()->type_state_ == RawType::kFinalizedInstantiated) ||
+ (raw_ptr()->type_state_ == RawType::kFinalizedUninstantiated);
}
- void set_is_finalized() const;
+ void set_is_finalized_instantiated() const;
+ void set_is_finalized_uninstantiated() const;
virtual bool IsBeingFinalized() const {
return raw_ptr()->type_state_ == RawType::kBeingFinalized;
}
@@ -976,7 +979,8 @@
class TypeParameter : public AbstractType {
public:
virtual bool IsFinalized() const {
- return raw_ptr()->type_state_ == RawTypeParameter::kFinalized;
+ ASSERT(raw_ptr()->type_state_ != RawTypeParameter::kFinalizedInstantiated);
+ return raw_ptr()->type_state_ == RawTypeParameter::kFinalizedUninstantiated;
}
void set_is_finalized() const;
virtual bool IsBeingFinalized() const { return false; }
« no previous file with comments | « runtime/vm/class_finalizer.cc ('k') | runtime/vm/object.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698