clang-format: Understand that "auto" is a type.
Before:
MACRO(auto * a);
After:
MACRO(auto *a);
llvm-svn: 205517
diff --git a/clang/unittests/Format/FormatTest.cpp b/clang/unittests/Format/FormatTest.cpp
index 62ca9ff..5395fd9 100644
--- a/clang/unittests/Format/FormatTest.cpp
+++ b/clang/unittests/Format/FormatTest.cpp
@@ -4554,6 +4554,12 @@
verifyFormat("foo<b && false>();");
verifyFormat("foo<b & 1>();");
+ verifyIndependentOfContext("MACRO(int *i);");
+ verifyIndependentOfContext("MACRO(auto *a);");
+ verifyIndependentOfContext("MACRO(const A *a);");
+ // FIXME: Is there a way to make this work?
+ // verifyIndependentOfContext("MACRO(A *a);");
+
// FIXME: We cannot handle this case yet; we might be able to figure out that
// foo<x> d > v; doesn't make sense.
verifyFormat("foo<a < b && c> d > v;");