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

Unified Diff: runtime/vm/object.h

Issue 17104002: Fix a bug in instance canonicalization and add debug mode checks that we are not missing any fields. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 6 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/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 24056)
+++ runtime/vm/object.h (working copy)
@@ -3531,6 +3531,9 @@
// Returns error in error_str, pass NULL if an error cannot occur.
virtual RawInstance* CheckAndCanonicalize(const char** error_str) const;
+ // Returns true if all fields are OK for canonicalization.
+ virtual bool CheckAndCanonicalizeFields(const char** error_str) const;
+
RawObject* GetField(const Field& field) const {
return *FieldAddr(field);
}
@@ -4984,6 +4987,9 @@
return RoundedAllocationSize(sizeof(RawArray) + (len * kBytesPerElement));
}
+ // Returns true if all elements are OK for canonicalization.
+ virtual bool CheckAndCanonicalizeFields(const char** error_str) const;
+
// Make the array immutable to Dart code by switching the class pointer
// to ImmutableArray.
void MakeImmutable() const;
« no previous file with comments | « no previous file | runtime/vm/object.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698