aboutsummaryrefslogtreecommitdiff
path: root/unittests/Format/FormatTest.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'unittests/Format/FormatTest.cpp')
-rw-r--r--unittests/Format/FormatTest.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/unittests/Format/FormatTest.cpp b/unittests/Format/FormatTest.cpp
index 1d3463ccfd..3c929a3f53 100644
--- a/unittests/Format/FormatTest.cpp
+++ b/unittests/Format/FormatTest.cpp
@@ -1519,13 +1519,17 @@ TEST_F(FormatTest, UnderstandContextOfRecordTypeKeywords) {
// Actual definitions...
verifyFormat("struct {} n;");
- verifyFormat("template <template <class T, class Y>, class Z > class X {} n;");
+ verifyFormat(
+ "template <template <class T, class Y>, class Z > class X {} n;");
verifyFormat("union Z {\n int n;\n} x;");
verifyFormat("class MACRO Z {} n;");
verifyFormat("class MACRO(X) Z {} n;");
verifyFormat("class __attribute__(X) Z {} n;");
verifyFormat("class __declspec(X) Z {} n;");
+ // Redefinition from nested context:
+ verifyFormat("class A::B::C {} n;");
+
// Elaborate types where incorrectly parsing the structural element would
// break the indent.
verifyFormat("if (true)\n"