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

Unified Diff: src/objects.h

Issue 1812673005: Use ICU case conversion/transliterator for case conversion behind a flag (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: move toLocale{U,L}Case behind --icu-case-mapping, too; adjust test status accordingly. roll back st… Created 4 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
Index: src/objects.h
diff --git a/src/objects.h b/src/objects.h
index 148ec17c6d15e1755e1a22bd660633a7618bdd42..f2cff1d5aa252463ea3f0462469f5853c0605319 100644
--- a/src/objects.h
+++ b/src/objects.h
@@ -8640,26 +8640,26 @@ class String: public Name {
class FlatContent {
public:
// Returns true if the string is flat and this structure contains content.
- bool IsFlat() { return state_ != NON_FLAT; }
+ bool IsFlat() const { return state_ != NON_FLAT; }
// Returns true if the structure contains one-byte content.
- bool IsOneByte() { return state_ == ONE_BYTE; }
+ bool IsOneByte() const { return state_ == ONE_BYTE; }
// Returns true if the structure contains two-byte content.
- bool IsTwoByte() { return state_ == TWO_BYTE; }
+ bool IsTwoByte() const { return state_ == TWO_BYTE; }
// Return the one byte content of the string. Only use if IsOneByte()
// returns true.
- Vector<const uint8_t> ToOneByteVector() {
+ Vector<const uint8_t> ToOneByteVector() const {
DCHECK_EQ(ONE_BYTE, state_);
return Vector<const uint8_t>(onebyte_start, length_);
}
// Return the two-byte content of the string. Only use if IsTwoByte()
// returns true.
- Vector<const uc16> ToUC16Vector() {
+ Vector<const uc16> ToUC16Vector() const {
DCHECK_EQ(TWO_BYTE, state_);
return Vector<const uc16>(twobyte_start, length_);
}
- uc16 Get(int i) {
+ uc16 Get(int i) const {
DCHECK(i < length_);
DCHECK(state_ != NON_FLAT);
if (state_ == ONE_BYTE) return onebyte_start[i];
« src/js/icu-case-mapping.js ('K') | « src/js/prologue.js ('k') | src/runtime/runtime.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698