summaryrefslogtreecommitdiffstats
path: root/clang/lib/Analysis/ProgramPoint.cpp
diff options
context:
space:
mode:
authorCsaba Dabis <dabis.csaba98@gmail.com>2019-05-29 18:21:14 +0000
committerCsaba Dabis <dabis.csaba98@gmail.com>2019-05-29 18:21:14 +0000
commit02be650617a5c8812e5c4696bcbbab284fe83acd (patch)
tree1b74f5dc918e63e5a00df74485975822e7518396 /clang/lib/Analysis/ProgramPoint.cpp
parentd5443f8c21b11cfa8214b192a53f24cda14230a3 (diff)
downloadbcm5719-llvm-02be650617a5c8812e5c4696bcbbab284fe83acd.tar.gz
bcm5719-llvm-02be650617a5c8812e5c4696bcbbab284fe83acd.zip
[analyzer] print() JSONify: Decl revision
Summary: - Reviewers: NoQ, xazax.hun, ravikandhadai, baloghadamsoftware, Szelethus Reviewed By: NoQ Subscribers: cfe-commits, szepet, rnkovacs, a.sidorin, mikhail.ramalho, donat.nagy, dkrupp Tags: #clang Differential Revision: https://reviews.llvm.org/D62495 llvm-svn: 362002
Diffstat (limited to 'clang/lib/Analysis/ProgramPoint.cpp')
-rw-r--r--clang/lib/Analysis/ProgramPoint.cpp10
1 files changed, 4 insertions, 6 deletions
diff --git a/clang/lib/Analysis/ProgramPoint.cpp b/clang/lib/Analysis/ProgramPoint.cpp
index fb29300f520..32ae439c8ca 100644
--- a/clang/lib/Analysis/ProgramPoint.cpp
+++ b/clang/lib/Analysis/ProgramPoint.cpp
@@ -116,18 +116,16 @@ void ProgramPoint::printJson(llvm::raw_ostream &Out, const char *NL) const {
case ProgramPoint::PreImplicitCallKind: {
ImplicitCallPoint PC = castAs<ImplicitCallPoint>();
- Out << "PreCall\", \"stmt\": \"";
- PC.getDecl()->print(Out, Context.getLangOpts());
- Out << "\", ";
+ Out << "PreCall\", \"decl\": \""
+ << PC.getDecl()->getAsFunction()->getQualifiedNameAsString() << "\", ";
printLocJson(Out, PC.getLocation(), SM);
break;
}
case ProgramPoint::PostImplicitCallKind: {
ImplicitCallPoint PC = castAs<ImplicitCallPoint>();
- Out << "PostCall\", \"stmt\": \"";
- PC.getDecl()->print(Out, Context.getLangOpts());
- Out << "\", ";
+ Out << "PostCall\", \"decl\": \""
+ << PC.getDecl()->getAsFunction()->getQualifiedNameAsString() << "\", ";
printLocJson(Out, PC.getLocation(), SM);
break;
}
OpenPOWER on IntegriCloud