1a1401311d1ab56c4ed0a474bd38c108f75cb0cd9Torne (Richard Coles)// Copyright 2014 The Chromium Authors. All rights reserved.
2a1401311d1ab56c4ed0a474bd38c108f75cb0cd9Torne (Richard Coles)// Use of this source code is governed by a BSD-style license that can be
3a1401311d1ab56c4ed0a474bd38c108f75cb0cd9Torne (Richard Coles)// found in the LICENSE file.
45821806d5e7f356e8fa4b058a389a808ea183019Torne (Richard Coles)
55821806d5e7f356e8fa4b058a389a808ea183019Torne (Richard Coles)#include "base/hash.h"
65821806d5e7f356e8fa4b058a389a808ea183019Torne (Richard Coles)
7a1401311d1ab56c4ed0a474bd38c108f75cb0cd9Torne (Richard Coles)// Definition in base/third_party/superfasthash/superfasthash.c. (Third-party
8a1401311d1ab56c4ed0a474bd38c108f75cb0cd9Torne (Richard Coles)// code did not come with its own header file, so declaring the function here.)
9a1401311d1ab56c4ed0a474bd38c108f75cb0cd9Torne (Richard Coles)// Note: This algorithm is also in Blink under Source/wtf/StringHasher.h.
10a1401311d1ab56c4ed0a474bd38c108f75cb0cd9Torne (Richard Coles)extern "C" uint32_t SuperFastHash(const char* data, int len);
115821806d5e7f356e8fa4b058a389a808ea183019Torne (Richard Coles)
125821806d5e7f356e8fa4b058a389a808ea183019Torne (Richard Coles)namespace base {
135821806d5e7f356e8fa4b058a389a808ea183019Torne (Richard Coles)
14a1401311d1ab56c4ed0a474bd38c108f75cb0cd9Torne (Richard Coles)uint32 SuperFastHash(const char* data, int len) {
15a1401311d1ab56c4ed0a474bd38c108f75cb0cd9Torne (Richard Coles)  return ::SuperFastHash(data, len);
165821806d5e7f356e8fa4b058a389a808ea183019Torne (Richard Coles)}
175821806d5e7f356e8fa4b058a389a808ea183019Torne (Richard Coles)
185821806d5e7f356e8fa4b058a389a808ea183019Torne (Richard Coles)}  // namespace base
19