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

Unified Diff: vm/object.h

Issue 9232017: Improve function compilation times for swarm application startup. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/runtime/
Patch Set: '' Created 8 years, 11 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 | vm/object.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: vm/object.h
===================================================================
--- vm/object.h (revision 3380)
+++ vm/object.h (working copy)
@@ -2633,6 +2633,15 @@
virtual intptr_t CharSize() const;
+ bool Equals(const String& str) const {
+ if (raw() == str.raw()) {
+ return true; // Both handles point to the same raw instance.
+ }
+ if (str.IsNull()) {
+ return false;
+ }
Ivan Posva 2012/01/18 19:44:30 Do you want to inline the hash check here?
siva 2012/01/18 20:01:06 As discussed offline, introducing the hash check s
+ return Equals(str, 0, str.Length());
+ }
bool Equals(const String& str, intptr_t begin_index, intptr_t len) const;
bool Equals(const char* str) const;
bool Equals(const uint8_t* characters, intptr_t len) const;
« no previous file with comments | « no previous file | vm/object.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698