| 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 |
| 11 * License as published by the Free Software Foundation; either | 11 * License as published by the Free Software Foundation; either |
| 12 * version 2 of the License, or (at your option) any later version. | 12 * version 2 of the License, or (at your option) any later version. |
| 13 * | 13 * |
| 14 * This library is distributed in the hope that it will be useful, | 14 * This library is distributed in the hope that it will be useful, |
| 15 * but WITHOUT ANY WARRANTY; without even the implied warranty of | 15 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | 16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
| 17 * Library General Public License for more details. | 17 * Library General Public License for more details. |
| 18 * | 18 * |
| 19 * You should have received a copy of the GNU Library General Public License | 19 * You should have received a copy of the GNU Library General Public License |
| 20 * along with this library; see the file COPYING.LIB. If not, write to | 20 * along with this library; see the file COPYING.LIB. If not, write to |
| 21 * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, | 21 * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, |
| 22 * Boston, MA 02110-1301, USA. | 22 * Boston, MA 02110-1301, USA. |
| 23 * | 23 * |
| 24 */ | 24 */ |
| 25 | 25 |
| 26 #include "wtf/text/StringImpl.h" | 26 #include "wtf/text/StringImpl.h" |
| 27 | 27 |
| 28 #include <algorithm> |
| 29 #include <memory> |
| 28 #include "wtf/DynamicAnnotations.h" | 30 #include "wtf/DynamicAnnotations.h" |
| 29 #include "wtf/LeakAnnotations.h" | 31 #include "wtf/LeakAnnotations.h" |
| 30 #include "wtf/PtrUtil.h" | 32 #include "wtf/PtrUtil.h" |
| 31 #include "wtf/StaticConstructors.h" | 33 #include "wtf/StaticConstructors.h" |
| 32 #include "wtf/StdLibExtras.h" | 34 #include "wtf/StdLibExtras.h" |
| 33 #include "wtf/allocator/Partitions.h" | 35 #include "wtf/allocator/Partitions.h" |
| 34 #include "wtf/text/AtomicString.h" | 36 #include "wtf/text/AtomicString.h" |
| 35 #include "wtf/text/AtomicStringTable.h" | 37 #include "wtf/text/AtomicStringTable.h" |
| 36 #include "wtf/text/CString.h" | 38 #include "wtf/text/CString.h" |
| 37 #include "wtf/text/CharacterNames.h" | 39 #include "wtf/text/CharacterNames.h" |
| 38 #include "wtf/text/StringBuffer.h" | 40 #include "wtf/text/StringBuffer.h" |
| 39 #include "wtf/text/StringHash.h" | 41 #include "wtf/text/StringHash.h" |
| 40 #include "wtf/text/StringToNumber.h" | 42 #include "wtf/text/StringToNumber.h" |
| 41 #include <algorithm> | |
| 42 #include <memory> | |
| 43 | 43 |
| 44 #ifdef STRING_STATS | 44 #ifdef STRING_STATS |
| 45 #include <unistd.h> |
| 45 #include "wtf/DataLog.h" | 46 #include "wtf/DataLog.h" |
| 46 #include "wtf/HashMap.h" | 47 #include "wtf/HashMap.h" |
| 47 #include "wtf/HashSet.h" | 48 #include "wtf/HashSet.h" |
| 48 #include "wtf/RefCounted.h" | 49 #include "wtf/RefCounted.h" |
| 49 #include "wtf/ThreadingPrimitives.h" | 50 #include "wtf/ThreadingPrimitives.h" |
| 50 #include <unistd.h> | |
| 51 #endif | 51 #endif |
| 52 | 52 |
| 53 using namespace std; | 53 using namespace std; |
| 54 | 54 |
| 55 namespace WTF { | 55 namespace WTF { |
| 56 | 56 |
| 57 using namespace Unicode; | 57 using namespace Unicode; |
| 58 | 58 |
| 59 // As of Jan 2017, StringImpl needs 2 * sizeof(int) + 29 bits of data, and | 59 // As of Jan 2017, StringImpl needs 2 * sizeof(int) + 29 bits of data, and |
| 60 // sizeof(ThreadRestrictionVerifier) is 16 bytes. Thus, in DCHECK mode the | 60 // sizeof(ThreadRestrictionVerifier) is 16 bytes. Thus, in DCHECK mode the |
| (...skipping 2152 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2213 } else if (localeIdMatchesLang(localeIdentifier, "lt")) { | 2213 } else if (localeIdMatchesLang(localeIdentifier, "lt")) { |
| 2214 // TODO(rob.buis) implement upper-casing rules for lt | 2214 // TODO(rob.buis) implement upper-casing rules for lt |
| 2215 // like in StringImpl::upper(locale). | 2215 // like in StringImpl::upper(locale). |
| 2216 } | 2216 } |
| 2217 } | 2217 } |
| 2218 | 2218 |
| 2219 return toUpper(c); | 2219 return toUpper(c); |
| 2220 } | 2220 } |
| 2221 | 2221 |
| 2222 } // namespace WTF | 2222 } // namespace WTF |
| OLD | NEW |