[PATCH] D66265: [NFCI] Always initialize BugReport const fields
Alex Langford via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Wed Aug 14 17:58:09 PDT 2019
This revision was automatically updated to reflect the committed changes.
Closed by commit rL368950: [NFCI] Always initialize BugReport const fields (authored by xiaobai, committed by ).
Herald added a project: LLVM.
Changed prior to commit:
https://reviews.llvm.org/D66265?vs=215292&id=215299#toc
Repository:
rL LLVM
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D66265/new/
https://reviews.llvm.org/D66265
Files:
cfe/trunk/include/clang/StaticAnalyzer/Core/BugReporter/BugReporter.h
Index: cfe/trunk/include/clang/StaticAnalyzer/Core/BugReporter/BugReporter.h
===================================================================
--- cfe/trunk/include/clang/StaticAnalyzer/Core/BugReporter/BugReporter.h
+++ cfe/trunk/include/clang/StaticAnalyzer/Core/BugReporter/BugReporter.h
@@ -180,10 +180,12 @@
/// to the user. This method allows to rest the location which should be used
/// for uniquing reports. For example, memory leaks checker, could set this to
/// the allocation site, rather then the location where the bug is reported.
- BugReport(BugType& bt, StringRef desc, const ExplodedNode *errornode,
+ BugReport(BugType &bt, StringRef desc, const ExplodedNode *errornode,
PathDiagnosticLocation LocationToUnique, const Decl *DeclToUnique)
: BT(bt), Description(desc), UniqueingLocation(LocationToUnique),
- UniqueingDecl(DeclToUnique), ErrorNode(errornode) {}
+ UniqueingDecl(DeclToUnique), ErrorNode(errornode),
+ ErrorNodeRange(getStmt() ? getStmt()->getSourceRange()
+ : SourceRange()) {}
virtual ~BugReport() = default;
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D66265.215299.patch
Type: text/x-patch
Size: 1136 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20190815/4fcd903e/attachment.bin>
More information about the cfe-commits
mailing list