summaryrefslogtreecommitdiffstats
path: root/clang/include
diff options
context:
space:
mode:
authorGeorge Karpenkov <ekarpenkov@apple.com>2019-01-18 03:13:14 +0000
committerGeorge Karpenkov <ekarpenkov@apple.com>2019-01-18 03:13:14 +0000
commit0029c3b64cbf109813a35ecba1829af8ab97e3cb (patch)
treec68682c3dccbfc2b01af1a12190fd1172423c0d5 /clang/include
parent1aa2bf8ea4dac56005be68f958c81df8f66c0f49 (diff)
downloadbcm5719-llvm-0029c3b64cbf109813a35ecba1829af8ab97e3cb.tar.gz
bcm5719-llvm-0029c3b64cbf109813a35ecba1829af8ab97e3cb.zip
[analyzer] const-ify reference to bug type used in BugReporter
Differential Revision: https://reviews.llvm.org/D56885 llvm-svn: 351511
Diffstat (limited to 'clang/include')
-rw-r--r--clang/include/clang/StaticAnalyzer/Core/BugReporter/BugReporter.h12
1 files changed, 6 insertions, 6 deletions
diff --git a/clang/include/clang/StaticAnalyzer/Core/BugReporter/BugReporter.h b/clang/include/clang/StaticAnalyzer/Core/BugReporter/BugReporter.h
index 9041f4c1afb..f830dc475b9 100644
--- a/clang/include/clang/StaticAnalyzer/Core/BugReporter/BugReporter.h
+++ b/clang/include/clang/StaticAnalyzer/Core/BugReporter/BugReporter.h
@@ -95,7 +95,7 @@ protected:
friend class BugReportEquivClass;
friend class BugReporter;
- BugType& BT;
+ const BugType& BT;
const Decl *DeclWithIssue = nullptr;
std::string ShortDescription;
std::string Description;
@@ -164,15 +164,15 @@ private:
void popInterestingSymbolsAndRegions();
public:
- BugReport(BugType& bt, StringRef desc, const ExplodedNode *errornode)
+ BugReport(const BugType& bt, StringRef desc, const ExplodedNode *errornode)
: BT(bt), Description(desc), ErrorNode(errornode) {}
- BugReport(BugType& bt, StringRef shortDesc, StringRef desc,
+ BugReport(const BugType& bt, StringRef shortDesc, StringRef desc,
const ExplodedNode *errornode)
: BT(bt), ShortDescription(shortDesc), Description(desc),
ErrorNode(errornode) {}
- BugReport(BugType &bt, StringRef desc, PathDiagnosticLocation l)
+ BugReport(const BugType &bt, StringRef desc, PathDiagnosticLocation l)
: BT(bt), Description(desc), Location(l) {}
/// Create a BugReport with a custom uniqueing location.
@@ -190,7 +190,7 @@ public:
virtual ~BugReport();
const BugType& getBugType() const { return BT; }
- BugType& getBugType() { return BT; }
+ //BugType& getBugType() { return BT; }
/// True when the report has an execution path associated with it.
///
@@ -481,7 +481,7 @@ public:
return {};
}
- void Register(BugType *BT);
+ void Register(const BugType *BT);
/// Add the given report to the set of reports tracked by BugReporter.
///
OpenPOWER on IntegriCloud