| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2007, 2008, 2009, 2011 Apple Inc. All rights reserved. | 2 * Copyright (C) 2007, 2008, 2009, 2011 Apple Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * | 7 * |
| 8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
| (...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 169 } | 169 } |
| 170 | 170 |
| 171 template<typename CharType> inline bool isASCIIAlphaCaselessEqual(CharType cssCh
aracter, char character) | 171 template<typename CharType> inline bool isASCIIAlphaCaselessEqual(CharType cssCh
aracter, char character) |
| 172 { | 172 { |
| 173 // This function compares a (preferrably) constant ASCII | 173 // This function compares a (preferrably) constant ASCII |
| 174 // lowercase letter to any input character. | 174 // lowercase letter to any input character. |
| 175 ASSERT(character >= 'a' && character <= 'z'); | 175 ASSERT(character >= 'a' && character <= 'z'); |
| 176 return LIKELY(toASCIILowerUnchecked(cssCharacter) == character); | 176 return LIKELY(toASCIILowerUnchecked(cssCharacter) == character); |
| 177 } | 177 } |
| 178 | 178 |
| 179 } | 179 } // namespace WTF |
| 180 | 180 |
| 181 using WTF::isASCII; | 181 using WTF::isASCII; |
| 182 using WTF::isASCIIAlpha; | 182 using WTF::isASCIIAlpha; |
| 183 using WTF::isASCIIAlphanumeric; | 183 using WTF::isASCIIAlphanumeric; |
| 184 using WTF::isASCIIDigit; | 184 using WTF::isASCIIDigit; |
| 185 using WTF::isASCIIHexDigit; | 185 using WTF::isASCIIHexDigit; |
| 186 using WTF::isASCIILower; | 186 using WTF::isASCIILower; |
| 187 using WTF::isASCIIOctalDigit; | 187 using WTF::isASCIIOctalDigit; |
| 188 using WTF::isASCIIPrintable; | 188 using WTF::isASCIIPrintable; |
| 189 using WTF::isASCIISpace; | 189 using WTF::isASCIISpace; |
| 190 using WTF::isASCIIUpper; | 190 using WTF::isASCIIUpper; |
| 191 using WTF::toASCIIHexValue; | 191 using WTF::toASCIIHexValue; |
| 192 using WTF::toASCIILower; | 192 using WTF::toASCIILower; |
| 193 using WTF::toASCIILowerUnchecked; | 193 using WTF::toASCIILowerUnchecked; |
| 194 using WTF::toASCIIUpper; | 194 using WTF::toASCIIUpper; |
| 195 using WTF::lowerNibbleToASCIIHexDigit; | 195 using WTF::lowerNibbleToASCIIHexDigit; |
| 196 using WTF::upperNibbleToASCIIHexDigit; | 196 using WTF::upperNibbleToASCIIHexDigit; |
| 197 using WTF::isASCIIAlphaCaselessEqual; | 197 using WTF::isASCIIAlphaCaselessEqual; |
| 198 | 198 |
| 199 #endif | 199 #endif |
| OLD | NEW |