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

Unified Diff: runtime/vm/object.cc

Issue 8772009: Address Regis' comments, replace AbstractType with Type where possible. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: '' Created 9 years, 1 month 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.h ('k') | runtime/vm/parser.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/object.cc
===================================================================
--- runtime/vm/object.cc (revision 1991)
+++ runtime/vm/object.cc (working copy)
@@ -600,7 +600,7 @@
// Remove the Object superclass cycle by setting the super type to null (not
// to the type of null).
cls = object_store->object_class();
- cls.set_super_type(AbstractType::Handle());
+ cls.set_super_type(Type::Handle());
ClassFinalizer::VerifyBootstrapClasses();
}
@@ -724,11 +724,11 @@
}
-RawAbstractType* Class::SignatureType() const {
+RawType* Class::SignatureType() const {
// Return the first canonical signature type if already computed.
const Array& signature_types = Array::Handle(canonical_types());
if (signature_types.Length() > 0) {
- AbstractType& signature_type = AbstractType::Handle();
+ Type& signature_type = Type::Handle();
signature_type ^= signature_types.At(0);
if (!signature_type.IsNull()) {
return signature_type.raw();
@@ -901,7 +901,7 @@
RawClass* Class::SuperClass() const {
- const AbstractType& sup_type = AbstractType::Handle(super_type());
+ const Type& sup_type = Type::Handle(super_type());
if (sup_type.IsNull()) {
return Class::null();
}
@@ -909,7 +909,7 @@
}
-void Class::set_super_type(const AbstractType& value) const {
+void Class::set_super_type(const Type& value) const {
StorePointer(&raw_ptr()->super_type_, value.raw());
}
@@ -1123,8 +1123,7 @@
// Instances of a signature class can only be closures.
ASSERT(result.instance_size() == Closure::InstanceSize());
// Cache the signature type as the first canonicalized type in result.
- const AbstractType& signature_type =
- AbstractType::Handle(result.SignatureType());
+ const Type& signature_type = Type::Handle(result.SignatureType());
ASSERT(!signature_type.IsFinalized());
const Array& new_canonical_types = Array::Handle(Array::New(1, Heap::kOld));
new_canonical_types.SetAt(0, signature_type);
@@ -2135,7 +2134,7 @@
const intptr_t canonical_types_len = canonical_types.Length();
// Linear search to see whether this type is already present in the
// list of canonicalized types.
- AbstractType& type = AbstractType::Handle();
+ Type& type = Type::Handle();
intptr_t index = 0;
while (index < canonical_types_len) {
type ^= canonical_types.At(index);
@@ -3224,8 +3223,7 @@
} else {
closure_function.set_signature_class(signature_class);
}
- const AbstractType& signature_type =
- AbstractType::Handle(signature_class.SignatureType());
+ const Type& signature_type = Type::Handle(signature_class.SignatureType());
if (!signature_type.IsFinalized()) {
String& errmsg = String::Handle();
ClassFinalizer::FinalizeAndCanonicalizeType(signature_type, &errmsg);
« no previous file with comments | « runtime/vm/object.h ('k') | runtime/vm/parser.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698