aboutsummaryrefslogtreecommitdiffhomepage
path: root/tests/DynamicHashTest.cpp
diff options
context:
space:
mode:
authorGravatar commit-bot@chromium.org <commit-bot@chromium.org@2bbb7eff-a529-9590-31e7-b0007b416f81>2013-10-12 17:25:17 +0000
committerGravatar commit-bot@chromium.org <commit-bot@chromium.org@2bbb7eff-a529-9590-31e7-b0007b416f81>2013-10-12 17:25:17 +0000
commitddf94cf108ae430877f009bd67b9070341426947 (patch)
tree91dc1bc9cbc3bf48da2891adfe835e568dee9e1a /tests/DynamicHashTest.cpp
parentb202adec608c78236765e8c543e56e7a7ef695d7 (diff)
Remove unnamed namespace usage from tests.
Skia code prefers static over unnamed namespace. BUG=None TEST=None R=bsalomon@google.com, robertphillips@google.com Author: tfarina@chromium.org Review URL: https://codereview.chromium.org/26962002 git-svn-id: http://skia.googlecode.com/svn/trunk@11747 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'tests/DynamicHashTest.cpp')
-rw-r--r--tests/DynamicHashTest.cpp9
1 files changed, 8 insertions, 1 deletions
diff --git a/tests/DynamicHashTest.cpp b/tests/DynamicHashTest.cpp
index 2425ea24ca..f502dbae70 100644
--- a/tests/DynamicHashTest.cpp
+++ b/tests/DynamicHashTest.cpp
@@ -1,3 +1,10 @@
+/*
+ * Copyright 2013 Google Inc.
+ *
+ * Use of this source code is governed by a BSD-style license that can be
+ * found in the LICENSE file.
+ */
+
#include "Test.h"
#include "SkTDynamicHash.h"
@@ -7,11 +14,11 @@ struct Entry {
int key;
double value;
};
+
const int& GetKey(const Entry& entry) { return entry.key; }
uint32_t GetHash(const int& key) { return key; }
bool AreEqual(const Entry& entry, const int& key) { return entry.key == key; }
-
class Hash : public SkTDynamicHash<Entry, int, GetKey, GetHash, AreEqual> {
public:
Hash() : INHERITED() {}