| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2005, 2006, 2008, 2010, 2013 Apple Inc. All rights reserved. | 2 * Copyright (C) 2005, 2006, 2008, 2010, 2013 Apple Inc. All rights reserved. |
| 3 * Copyright (C) 2010 Patrick Gansterer <paroga@paroga.com> | 3 * Copyright (C) 2010 Patrick Gansterer <paroga@paroga.com> |
| 4 * | 4 * |
| 5 * This library is free software; you can redistribute it and/or | 5 * This library is free software; you can redistribute it and/or |
| 6 * modify it under the terms of the GNU Library General Public | 6 * modify it under the terms of the GNU Library General Public |
| 7 * License as published by the Free Software Foundation; either | 7 * License as published by the Free Software Foundation; either |
| 8 * version 2 of the License, or (at your option) any later version. | 8 * version 2 of the License, or (at your option) any later version. |
| 9 * | 9 * |
| 10 * This library is distributed in the hope that it will be useful, | 10 * This library is distributed in the hope that it will be useful, |
| 11 * but WITHOUT ANY WARRANTY; without even the implied warranty of | 11 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | 12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
| 13 * Library General Public License for more details. | 13 * Library General Public License for more details. |
| 14 * | 14 * |
| 15 * You should have received a copy of the GNU Library General Public License | 15 * You should have received a copy of the GNU Library General Public License |
| 16 * along with this library; see the file COPYING.LIB. If not, write to | 16 * along with this library; see the file COPYING.LIB. If not, write to |
| 17 * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, | 17 * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, |
| 18 * Boston, MA 02110-1301, USA. | 18 * Boston, MA 02110-1301, USA. |
| 19 * | 19 * |
| 20 */ | 20 */ |
| 21 | 21 |
| 22 #ifndef WTF_StringHasher_h | 22 #ifndef WTF_StringHasher_h |
| 23 #define WTF_StringHasher_h | 23 #define WTF_StringHasher_h |
| 24 | 24 |
| 25 #include <wtf/unicode/Unicode.h> | 25 #include "wtf/unicode/Unicode.h" |
| 26 | 26 |
| 27 namespace WTF { | 27 namespace WTF { |
| 28 | 28 |
| 29 // Paul Hsieh's SuperFastHash | 29 // Paul Hsieh's SuperFastHash |
| 30 // http://www.azillionmonkeys.com/qed/hash.html | 30 // http://www.azillionmonkeys.com/qed/hash.html |
| 31 | 31 |
| 32 // LChar data is interpreted as Latin-1-encoded (zero extended to 16 bits). | 32 // LChar data is interpreted as Latin-1-encoded (zero extended to 16 bits). |
| 33 | 33 |
| 34 // NOTE: The hash computation here must stay in sync with the create_hash_table
script in | 34 // NOTE: The hash computation here must stay in sync with the create_hash_table
script in |
| 35 // JavaScriptCore and the CodeGeneratorJS.pm script in WebCore. | 35 // JavaScriptCore and the CodeGeneratorJS.pm script in WebCore. |
| (...skipping 251 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 287 unsigned m_hash; | 287 unsigned m_hash; |
| 288 bool m_hasPendingCharacter; | 288 bool m_hasPendingCharacter; |
| 289 UChar m_pendingCharacter; | 289 UChar m_pendingCharacter; |
| 290 }; | 290 }; |
| 291 | 291 |
| 292 } // namespace WTF | 292 } // namespace WTF |
| 293 | 293 |
| 294 using WTF::StringHasher; | 294 using WTF::StringHasher; |
| 295 | 295 |
| 296 #endif // WTF_StringHasher_h | 296 #endif // WTF_StringHasher_h |
| OLD | NEW |