| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
| 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
| 4 * (C) 2001 Dirk Mueller ( mueller@kde.org ) | 4 * (C) 2001 Dirk Mueller ( mueller@kde.org ) |
| 5 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2013 Apple Inc. All | 5 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2013 Apple Inc. All |
| 6 * rights reserved. | 6 * rights reserved. |
| 7 * Copyright (C) 2006 Andrew Wellington (proton@wiretapped.net) | 7 * Copyright (C) 2006 Andrew Wellington (proton@wiretapped.net) |
| 8 * | 8 * |
| 9 * This library is free software; you can redistribute it and/or | 9 * This library is free software; you can redistribute it and/or |
| 10 * modify it under the terms of the GNU Library General Public | 10 * modify it under the terms of the GNU Library General Public |
| (...skipping 287 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 298 | 298 |
| 299 if (isAtomic()) | 299 if (isAtomic()) |
| 300 AtomicStringTable::instance().remove(this); | 300 AtomicStringTable::instance().remove(this); |
| 301 } | 301 } |
| 302 | 302 |
| 303 void StringImpl::destroyIfNotStatic() { | 303 void StringImpl::destroyIfNotStatic() { |
| 304 if (!isStatic()) | 304 if (!isStatic()) |
| 305 delete this; | 305 delete this; |
| 306 } | 306 } |
| 307 | 307 |
| 308 void StringImpl::updateContainsOnlyASCII() const { |
| 309 m_containsOnlyASCII = is8Bit() |
| 310 ? charactersAreAllASCII(characters8(), length()) |
| 311 : charactersAreAllASCII(characters16(), length()); |
| 312 m_needsASCIICheck = false; |
| 313 } |
| 314 |
| 308 bool StringImpl::isSafeToSendToAnotherThread() const { | 315 bool StringImpl::isSafeToSendToAnotherThread() const { |
| 309 if (isStatic()) | 316 if (isStatic()) |
| 310 return true; | 317 return true; |
| 311 // AtomicStrings are not safe to send between threads as ~StringImpl() | 318 // AtomicStrings are not safe to send between threads as ~StringImpl() |
| 312 // will try to remove them from the wrong AtomicStringTable. | 319 // will try to remove them from the wrong AtomicStringTable. |
| 313 if (isAtomic()) | 320 if (isAtomic()) |
| 314 return false; | 321 return false; |
| 315 if (hasOneRef()) | 322 if (hasOneRef()) |
| 316 return true; | 323 return true; |
| 317 return false; | 324 return false; |
| (...skipping 1852 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2170 } else if (localeIdMatchesLang(localeIdentifier, "lt")) { | 2177 } else if (localeIdMatchesLang(localeIdentifier, "lt")) { |
| 2171 // TODO(rob.buis) implement upper-casing rules for lt | 2178 // TODO(rob.buis) implement upper-casing rules for lt |
| 2172 // like in StringImpl::upper(locale). | 2179 // like in StringImpl::upper(locale). |
| 2173 } | 2180 } |
| 2174 } | 2181 } |
| 2175 | 2182 |
| 2176 return toUpper(c); | 2183 return toUpper(c); |
| 2177 } | 2184 } |
| 2178 | 2185 |
| 2179 } // namespace WTF | 2186 } // namespace WTF |
| OLD | NEW |