summaryrefslogtreecommitdiffstats
path: root/clang/unittests/AST/DeclPrinterTest.cpp
diff options
context:
space:
mode:
authorRichard Smith <richard-llvm@metafoo.co.uk>2014-01-22 00:27:42 +0000
committerRichard Smith <richard-llvm@metafoo.co.uk>2014-01-22 00:27:42 +0000
commite81daee21b6aa9a2f80941103f1a32f36a0b4ec9 (patch)
tree338c80f191e165c7f7e74a7c18820306621b24d9 /clang/unittests/AST/DeclPrinterTest.cpp
parent6ba68f10c4f6b5f9f068b29def27cb6f6a55b11d (diff)
downloadbcm5719-llvm-e81daee21b6aa9a2f80941103f1a32f36a0b4ec9.tar.gz
bcm5719-llvm-e81daee21b6aa9a2f80941103f1a32f36a0b4ec9.zip
When formatting a C++-only declaration name, enable C++ mode in the formatter's
language options. This is not really ideal -- we should require the right language options to be passed in, or not require language options to format a name -- but it fixes a number of *obviously* wrong formattings. Patch by Olivier Goffart! llvm-svn: 199778
Diffstat (limited to 'clang/unittests/AST/DeclPrinterTest.cpp')
-rw-r--r--clang/unittests/AST/DeclPrinterTest.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/unittests/AST/DeclPrinterTest.cpp b/clang/unittests/AST/DeclPrinterTest.cpp
index 33c51363e9d..ade55aaee36 100644
--- a/clang/unittests/AST/DeclPrinterTest.cpp
+++ b/clang/unittests/AST/DeclPrinterTest.cpp
@@ -558,7 +558,7 @@ TEST(DeclPrinter, TestCXXConversionDecl3) {
" operator Z();"
"};",
methodDecl(ofClass(hasName("A"))).bind("id"),
- "Z operator struct Z()"));
+ "Z operator Z()"));
// WRONG; Should be: "operator Z();"
}
OpenPOWER on IntegriCloud