Switch LangOptions over to a .def file that describes header of the
language options. Use that .def file to declare the LangOptions class
and initialize all of its members, eliminating a source of annoying
initialization bugs.
AST serialization changes are next up.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@139605 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/StaticAnalyzer/Checkers/RetainCountChecker.cpp b/lib/StaticAnalyzer/Checkers/RetainCountChecker.cpp
index cf06f54..9715133 100644
--- a/lib/StaticAnalyzer/Checkers/RetainCountChecker.cpp
+++ b/lib/StaticAnalyzer/Checkers/RetainCountChecker.cpp
@@ -1772,7 +1772,7 @@
bool GCEnabled) {
const char *GCModeDescription = 0;
- switch (LOpts.getGCMode()) {
+ switch (LOpts.getGC()) {
case LangOptions::GCOnly:
assert(GCEnabled);
GCModeDescription = "Code is compiled to only use garbage collection";
@@ -2354,7 +2354,7 @@
return leakWithinFunctionGC.get();
} else {
if (!leakWithinFunction) {
- if (LOpts.getGCMode() == LangOptions::HybridGC) {
+ if (LOpts.getGC() == LangOptions::HybridGC) {
leakWithinFunction.reset(new LeakWithinFunction("Leak of object when "
"not using garbage "
"collection (GC) in "
@@ -2376,7 +2376,7 @@
return leakAtReturnGC.get();
} else {
if (!leakAtReturn) {
- if (LOpts.getGCMode() == LangOptions::HybridGC) {
+ if (LOpts.getGC() == LangOptions::HybridGC) {
leakAtReturn.reset(new LeakAtReturn("Leak of returned object when "
"not using garbage collection "
"(GC) in dual GC/non-GC code"));