summaryrefslogtreecommitdiffstats
path: root/clang/lib/Index/CommentToXML.cpp
diff options
context:
space:
mode:
authorAlex Lorenz <arphaman@gmail.com>2017-08-17 13:41:55 +0000
committerAlex Lorenz <arphaman@gmail.com>2017-08-17 13:41:55 +0000
commit36070ed8d261c231cf1bde460aec9ffde16f9ff7 (patch)
treecf060dc7b3fc8c8c6f3b1209063300cc004d274b /clang/lib/Index/CommentToXML.cpp
parent032e7f2cadebd5c8ea5b3179b15837285a6ab3af (diff)
downloadbcm5719-llvm-36070ed8d261c231cf1bde460aec9ffde16f9ff7.tar.gz
bcm5719-llvm-36070ed8d261c231cf1bde460aec9ffde16f9ff7.zip
Print enum constant values using the original source formatting
if possible when creating "Declaration" nodes in XML comments rdar://14765746 llvm-svn: 311085
Diffstat (limited to 'clang/lib/Index/CommentToXML.cpp')
-rw-r--r--clang/lib/Index/CommentToXML.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/clang/lib/Index/CommentToXML.cpp b/clang/lib/Index/CommentToXML.cpp
index e568c838b7b..918068a2405 100644
--- a/clang/lib/Index/CommentToXML.cpp
+++ b/clang/lib/Index/CommentToXML.cpp
@@ -579,6 +579,7 @@ void getSourceTextOfDeclaration(const DeclInfo *ThisDecl,
PrintingPolicy PPolicy(LangOpts);
PPolicy.PolishForDeclaration = true;
PPolicy.TerseOutput = true;
+ PPolicy.ConstantsAsWritten = true;
ThisDecl->CurrentDecl->print(OS, PPolicy,
/*Indentation*/0, /*PrintInstantiation*/false);
}
OpenPOWER on IntegriCloud