Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(51)

Unified Diff: tools/clang/rewrite_to_chrome_style/tests/template-expected.cc

Issue 2640283003: Look at canonical decl, when deciding whether to rename or not. (Closed)
Patch Set: Fixed handling of function template specializations. Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: tools/clang/rewrite_to_chrome_style/tests/template-expected.cc
diff --git a/tools/clang/rewrite_to_chrome_style/tests/template-expected.cc b/tools/clang/rewrite_to_chrome_style/tests/template-expected.cc
index 5c9103d9420183593442e72bb47d7f7fe8e17bf9..b6311ecc05a4977998ce3ba8fb4b804da33b6335 100644
--- a/tools/clang/rewrite_to_chrome_style/tests/template-expected.cc
+++ b/tools/clang/rewrite_to_chrome_style/tests/template-expected.cc
@@ -338,6 +338,31 @@ class IntrusiveHeap {
} // namespace blacklisting_of_renaming_of_begin_method
+namespace specializations {
+
+template <unsigned long sizeOfValue>
+int ToV8SignedIntegerInternal(long value);
+
+template <>
+int ToV8SignedIntegerInternal<4>(long value) {
+ return 123 + value;
+}
+
+template <>
+int ToV8SignedIntegerInternal<8>(long value) {
+ return 456 + value;
+}
+
+int ToV8(int value) {
+ return ToV8SignedIntegerInternal<sizeof value>(value);
+}
+
+int ToV8(long value) {
+ return ToV8SignedIntegerInternal<sizeof value>(value);
+}
+
+} // namespace specializations
+
Łukasz Anforowicz 2017/01/21 01:04:01 These tests are somewhat unrelated to the main cha
} // namespace blink
namespace not_blink {

Powered by Google App Engine
This is Rietveld 408576698