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

Unified Diff: vm/resolver.cc

Issue 10873004: Use kInstanceCid instead of object_store()->object_class() when checking to see if the class is obj… (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/runtime/
Patch Set: 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 | « vm/object.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: vm/resolver.cc
===================================================================
--- vm/resolver.cc (revision 11121)
+++ vm/resolver.cc (working copy)
@@ -26,12 +26,10 @@
int num_named_arguments) {
// Figure out type of receiver first.
Class& cls = Class::Handle();
- if (receiver.IsNull()) {
- // For method lookup treat null object as instance of Object.
- // TODO(srdjan): Remove special case once Dart's NullClass is implemented.
+ cls = receiver.clazz();
+ // For lookups treat null as an instance of class Object.
+ if (cls.IsNullClass()) {
cls = Isolate::Current()->object_store()->object_class();
- } else {
- cls = receiver.clazz();
}
ASSERT(!cls.IsNull());
« no previous file with comments | « vm/object.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698