summaryrefslogtreecommitdiffstats
path: root/clang/lib
diff options
context:
space:
mode:
authorJan Korous <jkorous@apple.com>2017-10-10 00:35:16 +0000
committerJan Korous <jkorous@apple.com>2017-10-10 00:35:16 +0000
commite6a0242ebc5f256d4589af4d0b87bee27962f5fe (patch)
tree90af53c4c0f0cbcb2c13a8be0876581b6174e1fd /clang/lib
parentdcb312bdb9616c19f1e58afc9d06b49f81f648e8 (diff)
downloadbcm5719-llvm-e6a0242ebc5f256d4589af4d0b87bee27962f5fe.tar.gz
bcm5719-llvm-e6a0242ebc5f256d4589af4d0b87bee27962f5fe.zip
R13575: Fix USR mangling for function pointer types
Differential Revision: https://reviews.llvm.org/D38707 llvm-svn: 315255
Diffstat (limited to 'clang/lib')
-rw-r--r--clang/lib/Index/USRGeneration.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/clang/lib/Index/USRGeneration.cpp b/clang/lib/Index/USRGeneration.cpp
index 81e143858e6..3a06554b256 100644
--- a/clang/lib/Index/USRGeneration.cpp
+++ b/clang/lib/Index/USRGeneration.cpp
@@ -754,8 +754,12 @@ void USRGenerator::VisitType(QualType T) {
if (const FunctionProtoType *FT = T->getAs<FunctionProtoType>()) {
Out << 'F';
VisitType(FT->getReturnType());
- for (const auto &I : FT->param_types())
+ Out << '(';
+ for (const auto &I : FT->param_types()) {
+ Out << '#';
VisitType(I);
+ }
+ Out << ')';
if (FT->isVariadic())
Out << '.';
return;
OpenPOWER on IntegriCloud