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

Unified Diff: vm/dart_api_impl.cc

Issue 10196003: Dart_IsSame -> Dart_IdentityEquals. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/runtime/
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 | « include/dart_api.h ('k') | vm/dart_api_impl_test.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: vm/dart_api_impl.cc
===================================================================
--- vm/dart_api_impl.cc (revision 6862)
+++ vm/dart_api_impl.cc (working copy)
@@ -396,14 +396,11 @@
}
-DART_EXPORT Dart_Handle Dart_IsSame(Dart_Handle obj1, Dart_Handle obj2,
- bool* value) {
+DART_EXPORT bool Dart_IdentityEquals(Dart_Handle obj1, Dart_Handle obj2) {
Isolate* isolate = Isolate::Current();
- DARTSCOPE(isolate);
- const Object& expected = Object::Handle(isolate, Api::UnwrapHandle(obj1));
- const Object& actual = Object::Handle(isolate, Api::UnwrapHandle(obj2));
- *value = (expected.raw() == actual.raw());
- return Api::Success(isolate);
+ CHECK_ISOLATE(isolate);
+ NoGCScope ngc;
+ return Api::UnwrapHandle(obj1) == Api::UnwrapHandle(obj2);
}
« no previous file with comments | « include/dart_api.h ('k') | vm/dart_api_impl_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698