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

Unified Diff: src/objects.h

Issue 1444001: Some string optimizations: (Closed)
Patch Set: Review fix. Created 10 years, 9 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 | « src/heap.cc ('k') | src/objects.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/objects.h
diff --git a/src/objects.h b/src/objects.h
index d299d92a25737d74e6a86b2000994dabb8de0709..9197466e85e4564cfe29e38e814e4865e5c06a64 100644
--- a/src/objects.h
+++ b/src/objects.h
@@ -3926,6 +3926,13 @@ class String: public HeapObject {
inline bool IsAsciiRepresentation();
inline bool IsTwoByteRepresentation();
+ // Check whether this string is an external two-byte string that in
+ // fact contains only ascii characters.
+ //
+ // Such strings may appear when the embedder prefers two-byte
+ // representations even for ascii data.
+ inline bool IsExternalTwoByteStringWithAsciiChars();
+
// Get and set individual two byte chars in the string.
inline void Set(int index, uint16_t value);
// Get individual two byte char in the string. Repeated calls
« no previous file with comments | « src/heap.cc ('k') | src/objects.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698