Index: lib/StaticAnalyzer/Core/BugReporterVisitors.cpp =================================================================== --- lib/StaticAnalyzer/Core/BugReporterVisitors.cpp +++ lib/StaticAnalyzer/Core/BugReporterVisitors.cpp @@ -2043,18 +2043,17 @@ Loc, BRC.getSourceManager(), BRC.getASTContext().getLangOpts()); // Return the macro name. - Out << MacroName; + Out << '\'' << MacroName << '\''; return false; } } - if (const auto *DR = dyn_cast(Ex)) { - const bool quotes = isa(DR->getDecl()); - if (quotes) { - Out << '\''; + if (const auto *DRE = dyn_cast(Ex)) { + const bool IsVarDecl = isa(DRE->getDecl()); + if (IsVarDecl) { const LocationContext *LCtx = N->getLocationContext(); const ProgramState *state = N->getState().get(); - if (const MemRegion *R = state->getLValue(cast(DR->getDecl()), + if (const MemRegion *R = state->getLValue(cast(DRE->getDecl()), LCtx).getAsRegion()) { if (report.isInteresting(R)) prunable = false; @@ -2066,28 +2065,26 @@ } } } - Out << DR->getDecl()->getDeclName().getAsString(); - if (quotes) - Out << '\''; - return quotes; + Out << '\'' << DRE->getDecl()->getDeclName() << '\''; + return IsVarDecl; } if (const auto *IL = dyn_cast(Ex)) { QualType OriginalTy = OriginalExpr->getType(); if (OriginalTy->isPointerType()) { if (IL->getValue() == 0) { - Out << "null"; + Out << "'null'"; return false; } } else if (OriginalTy->isObjCObjectPointerType()) { if (IL->getValue() == 0) { - Out << "nil"; + Out << "'nil'"; return false; } } - Out << IL->getValue(); + Out << '\'' << IL->getValue() << '\''; return false; } @@ -2290,12 +2287,12 @@ QualType Ty = CondVarExpr->getType(); if (Ty->isPointerType()) { - Out << (TookTrue ? "non-null" : "null"); + Out << (TookTrue ? "'non-null'" : "'null'"); return true; } if (Ty->isObjCObjectPointerType()) { - Out << (TookTrue ? "non-nil" : "nil"); + Out << (TookTrue ? "'non-nil'" : "'nil'"); return true; } @@ -2308,12 +2305,12 @@ if (IsAssuming || !IntValue.hasValue()) { if (Ty->isBooleanType()) - Out << (TookTrue ? "true" : "false"); + Out << (TookTrue ? "'true'" : "'false'"); else - Out << (TookTrue ? "not equal to 0" : "0"); + Out << (TookTrue ? "not equal to '0'" : "'0'"); } else { if (Ty->isBooleanType()) - Out << (IntValue.getValue()->getBoolValue() ? "true" : "false"); + Out << (IntValue.getValue()->getBoolValue() ? "'true'" : "'false'"); else Out << *IntValue.getValue(); } Index: test/Analysis/Inputs/expected-plists/NewDelete-path-notes.cpp.plist =================================================================== --- test/Analysis/Inputs/expected-plists/NewDelete-path-notes.cpp.plist +++ test/Analysis/Inputs/expected-plists/NewDelete-path-notes.cpp.plist @@ -131,9 +131,9 @@ depth0 extended_message - 'p' is non-null + 'p' is 'non-null' message - 'p' is non-null + 'p' is 'non-null' kindcontrol Index: test/Analysis/Inputs/expected-plists/conditional-path-notes.c.plist =================================================================== --- test/Analysis/Inputs/expected-plists/conditional-path-notes.c.plist +++ test/Analysis/Inputs/expected-plists/conditional-path-notes.c.plist @@ -68,9 +68,9 @@ depth0 extended_message - Assuming 'p' is null + Assuming 'p' is 'null' message - Assuming 'p' is null + Assuming 'p' is 'null' kindcontrol @@ -354,9 +354,9 @@ depth0 extended_message - Assuming 'p' is null + Assuming 'p' is 'null' message - Assuming 'p' is null + Assuming 'p' is 'null' kindcontrol @@ -543,9 +543,9 @@ depth0 extended_message - Assuming 'p' is null + Assuming 'p' is 'null' message - Assuming 'p' is null + Assuming 'p' is 'null' kindcontrol @@ -697,9 +697,9 @@ depth0 extended_message - Assuming 'p' is null + Assuming 'p' is 'null' message - Assuming 'p' is null + Assuming 'p' is 'null' kindcontrol @@ -1006,9 +1006,9 @@ depth0 extended_message - Assuming 'p' is null + Assuming 'p' is 'null' message - Assuming 'p' is null + Assuming 'p' is 'null' kindcontrol @@ -1195,9 +1195,9 @@ depth0 extended_message - Assuming 'a' is not equal to 0 + Assuming 'a' is not equal to '0' message - Assuming 'a' is not equal to 0 + Assuming 'a' is not equal to '0' kindcontrol @@ -1384,9 +1384,9 @@ depth0 extended_message - Assuming 'a' is not equal to 0 + Assuming 'a' is not equal to '0' message - Assuming 'a' is not equal to 0 + Assuming 'a' is not equal to '0' kindcontrol @@ -1447,9 +1447,9 @@ depth0 extended_message - Assuming 'b' is not equal to 0 + Assuming 'b' is not equal to '0' message - Assuming 'b' is not equal to 0 + Assuming 'b' is not equal to '0' kindcontrol Index: test/Analysis/Inputs/expected-plists/cxx-for-range.cpp.plist =================================================================== --- test/Analysis/Inputs/expected-plists/cxx-for-range.cpp.plist +++ test/Analysis/Inputs/expected-plists/cxx-for-range.cpp.plist @@ -199,9 +199,9 @@ depth0 extended_message - 'y' is not equal to 2 + 'y' is not equal to '2' message - 'y' is not equal to 2 + 'y' is not equal to '2' kindcontrol @@ -524,9 +524,9 @@ depth0 extended_message - 'y' is equal to 2 + 'y' is equal to '2' message - 'y' is equal to 2 + 'y' is equal to '2' kindcontrol @@ -832,9 +832,9 @@ depth1 extended_message - 'fail' is true + 'fail' is 'true' message - 'fail' is true + 'fail' is 'true' kindcontrol @@ -1120,9 +1120,9 @@ depth0 extended_message - Assuming 'y' is equal to 2 + Assuming 'y' is equal to '2' message - Assuming 'y' is equal to 2 + Assuming 'y' is equal to '2' kindcontrol @@ -1570,9 +1570,9 @@ depth0 extended_message - Assuming 'y' is equal to 2 + Assuming 'y' is equal to '2' message - Assuming 'y' is equal to 2 + Assuming 'y' is equal to '2' kindcontrol Index: test/Analysis/Inputs/expected-plists/edges-new.mm.plist =================================================================== --- test/Analysis/Inputs/expected-plists/edges-new.mm.plist +++ test/Analysis/Inputs/expected-plists/edges-new.mm.plist @@ -666,9 +666,9 @@ depth0 extended_message - Assuming 'p' is null + Assuming 'p' is 'null' message - Assuming 'p' is null + Assuming 'p' is 'null' kindcontrol @@ -855,9 +855,9 @@ depth0 extended_message - Assuming 'q' is null + Assuming 'q' is 'null' message - Assuming 'q' is null + Assuming 'q' is 'null' kindcontrol @@ -1298,9 +1298,9 @@ depth0 extended_message - Assuming 'a' is not equal to 0 + Assuming 'a' is not equal to '0' message - Assuming 'a' is not equal to 0 + Assuming 'a' is not equal to '0' kindcontrol @@ -1395,9 +1395,9 @@ depth0 extended_message - Assuming 'b' is equal to 0 + Assuming 'b' is equal to '0' message - Assuming 'b' is equal to 0 + Assuming 'b' is equal to '0' kindcontrol @@ -1713,9 +1713,9 @@ depth0 extended_message - Assuming 'p' is null + Assuming 'p' is 'null' message - Assuming 'p' is null + Assuming 'p' is 'null' kindevent @@ -2029,9 +2029,9 @@ depth0 extended_message - Assuming 'x' is 0 + Assuming 'x' is '0' message - Assuming 'x' is 0 + Assuming 'x' is '0' kindcontrol @@ -2734,9 +2734,9 @@ depth0 extended_message - 'i' is not equal to 1 + 'i' is not equal to '1' message - 'i' is not equal to 1 + 'i' is not equal to '1' kindcontrol @@ -2957,9 +2957,9 @@ depth0 extended_message - 'i' is equal to 1 + 'i' is equal to '1' message - 'i' is equal to 1 + 'i' is equal to '1' kindcontrol @@ -3938,9 +3938,9 @@ depth0 extended_message - 'i' is equal to 0 + 'i' is equal to '0' message - 'i' is equal to 0 + 'i' is equal to '0' kindcontrol @@ -4195,9 +4195,9 @@ depth0 extended_message - 'i' is not equal to 0 + 'i' is not equal to '0' message - 'i' is not equal to 0 + 'i' is not equal to '0' kindcontrol @@ -4292,9 +4292,9 @@ depth0 extended_message - 'i' is equal to 1 + 'i' is equal to '1' message - 'i' is equal to 1 + 'i' is equal to '1' kindcontrol @@ -7626,9 +7626,9 @@ depth0 extended_message - Assuming 'coin' is not equal to 0 + Assuming 'coin' is not equal to '0' message - Assuming 'coin' is not equal to 0 + Assuming 'coin' is not equal to '0' kindcontrol @@ -7947,9 +7947,9 @@ depth0 extended_message - Assuming 'coin' is 0 + Assuming 'coin' is '0' message - Assuming 'coin' is 0 + Assuming 'coin' is '0' kindcontrol @@ -8112,9 +8112,9 @@ depth0 extended_message - 'coin' is 0 + 'coin' is '0' message - 'coin' is 0 + 'coin' is '0' kindcontrol @@ -8828,9 +8828,9 @@ depth0 extended_message - Assuming 'x' is not equal to 0 + Assuming 'x' is not equal to '0' message - Assuming 'x' is not equal to 0 + Assuming 'x' is not equal to '0' kindcontrol @@ -9280,9 +9280,9 @@ depth0 extended_message - Assuming 'y' is null + Assuming 'y' is 'null' message - Assuming 'y' is null + Assuming 'y' is 'null' kindcontrol @@ -9377,9 +9377,9 @@ depth0 extended_message - 'y' is null + 'y' is 'null' message - 'y' is null + 'y' is 'null' kindcontrol @@ -9631,9 +9631,9 @@ depth0 extended_message - Assuming 'x' is nil + Assuming 'x' is 'nil' message - Assuming 'x' is nil + Assuming 'x' is 'nil' kindcontrol @@ -10033,9 +10033,9 @@ depth0 extended_message - Assuming 'y' is nil + Assuming 'y' is 'nil' message - Assuming 'y' is nil + Assuming 'y' is 'nil' kindcontrol @@ -10954,9 +10954,9 @@ depth0 extended_message - Assuming 'coin' is not equal to 0 + Assuming 'coin' is not equal to '0' message - Assuming 'coin' is not equal to 0 + Assuming 'coin' is not equal to '0' kindcontrol @@ -20902,9 +20902,9 @@ depth0 extended_message - Assuming 'tmp' is null + Assuming 'tmp' is 'null' message - Assuming 'tmp' is null + Assuming 'tmp' is 'null' kindevent @@ -22284,9 +22284,9 @@ depth0 extended_message - Field 'b' is equal to 2 + Field 'b' is equal to '2' message - Field 'b' is equal to 2 + Field 'b' is equal to '2' kindcontrol Index: test/Analysis/Inputs/expected-plists/inline-plist.c.plist =================================================================== --- test/Analysis/Inputs/expected-plists/inline-plist.c.plist +++ test/Analysis/Inputs/expected-plists/inline-plist.c.plist @@ -102,9 +102,9 @@ depth0 extended_message - Assuming 'x' is equal to 0 + Assuming 'x' is equal to '0' message - Assuming 'x' is equal to 0 + Assuming 'x' is equal to '0' kindcontrol @@ -459,9 +459,9 @@ depth0 extended_message - Assuming 'p' is null + Assuming 'p' is 'null' message - Assuming 'p' is null + Assuming 'p' is 'null' kindcontrol @@ -556,9 +556,9 @@ depth0 extended_message - 'p' is equal to null + 'p' is equal to 'null' message - 'p' is equal to null + 'p' is equal to 'null' kindcontrol Index: test/Analysis/Inputs/expected-plists/malloc-plist.c.plist =================================================================== --- test/Analysis/Inputs/expected-plists/malloc-plist.c.plist +++ test/Analysis/Inputs/expected-plists/malloc-plist.c.plist @@ -58,9 +58,9 @@ depth0 extended_message - Assuming 'in' is > 5 + Assuming 'in' is > '5' message - Assuming 'in' is > 5 + Assuming 'in' is > '5' kindcontrol @@ -600,9 +600,9 @@ depth0 extended_message - Assuming 'tmp' is null + Assuming 'tmp' is 'null' message - Assuming 'tmp' is null + Assuming 'tmp' is 'null' kindcontrol @@ -980,9 +980,9 @@ depth1 extended_message - Assuming 'x' is non-null + Assuming 'x' is 'non-null' message - Assuming 'x' is non-null + Assuming 'x' is 'non-null' kindcontrol @@ -2096,9 +2096,9 @@ depth1 extended_message - Assuming 'tmp' is null + Assuming 'tmp' is 'null' message - Assuming 'tmp' is null + Assuming 'tmp' is 'null' kindcontrol @@ -3738,9 +3738,9 @@ depth1 extended_message - Assuming 'y' is not equal to 0 + Assuming 'y' is not equal to '0' message - Assuming 'y' is not equal to 0 + Assuming 'y' is not equal to '0' kindcontrol @@ -4021,9 +4021,9 @@ depth1 extended_message - Assuming 'y' is 0 + Assuming 'y' is '0' message - Assuming 'y' is 0 + Assuming 'y' is '0' kindcontrol Index: test/Analysis/Inputs/expected-plists/method-call-path-notes.cpp.plist =================================================================== --- test/Analysis/Inputs/expected-plists/method-call-path-notes.cpp.plist +++ test/Analysis/Inputs/expected-plists/method-call-path-notes.cpp.plist @@ -466,9 +466,9 @@ depth0 extended_message - Assuming 'p' is null + Assuming 'p' is 'null' message - Assuming 'p' is null + Assuming 'p' is 'null' kindcontrol @@ -743,9 +743,9 @@ depth0 extended_message - Assuming 'p' is null + Assuming 'p' is 'null' message - Assuming 'p' is null + Assuming 'p' is 'null' kindcontrol Index: test/Analysis/Inputs/expected-plists/null-deref-path-notes.m.plist =================================================================== --- test/Analysis/Inputs/expected-plists/null-deref-path-notes.m.plist +++ test/Analysis/Inputs/expected-plists/null-deref-path-notes.m.plist @@ -68,9 +68,9 @@ depth0 extended_message - Assuming 'obj' is nil + Assuming 'obj' is 'nil' message - Assuming 'obj' is nil + Assuming 'obj' is 'nil' kindcontrol @@ -384,9 +384,9 @@ depth0 extended_message - Assuming 'self' is nil + Assuming 'self' is 'nil' message - Assuming 'self' is nil + Assuming 'self' is 'nil' kindcontrol @@ -593,9 +593,9 @@ depth0 extended_message - Assuming 'coin' is 0 + Assuming 'coin' is '0' message - Assuming 'coin' is 0 + Assuming 'coin' is '0' kindcontrol Index: test/Analysis/Inputs/expected-plists/objc-radar17039661.m.plist =================================================================== --- test/Analysis/Inputs/expected-plists/objc-radar17039661.m.plist +++ test/Analysis/Inputs/expected-plists/objc-radar17039661.m.plist @@ -400,9 +400,9 @@ depth3 extended_message - Assuming 'cond' is not equal to 0 + Assuming 'cond' is not equal to '0' message - Assuming 'cond' is not equal to 0 + Assuming 'cond' is not equal to '0' kindcontrol @@ -1080,9 +1080,9 @@ depth3 extended_message - Assuming 'cond' is not equal to 0 + Assuming 'cond' is not equal to '0' message - Assuming 'cond' is not equal to 0 + Assuming 'cond' is not equal to '0' kindcontrol Index: test/Analysis/Inputs/expected-plists/plist-macros-with-expansion.cpp.plist =================================================================== --- test/Analysis/Inputs/expected-plists/plist-macros-with-expansion.cpp.plist +++ test/Analysis/Inputs/expected-plists/plist-macros-with-expansion.cpp.plist @@ -5230,9 +5230,9 @@ depth1 extended_message - 'A' is >= 0 + 'A' is >= '0' message - 'A' is >= 0 + 'A' is >= '0' kindevent @@ -5259,9 +5259,9 @@ depth1 extended_message - 'B' is >= 0 + 'B' is >= '0' message - 'B' is >= 0 + 'B' is >= '0' kindevent Index: test/Analysis/Inputs/expected-plists/plist-macros.cpp.plist =================================================================== --- test/Analysis/Inputs/expected-plists/plist-macros.cpp.plist +++ test/Analysis/Inputs/expected-plists/plist-macros.cpp.plist @@ -367,9 +367,9 @@ depth0 extended_message - Assuming 'p' is equal to null + Assuming 'p' is equal to 'null' message - Assuming 'p' is equal to null + Assuming 'p' is equal to 'null' kindcontrol @@ -722,9 +722,9 @@ depth0 extended_message - Assuming 'p' is null + Assuming 'p' is 'null' message - Assuming 'p' is null + Assuming 'p' is 'null' kindcontrol @@ -947,9 +947,9 @@ depth0 extended_message - Assuming 'p' is equal to null + Assuming 'p' is equal to 'null' message - Assuming 'p' is equal to null + Assuming 'p' is equal to 'null' kindcontrol @@ -1137,9 +1137,9 @@ depth0 extended_message - Assuming 'p' is null + Assuming 'p' is 'null' message - Assuming 'p' is null + Assuming 'p' is 'null' kindcontrol @@ -1326,9 +1326,9 @@ depth0 extended_message - Assuming 'p' is null + Assuming 'p' is 'null' message - Assuming 'p' is null + Assuming 'p' is 'null' kindcontrol @@ -1389,9 +1389,9 @@ depth0 extended_message - 'p' is null + 'p' is 'null' message - 'p' is null + 'p' is 'null' kindevent @@ -1418,9 +1418,9 @@ depth0 extended_message - Assuming 'y' is 0 + Assuming 'y' is '0' message - Assuming 'y' is 0 + Assuming 'y' is '0' kindcontrol @@ -1715,9 +1715,9 @@ depth1 extended_message - Assuming 'a' is null + Assuming 'a' is 'null' message - Assuming 'a' is null + Assuming 'a' is 'null' kindcontrol Index: test/Analysis/Inputs/expected-plists/plist-output-alternate.m.plist =================================================================== --- test/Analysis/Inputs/expected-plists/plist-output-alternate.m.plist +++ test/Analysis/Inputs/expected-plists/plist-output-alternate.m.plist @@ -666,9 +666,9 @@ depth0 extended_message - Assuming 'p' is null + Assuming 'p' is 'null' message - Assuming 'p' is null + Assuming 'p' is 'null' kindcontrol @@ -855,9 +855,9 @@ depth0 extended_message - Assuming 'q' is null + Assuming 'q' is 'null' message - Assuming 'q' is null + Assuming 'q' is 'null' kindcontrol @@ -1395,9 +1395,9 @@ depth0 extended_message - Assuming 'x' is 0 + Assuming 'x' is '0' message - Assuming 'x' is 0 + Assuming 'x' is '0' kindcontrol Index: test/Analysis/Inputs/expected-plists/plist-output.m.plist =================================================================== --- test/Analysis/Inputs/expected-plists/plist-output.m.plist +++ test/Analysis/Inputs/expected-plists/plist-output.m.plist @@ -666,9 +666,9 @@ depth0 extended_message - Assuming 'p' is null + Assuming 'p' is 'null' message - Assuming 'p' is null + Assuming 'p' is 'null' kindcontrol @@ -855,9 +855,9 @@ depth0 extended_message - Assuming 'q' is null + Assuming 'q' is 'null' message - Assuming 'q' is null + Assuming 'q' is 'null' kindcontrol @@ -1298,9 +1298,9 @@ depth0 extended_message - Assuming 'a' is not equal to 0 + Assuming 'a' is not equal to '0' message - Assuming 'a' is not equal to 0 + Assuming 'a' is not equal to '0' kindcontrol @@ -1395,9 +1395,9 @@ depth0 extended_message - Assuming 'b' is equal to 0 + Assuming 'b' is equal to '0' message - Assuming 'b' is equal to 0 + Assuming 'b' is equal to '0' kindcontrol @@ -1713,9 +1713,9 @@ depth0 extended_message - Assuming 'p' is null + Assuming 'p' is 'null' message - Assuming 'p' is null + Assuming 'p' is 'null' kindevent @@ -2520,9 +2520,9 @@ depth0 extended_message - 'i' is not equal to 1 + 'i' is not equal to '1' message - 'i' is not equal to 1 + 'i' is not equal to '1' kindcontrol @@ -2743,9 +2743,9 @@ depth0 extended_message - 'i' is equal to 1 + 'i' is equal to '1' message - 'i' is equal to 1 + 'i' is equal to '1' kindcontrol @@ -3563,9 +3563,9 @@ depth0 extended_message - 'i' is not equal to 1 + 'i' is not equal to '1' message - 'i' is not equal to 1 + 'i' is not equal to '1' kindcontrol @@ -3786,9 +3786,9 @@ depth0 extended_message - 'i' is equal to 1 + 'i' is equal to '1' message - 'i' is equal to 1 + 'i' is equal to '1' kindcontrol @@ -6238,9 +6238,9 @@ depth0 extended_message - Assuming 'x' is nil + Assuming 'x' is 'nil' message - Assuming 'x' is nil + Assuming 'x' is 'nil' kindcontrol Index: test/Analysis/Inputs/expected-plists/retain-release-path-notes.m.plist =================================================================== --- test/Analysis/Inputs/expected-plists/retain-release-path-notes.m.plist +++ test/Analysis/Inputs/expected-plists/retain-release-path-notes.m.plist @@ -3707,9 +3707,9 @@ depth1 extended_message - Assuming 'Cond' is not equal to 0 + Assuming 'Cond' is not equal to '0' message - Assuming 'Cond' is not equal to 0 + Assuming 'Cond' is not equal to '0' kindcontrol Index: test/Analysis/Inputs/expected-plists/retain-release.m.objc.plist =================================================================== --- test/Analysis/Inputs/expected-plists/retain-release.m.objc.plist +++ test/Analysis/Inputs/expected-plists/retain-release.m.objc.plist @@ -1003,9 +1003,9 @@ depth0 extended_message - Assuming 'x' is 0 + Assuming 'x' is '0' message - Assuming 'x' is 0 + Assuming 'x' is '0' kindcontrol @@ -2040,9 +2040,9 @@ depth0 extended_message - Assuming 'date' is null + Assuming 'date' is 'null' message - Assuming 'date' is null + Assuming 'date' is 'null' kindcontrol @@ -2293,9 +2293,9 @@ depth0 extended_message - Assuming 'disk' is non-null + Assuming 'disk' is 'non-null' message - Assuming 'disk' is non-null + Assuming 'disk' is 'non-null' kindcontrol @@ -2458,9 +2458,9 @@ depth0 extended_message - Assuming 'disk' is null + Assuming 'disk' is 'null' message - Assuming 'disk' is null + Assuming 'disk' is 'null' kindcontrol @@ -2684,9 +2684,9 @@ depth0 extended_message - Assuming 'disk' is null + Assuming 'disk' is 'null' message - Assuming 'disk' is null + Assuming 'disk' is 'null' kindcontrol @@ -2815,9 +2815,9 @@ depth0 extended_message - Assuming 'disk' is null + Assuming 'disk' is 'null' message - Assuming 'disk' is null + Assuming 'disk' is 'null' kindcontrol @@ -2975,9 +2975,9 @@ depth0 extended_message - Assuming 'dict' is non-null + Assuming 'dict' is 'non-null' message - Assuming 'dict' is non-null + Assuming 'dict' is 'non-null' kindcontrol @@ -3168,9 +3168,9 @@ depth0 extended_message - Assuming 'disk' is null + Assuming 'disk' is 'null' message - Assuming 'disk' is null + Assuming 'disk' is 'null' kindcontrol @@ -3299,9 +3299,9 @@ depth0 extended_message - Assuming 'disk' is null + Assuming 'disk' is 'null' message - Assuming 'disk' is null + Assuming 'disk' is 'null' kindcontrol @@ -3430,9 +3430,9 @@ depth0 extended_message - Assuming 'dict' is null + Assuming 'dict' is 'null' message - Assuming 'dict' is null + Assuming 'dict' is 'null' kindcontrol @@ -3590,9 +3590,9 @@ depth0 extended_message - Assuming 'disk' is non-null + Assuming 'disk' is 'non-null' message - Assuming 'disk' is non-null + Assuming 'disk' is 'non-null' kindcontrol @@ -3785,9 +3785,9 @@ depth0 extended_message - Assuming 'disk' is null + Assuming 'disk' is 'null' message - Assuming 'disk' is null + Assuming 'disk' is 'null' kindcontrol @@ -3945,9 +3945,9 @@ depth0 extended_message - Assuming 'disk' is non-null + Assuming 'disk' is 'non-null' message - Assuming 'disk' is non-null + Assuming 'disk' is 'non-null' kindcontrol @@ -4110,9 +4110,9 @@ depth0 extended_message - Assuming 'dict' is null + Assuming 'dict' is 'null' message - Assuming 'dict' is null + Assuming 'dict' is 'null' kindcontrol @@ -4241,9 +4241,9 @@ depth0 extended_message - Assuming 'disk' is null + Assuming 'disk' is 'null' message - Assuming 'disk' is null + Assuming 'disk' is 'null' kindcontrol @@ -4471,9 +4471,9 @@ depth0 extended_message - Assuming 'disk' is null + Assuming 'disk' is 'null' message - Assuming 'disk' is null + Assuming 'disk' is 'null' kindcontrol @@ -4602,9 +4602,9 @@ depth0 extended_message - Assuming 'disk' is null + Assuming 'disk' is 'null' message - Assuming 'disk' is null + Assuming 'disk' is 'null' kindcontrol @@ -4733,9 +4733,9 @@ depth0 extended_message - Assuming 'dict' is null + Assuming 'dict' is 'null' message - Assuming 'dict' is null + Assuming 'dict' is 'null' kindcontrol @@ -4864,9 +4864,9 @@ depth0 extended_message - Assuming 'disk' is null + Assuming 'disk' is 'null' message - Assuming 'disk' is null + Assuming 'disk' is 'null' kindcontrol @@ -5092,9 +5092,9 @@ depth0 extended_message - Assuming 'dissenter' is non-null + Assuming 'dissenter' is 'non-null' message - Assuming 'dissenter' is non-null + Assuming 'dissenter' is 'non-null' kindcontrol @@ -5290,9 +5290,9 @@ depth0 extended_message - Assuming 'disk' is null + Assuming 'disk' is 'null' message - Assuming 'disk' is null + Assuming 'disk' is 'null' kindcontrol @@ -5421,9 +5421,9 @@ depth0 extended_message - Assuming 'disk' is null + Assuming 'disk' is 'null' message - Assuming 'disk' is null + Assuming 'disk' is 'null' kindcontrol @@ -5552,9 +5552,9 @@ depth0 extended_message - Assuming 'dict' is null + Assuming 'dict' is 'null' message - Assuming 'dict' is null + Assuming 'dict' is 'null' kindcontrol @@ -5683,9 +5683,9 @@ depth0 extended_message - Assuming 'disk' is null + Assuming 'disk' is 'null' message - Assuming 'disk' is null + Assuming 'disk' is 'null' kindcontrol @@ -5814,9 +5814,9 @@ depth0 extended_message - Assuming 'dissenter' is null + Assuming 'dissenter' is 'null' message - Assuming 'dissenter' is null + Assuming 'dissenter' is 'null' kindcontrol @@ -5974,9 +5974,9 @@ depth0 extended_message - Assuming 'session' is non-null + Assuming 'session' is 'non-null' message - Assuming 'session' is non-null + Assuming 'session' is 'non-null' kindcontrol @@ -7970,9 +7970,9 @@ depth0 extended_message - Assuming 'p' is null + Assuming 'p' is 'null' message - Assuming 'p' is null + Assuming 'p' is 'null' kindcontrol @@ -8195,9 +8195,9 @@ depth0 extended_message - Assuming 'p' is null + Assuming 'p' is 'null' message - Assuming 'p' is null + Assuming 'p' is 'null' kindcontrol @@ -8420,9 +8420,9 @@ depth0 extended_message - Assuming 'p' is null + Assuming 'p' is 'null' message - Assuming 'p' is null + Assuming 'p' is 'null' kindcontrol @@ -8645,9 +8645,9 @@ depth0 extended_message - Assuming 'p' is null + Assuming 'p' is 'null' message - Assuming 'p' is null + Assuming 'p' is 'null' kindcontrol @@ -9160,9 +9160,9 @@ depth0 extended_message - Assuming 'name' is nil + Assuming 'name' is 'nil' message - Assuming 'name' is nil + Assuming 'name' is 'nil' kindcontrol @@ -9352,9 +9352,9 @@ depth0 extended_message - Assuming 'name' is non-nil + Assuming 'name' is 'non-nil' message - Assuming 'name' is non-nil + Assuming 'name' is 'non-nil' kindcontrol @@ -9512,9 +9512,9 @@ depth0 extended_message - Assuming 'kind' is nil + Assuming 'kind' is 'nil' message - Assuming 'kind' is nil + Assuming 'kind' is 'nil' kindcontrol @@ -9609,9 +9609,9 @@ depth0 extended_message - 'name' is non-nil + 'name' is 'non-nil' message - 'name' is non-nil + 'name' is 'non-nil' kindcontrol @@ -9937,9 +9937,9 @@ depth0 extended_message - Assuming 'name' is non-nil + Assuming 'name' is 'non-nil' message - Assuming 'name' is non-nil + Assuming 'name' is 'non-nil' kindcontrol @@ -10068,9 +10068,9 @@ depth0 extended_message - Assuming 'kind' is non-nil + Assuming 'kind' is 'non-nil' message - Assuming 'kind' is non-nil + Assuming 'kind' is 'non-nil' kindcontrol @@ -10199,9 +10199,9 @@ depth0 extended_message - 'name' is non-nil + 'name' is 'non-nil' message - 'name' is non-nil + 'name' is 'non-nil' kindcontrol @@ -19034,9 +19034,9 @@ depth0 extended_message - Assuming 'x' is 0 + Assuming 'x' is '0' message - Assuming 'x' is 0 + Assuming 'x' is '0' kindcontrol @@ -19619,9 +19619,9 @@ depth0 extended_message - Assuming 'error_to_dump' is not equal to null + Assuming 'error_to_dump' is not equal to 'null' message - Assuming 'error_to_dump' is not equal to null + Assuming 'error_to_dump' is not equal to 'null' kindevent @@ -19842,9 +19842,9 @@ depth0 extended_message - Assuming 'info' is not equal to null + Assuming 'info' is not equal to 'null' message - Assuming 'info' is not equal to null + Assuming 'info' is not equal to 'null' kindcontrol @@ -23283,9 +23283,9 @@ depth0 extended_message - Assuming 'y' is <= 2 + Assuming 'y' is <= '2' message - Assuming 'y' is <= 2 + Assuming 'y' is <= '2' kindcontrol @@ -24371,9 +24371,9 @@ depth1 extended_message - Assuming 'Cond' is not equal to 0 + Assuming 'Cond' is not equal to '0' message - Assuming 'Cond' is not equal to 0 + Assuming 'Cond' is not equal to '0' kindcontrol Index: test/Analysis/Inputs/expected-plists/retain-release.m.objcpp.plist =================================================================== --- test/Analysis/Inputs/expected-plists/retain-release.m.objcpp.plist +++ test/Analysis/Inputs/expected-plists/retain-release.m.objcpp.plist @@ -1003,9 +1003,9 @@ depth0 extended_message - Assuming 'x' is 0 + Assuming 'x' is '0' message - Assuming 'x' is 0 + Assuming 'x' is '0' kindcontrol @@ -2040,9 +2040,9 @@ depth0 extended_message - Assuming 'date' is null + Assuming 'date' is 'null' message - Assuming 'date' is null + Assuming 'date' is 'null' kindcontrol @@ -2293,9 +2293,9 @@ depth0 extended_message - Assuming 'disk' is non-null + Assuming 'disk' is 'non-null' message - Assuming 'disk' is non-null + Assuming 'disk' is 'non-null' kindcontrol @@ -2458,9 +2458,9 @@ depth0 extended_message - Assuming 'disk' is null + Assuming 'disk' is 'null' message - Assuming 'disk' is null + Assuming 'disk' is 'null' kindcontrol @@ -2684,9 +2684,9 @@ depth0 extended_message - Assuming 'disk' is null + Assuming 'disk' is 'null' message - Assuming 'disk' is null + Assuming 'disk' is 'null' kindcontrol @@ -2815,9 +2815,9 @@ depth0 extended_message - Assuming 'disk' is null + Assuming 'disk' is 'null' message - Assuming 'disk' is null + Assuming 'disk' is 'null' kindcontrol @@ -2975,9 +2975,9 @@ depth0 extended_message - Assuming 'dict' is non-null + Assuming 'dict' is 'non-null' message - Assuming 'dict' is non-null + Assuming 'dict' is 'non-null' kindcontrol @@ -3168,9 +3168,9 @@ depth0 extended_message - Assuming 'disk' is null + Assuming 'disk' is 'null' message - Assuming 'disk' is null + Assuming 'disk' is 'null' kindcontrol @@ -3299,9 +3299,9 @@ depth0 extended_message - Assuming 'disk' is null + Assuming 'disk' is 'null' message - Assuming 'disk' is null + Assuming 'disk' is 'null' kindcontrol @@ -3430,9 +3430,9 @@ depth0 extended_message - Assuming 'dict' is null + Assuming 'dict' is 'null' message - Assuming 'dict' is null + Assuming 'dict' is 'null' kindcontrol @@ -3590,9 +3590,9 @@ depth0 extended_message - Assuming 'disk' is non-null + Assuming 'disk' is 'non-null' message - Assuming 'disk' is non-null + Assuming 'disk' is 'non-null' kindcontrol @@ -3785,9 +3785,9 @@ depth0 extended_message - Assuming 'disk' is null + Assuming 'disk' is 'null' message - Assuming 'disk' is null + Assuming 'disk' is 'null' kindcontrol @@ -3945,9 +3945,9 @@ depth0 extended_message - Assuming 'disk' is non-null + Assuming 'disk' is 'non-null' message - Assuming 'disk' is non-null + Assuming 'disk' is 'non-null' kindcontrol @@ -4110,9 +4110,9 @@ depth0 extended_message - Assuming 'dict' is null + Assuming 'dict' is 'null' message - Assuming 'dict' is null + Assuming 'dict' is 'null' kindcontrol @@ -4241,9 +4241,9 @@ depth0 extended_message - Assuming 'disk' is null + Assuming 'disk' is 'null' message - Assuming 'disk' is null + Assuming 'disk' is 'null' kindcontrol @@ -4471,9 +4471,9 @@ depth0 extended_message - Assuming 'disk' is null + Assuming 'disk' is 'null' message - Assuming 'disk' is null + Assuming 'disk' is 'null' kindcontrol @@ -4602,9 +4602,9 @@ depth0 extended_message - Assuming 'disk' is null + Assuming 'disk' is 'null' message - Assuming 'disk' is null + Assuming 'disk' is 'null' kindcontrol @@ -4733,9 +4733,9 @@ depth0 extended_message - Assuming 'dict' is null + Assuming 'dict' is 'null' message - Assuming 'dict' is null + Assuming 'dict' is 'null' kindcontrol @@ -4864,9 +4864,9 @@ depth0 extended_message - Assuming 'disk' is null + Assuming 'disk' is 'null' message - Assuming 'disk' is null + Assuming 'disk' is 'null' kindcontrol @@ -5092,9 +5092,9 @@ depth0 extended_message - Assuming 'dissenter' is non-null + Assuming 'dissenter' is 'non-null' message - Assuming 'dissenter' is non-null + Assuming 'dissenter' is 'non-null' kindcontrol @@ -5290,9 +5290,9 @@ depth0 extended_message - Assuming 'disk' is null + Assuming 'disk' is 'null' message - Assuming 'disk' is null + Assuming 'disk' is 'null' kindcontrol @@ -5421,9 +5421,9 @@ depth0 extended_message - Assuming 'disk' is null + Assuming 'disk' is 'null' message - Assuming 'disk' is null + Assuming 'disk' is 'null' kindcontrol @@ -5552,9 +5552,9 @@ depth0 extended_message - Assuming 'dict' is null + Assuming 'dict' is 'null' message - Assuming 'dict' is null + Assuming 'dict' is 'null' kindcontrol @@ -5683,9 +5683,9 @@ depth0 extended_message - Assuming 'disk' is null + Assuming 'disk' is 'null' message - Assuming 'disk' is null + Assuming 'disk' is 'null' kindcontrol @@ -5814,9 +5814,9 @@ depth0 extended_message - Assuming 'dissenter' is null + Assuming 'dissenter' is 'null' message - Assuming 'dissenter' is null + Assuming 'dissenter' is 'null' kindcontrol @@ -5974,9 +5974,9 @@ depth0 extended_message - Assuming 'session' is non-null + Assuming 'session' is 'non-null' message - Assuming 'session' is non-null + Assuming 'session' is 'non-null' kindcontrol @@ -7970,9 +7970,9 @@ depth0 extended_message - Assuming 'p' is null + Assuming 'p' is 'null' message - Assuming 'p' is null + Assuming 'p' is 'null' kindcontrol @@ -8195,9 +8195,9 @@ depth0 extended_message - Assuming 'p' is null + Assuming 'p' is 'null' message - Assuming 'p' is null + Assuming 'p' is 'null' kindcontrol @@ -8420,9 +8420,9 @@ depth0 extended_message - Assuming 'p' is null + Assuming 'p' is 'null' message - Assuming 'p' is null + Assuming 'p' is 'null' kindcontrol @@ -8645,9 +8645,9 @@ depth0 extended_message - Assuming 'p' is null + Assuming 'p' is 'null' message - Assuming 'p' is null + Assuming 'p' is 'null' kindcontrol @@ -9160,9 +9160,9 @@ depth0 extended_message - Assuming 'name' is nil + Assuming 'name' is 'nil' message - Assuming 'name' is nil + Assuming 'name' is 'nil' kindcontrol @@ -9352,9 +9352,9 @@ depth0 extended_message - Assuming 'name' is non-nil + Assuming 'name' is 'non-nil' message - Assuming 'name' is non-nil + Assuming 'name' is 'non-nil' kindcontrol @@ -9512,9 +9512,9 @@ depth0 extended_message - Assuming 'kind' is nil + Assuming 'kind' is 'nil' message - Assuming 'kind' is nil + Assuming 'kind' is 'nil' kindcontrol @@ -9609,9 +9609,9 @@ depth0 extended_message - 'name' is non-nil + 'name' is 'non-nil' message - 'name' is non-nil + 'name' is 'non-nil' kindcontrol @@ -9937,9 +9937,9 @@ depth0 extended_message - Assuming 'name' is non-nil + Assuming 'name' is 'non-nil' message - Assuming 'name' is non-nil + Assuming 'name' is 'non-nil' kindcontrol @@ -10068,9 +10068,9 @@ depth0 extended_message - Assuming 'kind' is non-nil + Assuming 'kind' is 'non-nil' message - Assuming 'kind' is non-nil + Assuming 'kind' is 'non-nil' kindcontrol @@ -10199,9 +10199,9 @@ depth0 extended_message - 'name' is non-nil + 'name' is 'non-nil' message - 'name' is non-nil + 'name' is 'non-nil' kindcontrol @@ -19103,9 +19103,9 @@ depth0 extended_message - Assuming 'x' is 0 + Assuming 'x' is '0' message - Assuming 'x' is 0 + Assuming 'x' is '0' kindcontrol @@ -19688,9 +19688,9 @@ depth0 extended_message - Assuming 'error_to_dump' is not equal to null + Assuming 'error_to_dump' is not equal to 'null' message - Assuming 'error_to_dump' is not equal to null + Assuming 'error_to_dump' is not equal to 'null' kindevent @@ -19911,9 +19911,9 @@ depth0 extended_message - Assuming 'info' is not equal to null + Assuming 'info' is not equal to 'null' message - Assuming 'info' is not equal to null + Assuming 'info' is not equal to 'null' kindcontrol @@ -23352,9 +23352,9 @@ depth0 extended_message - Assuming 'y' is <= 2 + Assuming 'y' is <= '2' message - Assuming 'y' is <= 2 + Assuming 'y' is <= '2' kindcontrol @@ -24440,9 +24440,9 @@ depth1 extended_message - Assuming 'Cond' is not equal to 0 + Assuming 'Cond' is not equal to '0' message - Assuming 'Cond' is not equal to 0 + Assuming 'Cond' is not equal to '0' kindcontrol Index: test/Analysis/Inputs/expected-plists/unix-fns.c.plist =================================================================== --- test/Analysis/Inputs/expected-plists/unix-fns.c.plist +++ test/Analysis/Inputs/expected-plists/unix-fns.c.plist @@ -102,9 +102,9 @@ depth0 extended_message - Assuming 'fd' is not equal to 0 + Assuming 'fd' is not equal to '0' message - Assuming 'fd' is not equal to 0 + Assuming 'fd' is not equal to '0' kindcontrol @@ -327,9 +327,9 @@ depth0 extended_message - Assuming 'fd' is not equal to 0 + Assuming 'fd' is not equal to '0' message - Assuming 'fd' is not equal to 0 + Assuming 'fd' is not equal to '0' kindcontrol @@ -1885,9 +1885,9 @@ depth2 extended_message - Assuming 'q' is non-null + Assuming 'q' is 'non-null' message - Assuming 'q' is non-null + Assuming 'q' is 'non-null' kindcontrol Index: test/Analysis/NewDelete-path-notes.cpp =================================================================== --- test/Analysis/NewDelete-path-notes.cpp +++ test/Analysis/NewDelete-path-notes.cpp @@ -6,7 +6,7 @@ void test() { int *p = new int; // expected-note@-1 {{Memory is allocated}} - if (p) // expected-note {{'p' is non-null}} + if (p) // expected-note {{'p' is 'non-null'}} // expected-note@-1 {{Taking true branch}} delete p; // expected-note@-1 {{Memory is released}} Index: test/Analysis/conditional-path-notes.c =================================================================== --- test/Analysis/conditional-path-notes.c +++ test/Analysis/conditional-path-notes.c @@ -4,7 +4,7 @@ void testCondOp(int *p) { int *x = p ? p : p; - // expected-note@-1 {{Assuming 'p' is null}} + // expected-note@-1 {{Assuming 'p' is 'null'}} // expected-note@-2 {{'?' condition is false}} // expected-note@-3 {{'x' initialized to a null pointer value}} *x = 1; // expected-warning{{Dereference of null pointer (loaded from variable 'x')}} @@ -13,7 +13,7 @@ void testCondProblem(int *p) { if (p) return; - // expected-note@-1 {{Assuming 'p' is null}} + // expected-note@-1 {{Assuming 'p' is 'null'}} // expected-note@-2 {{Taking false branch}} int x = *p ? 0 : 1; // expected-warning{{Dereference of null pointer (loaded from variable 'p')}} @@ -23,7 +23,7 @@ void testLHSProblem(int *p) { int x = !p ? *p : 1; // expected-warning{{Dereference of null pointer (loaded from variable 'p')}} - // expected-note@-1 {{Assuming 'p' is null}} + // expected-note@-1 {{Assuming 'p' is 'null'}} // expected-note@-2 {{'?' condition is true}} // expected-note@-3 {{Dereference of null pointer (loaded from variable 'p')}} (void)x; @@ -31,7 +31,7 @@ void testRHSProblem(int *p) { int x = p ? 1 : *p; // expected-warning{{Dereference of null pointer (loaded from variable 'p')}} - // expected-note@-1 {{Assuming 'p' is null}} + // expected-note@-1 {{Assuming 'p' is 'null'}} // expected-note@-2 {{'?' condition is false}} // expected-note@-3 {{Dereference of null pointer (loaded from variable 'p')}} (void)x; @@ -47,7 +47,7 @@ void testBinaryLHSProblem(int *p) { if (p) return; - // expected-note@-1 {{Assuming 'p' is null}} + // expected-note@-1 {{Assuming 'p' is 'null'}} // expected-note@-2 {{Taking false branch}} int x = *p ?: 1; // expected-warning{{Dereference of null pointer (loaded from variable 'p')}} @@ -57,7 +57,7 @@ void testDiagnosableBranch(int a) { if (a) { - // expected-note@-1 {{Assuming 'a' is not equal to 0}} + // expected-note@-1 {{Assuming 'a' is not equal to '0'}} // expected-note@-2 {{Taking true branch}} *(volatile int *)0 = 1; // expected-warning{{Dereference of null pointer}} // expected-note@-1 {{Dereference of null pointer}} @@ -66,9 +66,9 @@ void testDiagnosableBranchLogical(int a, int b) { if (a && b) { - // expected-note@-1 {{Assuming 'a' is not equal to 0}} + // expected-note@-1 {{Assuming 'a' is not equal to '0'}} // expected-note@-2 {{Left side of '&&' is true}} - // expected-note@-3 {{Assuming 'b' is not equal to 0}} + // expected-note@-3 {{Assuming 'b' is not equal to '0'}} // expected-note@-4 {{Taking true branch}} *(volatile int *)0 = 1; // expected-warning{{Dereference of null pointer}} // expected-note@-1 {{Dereference of null pointer}} Index: test/Analysis/diagnostics/Inputs/expected-plists/deref-track-symbolic-region.c.plist =================================================================== --- test/Analysis/diagnostics/Inputs/expected-plists/deref-track-symbolic-region.c.plist +++ test/Analysis/diagnostics/Inputs/expected-plists/deref-track-symbolic-region.c.plist @@ -165,9 +165,9 @@ depth0 extended_message - Assuming field 'x' is null + Assuming field 'x' is 'null' message - Assuming field 'x' is null + Assuming field 'x' is 'null' kindcontrol @@ -454,9 +454,9 @@ depth0 extended_message - Assuming field 'x' is null + Assuming field 'x' is 'null' message - Assuming field 'x' is null + Assuming field 'x' is 'null' kindcontrol Index: test/Analysis/diagnostics/Inputs/expected-plists/undef-value-param.c.plist =================================================================== --- test/Analysis/diagnostics/Inputs/expected-plists/undef-value-param.c.plist +++ test/Analysis/diagnostics/Inputs/expected-plists/undef-value-param.c.plist @@ -208,9 +208,9 @@ depth1 extended_message - Assuming 'c' is not equal to 0 + Assuming 'c' is not equal to '0' message - Assuming 'c' is not equal to 0 + Assuming 'c' is not equal to '0' kindcontrol @@ -662,9 +662,9 @@ depth1 extended_message - Assuming 'x' is <= 0 + Assuming 'x' is <= '0' message - Assuming 'x' is <= 0 + Assuming 'x' is <= '0' kindcontrol @@ -1058,9 +1058,9 @@ depth1 extended_message - Assuming 'x' is <= 0 + Assuming 'x' is <= '0' message - Assuming 'x' is <= 0 + Assuming 'x' is <= '0' kindcontrol Index: test/Analysis/diagnostics/Inputs/expected-plists/undef-value-param.m.plist =================================================================== --- test/Analysis/diagnostics/Inputs/expected-plists/undef-value-param.m.plist +++ test/Analysis/diagnostics/Inputs/expected-plists/undef-value-param.m.plist @@ -213,9 +213,9 @@ depth1 extended_message - Assuming 'err' is not equal to 0 + Assuming 'err' is not equal to '0' message - Assuming 'err' is not equal to 0 + Assuming 'err' is not equal to '0' kindcontrol @@ -739,9 +739,9 @@ depth1 extended_message - Assuming 'err' is not equal to 0 + Assuming 'err' is not equal to '0' message - Assuming 'err' is not equal to 0 + Assuming 'err' is not equal to '0' kindcontrol Index: test/Analysis/diagnostics/Inputs/expected-sarif/sarif-multi-diagnostic-test.c.sarif =================================================================== --- test/Analysis/diagnostics/Inputs/expected-sarif/sarif-multi-diagnostic-test.c.sarif +++ test/Analysis/diagnostics/Inputs/expected-sarif/sarif-multi-diagnostic-test.c.sarif @@ -224,7 +224,7 @@ "importance": "important", "location": { "message": { - "text": "Assuming 'i' is equal to 0" + "text": "Assuming 'i' is equal to '0'" }, "physicalLocation": { "fileLocation": { Index: test/Analysis/diagnostics/deref-track-symbolic-region.c =================================================================== --- test/Analysis/diagnostics/deref-track-symbolic-region.c +++ test/Analysis/diagnostics/deref-track-symbolic-region.c @@ -15,7 +15,7 @@ struct S *ps = &syz; if (ps->x) - //expected-note@-1{{Assuming field 'x' is null}} + //expected-note@-1{{Assuming field 'x' is 'null'}} //expected-note@-2{{Taking false branch}} m++; @@ -30,7 +30,7 @@ struct S *ps = &syz; if (ps->x) - //expected-note@-1{{Assuming field 'x' is null}} + //expected-note@-1{{Assuming field 'x' is 'null'}} //expected-note@-2{{Taking false branch}} m++; Index: test/Analysis/diagnostics/deref-track-symbolic-region.cpp =================================================================== --- test/Analysis/diagnostics/deref-track-symbolic-region.cpp +++ test/Analysis/diagnostics/deref-track-symbolic-region.cpp @@ -10,7 +10,7 @@ S &r = *p; //expected-note {{'r' initialized here}} if (p) return; //expected-note@-1{{Taking false branch}} - //expected-note@-2{{Assuming 'p' is null}} + //expected-note@-2{{Assuming 'p' is 'null'}} r.y = 5; // expected-warning {{Access to field 'y' results in a dereference of a null pointer (loaded from variable 'r')}} // expected-note@-1{{Access to field 'y' results in a dereference of a null pointer (loaded from variable 'r')}} } @@ -18,7 +18,7 @@ void testRefParam(int *ptr) { int &ref = *ptr; // expected-note {{'ref' initialized here}} if (ptr) - // expected-note@-1{{Assuming 'ptr' is null}} + // expected-note@-1{{Assuming 'ptr' is 'null'}} // expected-note@-2{{Taking false branch}} return; @@ -40,4 +40,4 @@ int *const &p2 = p;// expected-note{{'p2' initialized here}} return *p2; //expected-warning {{Dereference of null pointer}} // expected-note@-1{{Dereference of null pointer}} -} \ No newline at end of file +} Index: test/Analysis/diagnostics/dtors.cpp =================================================================== --- test/Analysis/diagnostics/dtors.cpp +++ test/Analysis/diagnostics/dtors.cpp @@ -16,7 +16,7 @@ S *s; smart_ptr(S *); S *get() { - return (x || 0) ? nullptr : s; // expected-note{{Field 'x' is 0}} + return (x || 0) ? nullptr : s; // expected-note{{Field 'x' is '0'}} // expected-note@-1{{Left side of '||' is false}} // expected-note@-2{{'?' condition is false}} // expected-warning@-3{{Use of memory after it is freed}} Index: test/Analysis/diagnostics/find_last_store.c =================================================================== --- test/Analysis/diagnostics/find_last_store.c +++ test/Analysis/diagnostics/find_last_store.c @@ -10,7 +10,7 @@ // expected-note@-1{{Returning from 'd'}} // expected-note@-2{{'e' initialized here}} - (void)(e || e->b); // expected-note{{Assuming 'e' is null}} + (void)(e || e->b); // expected-note{{Assuming 'e' is 'null'}} // expected-note@-1{{Left side of '||' is false}} // expected-note@-2{{Access to field 'b' results in a dereference of a null pointer (loaded from variable 'e')}} // expected-warning@-3{{Access to field 'b' results in a dereference of a null pointer (loaded from variable 'e')}} Index: test/Analysis/diagnostics/macro-null-return-suppression.cpp =================================================================== --- test/Analysis/diagnostics/macro-null-return-suppression.cpp +++ test/Analysis/diagnostics/macro-null-return-suppression.cpp @@ -52,7 +52,7 @@ int *x = RETURN_NULL(); x = returnFreshPointer(); // expected-note{{Value assigned to 'x'}} if (x) {} // expected-note{{Taking false branch}} - // expected-note@-1{{Assuming 'x' is null}} + // expected-note@-1{{Assuming 'x' is 'null'}} return *x; // expected-warning{{Dereference of null pointer}} // expected-note@-1{{Dereference}} } Index: test/Analysis/diagnostics/macros.cpp =================================================================== --- test/Analysis/diagnostics/macros.cpp +++ test/Analysis/diagnostics/macros.cpp @@ -4,7 +4,7 @@ #include "../Inputs/system-header-simulator-cxx.h" void testIntMacro(unsigned int i) { - if (i == UINT32_MAX) { // expected-note {{Assuming 'i' is equal to UINT32_MAX}} + if (i == UINT32_MAX) { // expected-note {{Assuming 'i' is equal to 'UINT32_MAX'}} // expected-note@-1 {{Taking true branch}} char *p = NULL; // expected-note {{'p' initialized to a null pointer value}} *p = 7; // expected-warning {{Dereference of null pointer (loaded from variable 'p')}} @@ -13,7 +13,7 @@ } void testNULLMacro(int *p) { - if (p == NULL) { // expected-note {{Assuming 'p' is equal to NULL}} + if (p == NULL) { // expected-note {{Assuming 'p' is equal to 'NULL'}} // expected-note@-1 {{Taking true branch}} *p = 7; // expected-warning {{Dereference of null pointer (loaded from variable 'p')}} // expected-note@-1 {{Dereference of null pointer (loaded from variable 'p')}} @@ -30,7 +30,7 @@ // There are no path notes on the comparison to float types. void testDoubleMacro(double d) { - if (d == DBL_MAX) { // expected-note {{Assuming 'd' is equal to DBL_MAX}} + if (d == DBL_MAX) { // expected-note {{Assuming 'd' is equal to 'DBL_MAX'}} // expected-note@-1 {{Taking true branch}} char *p = NULL; // expected-note {{'p' initialized to a null pointer value}} Index: test/Analysis/diagnostics/macros.m =================================================================== --- test/Analysis/diagnostics/macros.m +++ test/Analysis/diagnostics/macros.m @@ -12,7 +12,7 @@ @end void testBOOLMacro(BOOL b) { - if (b == YES) { // expected-note {{Assuming 'b' is equal to YES}} + if (b == YES) { // expected-note {{Assuming 'b' is equal to 'YES'}} // expected-note@-1 {{Taking true branch}} char *p = NULL;// expected-note {{'p' initialized to a null pointer value}} *p = 7; // expected-warning {{Dereference of null pointer (loaded from variable 'p')}} @@ -21,7 +21,7 @@ } void testNilMacro(NSMutableDictionary *d, NSObject *o) { - if (o == nil) // expected-note {{Assuming 'o' is equal to nil}} + if (o == nil) // expected-note {{Assuming 'o' is equal to 'nil'}} // expected-note@-1 {{Taking true branch}} [d setObject:o forKey:[o description]]; // expected-warning {{Key argument to 'setObject:forKey:' cannot be nil}} // expected-note@-1 {{'description' not called because the receiver is nil}} Index: test/Analysis/diagnostics/no-store-func-path-notes.cpp =================================================================== --- test/Analysis/diagnostics/no-store-func-path-notes.cpp +++ test/Analysis/diagnostics/no-store-func-path-notes.cpp @@ -102,7 +102,7 @@ C(int pX, int pY, bool Flag) { x = pX; - if (Flag) // expected-note{{Assuming 'Flag' is true}} + if (Flag) // expected-note{{Assuming 'Flag' is 'true'}} // expected-note@-1{{Taking true branch}} return; // expected-note{{Returning without writing to 'this->y'}} y = pY; Index: test/Analysis/diagnostics/text-diagnostics.c =================================================================== --- test/Analysis/diagnostics/text-diagnostics.c +++ test/Analysis/diagnostics/text-diagnostics.c @@ -15,7 +15,7 @@ *q = 1; // CHECK-LABEL: text-diagnostics.c:{{.*}}:6: warning: Dereference of null pointer (loaded from variable 'q') - // CHECK-NEXT: text-diagnostics.c:[[@LINE-5]]:7: note: Assuming 'q' is null + // CHECK-NEXT: text-diagnostics.c:[[@LINE-5]]:7: note: Assuming 'q' is 'null' // CHECK-NEXT: text-diagnostics.c:[[@LINE-6]]:3: note: Taking false branch // CHECK-NEXT: text-diagnostics.c:[[@LINE-5]]:6: note: Dereference of null pointer (loaded from variable 'q') } Index: test/Analysis/diagnostics/undef-value-param.c =================================================================== --- test/Analysis/diagnostics/undef-value-param.c +++ test/Analysis/diagnostics/undef-value-param.c @@ -10,7 +10,7 @@ } void foo(int c, int *x) { if (c) - //expected-note@-1{{Assuming 'c' is not equal to 0}} + //expected-note@-1{{Assuming 'c' is not equal to '0'}} //expected-note@-2{{Taking true branch}} return; // expected-note{{Returning without writing to '*x'}} *x = 5; @@ -29,7 +29,7 @@ void initArray(int x, double XYZ[3]) { if (x <= 0) //expected-note {{Taking true branch}} - //expected-note@-1 {{Assuming 'x' is <= 0}} + //expected-note@-1 {{Assuming 'x' is <= '0'}} return; XYZ[0] = 1; XYZ[1] = 1; @@ -49,7 +49,7 @@ }; void initStruct(int x, struct WithFields *X) { if (x <= 0) //expected-note {{Taking true branch}} - //expected-note@-1 {{Assuming 'x' is <= 0}} + //expected-note@-1 {{Assuming 'x' is <= '0'}} return; //expected-note{{Returning without writing to 'X->f1'}} X->f1 = getValidPtr(); Index: test/Analysis/diagnostics/undef-value-param.m =================================================================== --- test/Analysis/diagnostics/undef-value-param.m +++ test/Analysis/diagnostics/undef-value-param.m @@ -54,7 +54,7 @@ unsigned err = 0; SCDynamicStoreRef ref = anotherCreateRef(&err, x); if (err) { - //expected-note@-1{{Assuming 'err' is not equal to 0}} + //expected-note@-1{{Assuming 'err' is not equal to '0'}} //expected-note@-2{{Taking true branch}} CFRelease(ref); ref = 0; // expected-note{{nil object reference stored to 'ref'}} @@ -66,7 +66,7 @@ unsigned err = 0; SCDynamicStoreRef ref = anotherCreateRef(&err, x); if (err) { - //expected-note@-1{{Assuming 'err' is not equal to 0}} + //expected-note@-1{{Assuming 'err' is not equal to '0'}} //expected-note@-2{{Taking true branch}} CFRelease(ref); return; // expected-note{{Returning without writing to '*storeRef'}} Index: test/Analysis/inline-plist.c =================================================================== --- test/Analysis/inline-plist.c +++ test/Analysis/inline-plist.c @@ -11,7 +11,7 @@ int foo(int x, int y) { mmm(y); if (x != 0) { - // expected-note@-1 {{Assuming 'x' is equal to 0}} + // expected-note@-1 {{Assuming 'x' is equal to '0'}} // expected-note@-2 {{Taking false branch}} x++; } @@ -37,13 +37,13 @@ // should show when p is assumed to be null. void bar(int *p) { if (!!p) { - // expected-note@-1 {{Assuming 'p' is null}} + // expected-note@-1 {{Assuming 'p' is 'null'}} // expected-note@-2 {{Taking false branch}} return; } if (p == 0) { - // expected-note@-1 {{'p' is equal to null}} + // expected-note@-1 {{'p' is equal to 'null'}} // expected-note@-2 {{Taking true branch}} triggers_bug(p); // expected-note@-1 {{Passing null pointer value via 1st parameter 'p'}} Index: test/Analysis/inlining/Inputs/expected-plists/path-notes.c.plist =================================================================== --- test/Analysis/inlining/Inputs/expected-plists/path-notes.c.plist +++ test/Analysis/inlining/Inputs/expected-plists/path-notes.c.plist @@ -331,9 +331,9 @@ depth0 extended_message - Assuming 'a' is null + Assuming 'a' is 'null' message - Assuming 'a' is null + Assuming 'a' is 'null' kindcontrol @@ -583,9 +583,9 @@ depth0 extended_message - Assuming 'a' is null + Assuming 'a' is 'null' message - Assuming 'a' is null + Assuming 'a' is 'null' kindcontrol @@ -836,9 +836,9 @@ depth0 extended_message - Assuming 'a' is null + Assuming 'a' is 'null' message - Assuming 'a' is null + Assuming 'a' is 'null' kindcontrol Index: test/Analysis/inlining/Inputs/expected-plists/path-notes.cpp.plist =================================================================== --- test/Analysis/inlining/Inputs/expected-plists/path-notes.cpp.plist +++ test/Analysis/inlining/Inputs/expected-plists/path-notes.cpp.plist @@ -4271,9 +4271,9 @@ depth0 extended_message - Assuming field 'arr' is null + Assuming field 'arr' is 'null' message - Assuming field 'arr' is null + Assuming field 'arr' is 'null' kindcontrol Index: test/Analysis/inlining/Inputs/expected-plists/path-notes.m.plist =================================================================== --- test/Analysis/inlining/Inputs/expected-plists/path-notes.m.plist +++ test/Analysis/inlining/Inputs/expected-plists/path-notes.m.plist @@ -1596,9 +1596,9 @@ depth0 extended_message - Assuming 'myNil' is nil + Assuming 'myNil' is 'nil' message - Assuming 'myNil' is nil + Assuming 'myNil' is 'nil' kindcontrol Index: test/Analysis/inlining/path-notes.c =================================================================== --- test/Analysis/inlining/path-notes.c +++ test/Analysis/inlining/path-notes.c @@ -17,7 +17,7 @@ void testCheck(int *a) { if (a) { - // expected-note@-1 + {{Assuming 'a' is null}} + // expected-note@-1 + {{Assuming 'a' is 'null'}} // expected-note@-2 + {{Taking false branch}} ; } @@ -32,7 +32,7 @@ int *a = getPointer(); // expected-note@-1 {{'a' initialized here}} if (a) { - // expected-note@-1 + {{Assuming 'a' is null}} + // expected-note@-1 + {{Assuming 'a' is 'null'}} // expected-note@-2 + {{Taking false branch}} ; } @@ -44,7 +44,7 @@ a = getPointer(); // expected-note@-1 {{Value assigned to 'a'}} if (a) { - // expected-note@-1 + {{Assuming 'a' is null}} + // expected-note@-1 + {{Assuming 'a' is 'null'}} // expected-note@-2 + {{Taking false branch}} ; } Index: test/Analysis/inlining/path-notes.cpp =================================================================== --- test/Analysis/inlining/path-notes.cpp +++ test/Analysis/inlining/path-notes.cpp @@ -231,7 +231,7 @@ }; void Owner::testGetDerefExprOnMemberExprWithADot() { - if (arr) // expected-note {{Assuming field 'arr' is null}} + if (arr) // expected-note {{Assuming field 'arr' is 'null'}} // expected-note@-1 {{Taking false branch}} ; arr[1].x = 1; //expected-warning {{Dereference of null pointer}} Index: test/Analysis/inlining/path-notes.m =================================================================== --- test/Analysis/inlining/path-notes.m +++ test/Analysis/inlining/path-notes.m @@ -156,7 +156,7 @@ } id testCreateArrayLiteral(id myNil) { - if (myNil) // expected-note {{Assuming 'myNil' is nil}} + if (myNil) // expected-note {{Assuming 'myNil' is 'nil'}} ; // expected-note@-1 {{Taking false branch}} return @[ @"a", myNil, @"c" ]; // expected-warning {{Array element cannot be nil}} //expected-note@-1 {{Array element cannot be nil}} Index: test/Analysis/inlining/temp-dtors-path-notes.cpp =================================================================== --- test/Analysis/inlining/temp-dtors-path-notes.cpp +++ test/Analysis/inlining/temp-dtors-path-notes.cpp @@ -31,7 +31,7 @@ void test(int coin) { // We'd divide by zero in the automatic destructor for variable 'c'. - const C &c = coin ? C(1) : C(0); // expected-note {{Assuming 'coin' is 0}} + const C &c = coin ? C(1) : C(0); // expected-note {{Assuming 'coin' is '0'}} // expected-note@-1{{'?' condition is false}} // expected-note@-2{{Passing the value 0 via 1st parameter 'x'}} // expected-note@-3{{Calling constructor for 'C'}} Index: test/Analysis/inner-pointer.cpp =================================================================== --- test/Analysis/inner-pointer.cpp +++ test/Analysis/inner-pointer.cpp @@ -38,9 +38,9 @@ std::string s; const char *c2 = s.c_str(); if (cond) { - // expected-note@-1 {{Assuming 'cond' is true}} + // expected-note@-1 {{Assuming 'cond' is 'true'}} // expected-note@-2 {{Taking true branch}} - // expected-note@-3 {{Assuming 'cond' is false}} + // expected-note@-3 {{Assuming 'cond' is 'false'}} // expected-note@-4 {{Taking false branch}} consume(c); // expected-warning {{Inner pointer of container used after re/deallocation}} // expected-note@-1 {{Inner pointer of container used after re/deallocation}} @@ -73,9 +73,9 @@ std::wstring s; const wchar_t *c2 = s.c_str(); if (cond) { - // expected-note@-1 {{Assuming 'cond' is true}} + // expected-note@-1 {{Assuming 'cond' is 'true'}} // expected-note@-2 {{Taking true branch}} - // expected-note@-3 {{Assuming 'cond' is false}} + // expected-note@-3 {{Assuming 'cond' is 'false'}} // expected-note@-4 {{Taking false branch}} consume(c); // expected-warning {{Inner pointer of container used after re/deallocation}} // expected-note@-1 {{Inner pointer of container used after re/deallocation}} @@ -122,9 +122,9 @@ std::string s2; const char *c2 = s2.c_str(); if (cond) { - // expected-note@-1 {{Assuming 'cond' is true}} + // expected-note@-1 {{Assuming 'cond' is 'true'}} // expected-note@-2 {{Taking true branch}} - // expected-note@-3 {{Assuming 'cond' is false}} + // expected-note@-3 {{Assuming 'cond' is 'false'}} // expected-note@-4 {{Taking false branch}} consume(c1); // expected-warning {{Inner pointer of container used after re/deallocation}} // expected-note@-1 {{Inner pointer of container used after re/deallocation}} Index: test/Analysis/keychainAPI-diagnostic-visitor.m =================================================================== --- test/Analysis/keychainAPI-diagnostic-visitor.m +++ test/Analysis/keychainAPI-diagnostic-visitor.m @@ -27,7 +27,7 @@ char *x; st = SecKeychainItemCopyContent(2, ptr, ptr, &length, (void **)&bytes); // expected-note {{Data is allocated here}} x = bytes; - if (st == noErr) // expected-note {{Assuming 'st' is equal to noErr}} // expected-note{{Taking true branch}} + if (st == noErr) // expected-note {{Assuming 'st' is equal to 'noErr'}} // expected-note{{Taking true branch}} x = bytes;; length++; // expected-warning {{Allocated data is not released}} // expected-note{{Allocated data is not released}} Index: test/Analysis/loop-widening-notes.cpp =================================================================== --- test/Analysis/loop-widening-notes.cpp +++ test/Analysis/loop-widening-notes.cpp @@ -4,7 +4,7 @@ int bar(); int flag_a; int test_for_bug_25609() { - if (p_a == 0) // expected-note {{Assuming 'p_a' is equal to null}} + if (p_a == 0) // expected-note {{Assuming 'p_a' is equal to 'null'}} // expected-note@-1 {{Taking true branch}} bar(); for (int i = 0; // expected-note {{Loop condition is true. Entering loop body}} @@ -27,10 +27,10 @@ // expected-note@-2 {{Loop condition is false. Execution continues on line 30}} num = flag_b; } - if (num < 0) // expected-note {{Assuming 'num' is >= 0}} + if (num < 0) // expected-note {{Assuming 'num' is >= '0'}} // expected-note@-1 {{Taking false branch}} flag_b = 0; - else if (num >= 1) // expected-note {{Assuming 'num' is < 1}} + else if (num >= 1) // expected-note {{Assuming 'num' is < '1'}} // expected-note@-1 {{Taking false branch}} flag_b = 50; else @@ -47,7 +47,7 @@ num--; } while (flag_c-- > 0); //expected-note {{Value assigned to 'num'}} int local = 0; - if (num == 0) // expected-note {{Assuming 'num' is equal to 0}} + if (num == 0) // expected-note {{Assuming 'num' is equal to '0'}} // expected-note@-1 {{Taking true branch}} local = 10 / num; // no-crash expected-warning {{Division by zero}} // expected-note@-1 {{Division by zero}} @@ -64,7 +64,7 @@ ++i) { ++num; } - if (num == 0) // expected-note {{Assuming 'num' is equal to 0}} + if (num == 0) // expected-note {{Assuming 'num' is equal to '0'}} // expected-note@-1 {{Taking true branch}} flag_d += 10; return flag_d / num; // no-crash expected-warning {{Division by zero}} Index: test/Analysis/method-call-path-notes.cpp =================================================================== --- test/Analysis/method-call-path-notes.cpp +++ test/Analysis/method-call-path-notes.cpp @@ -26,7 +26,7 @@ } void test_ic_null(TestInstanceCall *p) { - if (!p) // expected-note {{Assuming 'p' is null}} expected-note {{Taking true branch}} + if (!p) // expected-note {{Assuming 'p' is 'null'}} expected-note {{Taking true branch}} p->foo(); // expected-warning {{Called C++ object pointer is null}} expected-note{{Called C++ object pointer is null}} } @@ -38,7 +38,7 @@ } void test_cast(const TestInstanceCall *p) { - if (!p) // expected-note {{Assuming 'p' is null}} expected-note {{Taking true branch}} + if (!p) // expected-note {{Assuming 'p' is 'null'}} expected-note {{Taking true branch}} const_cast(p)->foo(); // expected-warning {{Called C++ object pointer is null}} expected-note {{Called C++ object pointer is null}} } Index: test/Analysis/mig.mm =================================================================== --- test/Analysis/mig.mm +++ test/Analysis/mig.mm @@ -56,7 +56,7 @@ MIG_SERVER_ROUTINE kern_return_t basic_test(mach_port_name_t port, vm_address_t address, vm_size_t size) { vm_deallocate(port, address, size); // expected-note{{Value passed through parameter 'address' is deallocated}} - if (size > 10) { // expected-note{{Assuming 'size' is > 10}} + if (size > 10) { // expected-note{{Assuming 'size' is > '10'}} // expected-note@-1{{Taking true branch}} return KERN_ERROR; // expected-warning{{MIG callback fails with error after deallocating argument value. This is a use-after-free vulnerability because the caller will try to deallocate it again}} // expected-note@-1{{MIG callback fails with error after deallocating argument value. This is a use-after-free vulnerability because the caller will try to deallocate it again}} @@ -105,7 +105,7 @@ } will_deallocate{port, address, size}; if (size > 10) { - // expected-note@-1{{Assuming 'size' is > 10}} + // expected-note@-1{{Assuming 'size' is > '10'}} // expected-note@-2{{Taking true branch}} return KERN_ERROR; // expected-note@-1{{Calling '~WillDeallocate'}} Index: test/Analysis/new-ctor-malloc.cpp =================================================================== --- test/Analysis/new-ctor-malloc.cpp +++ test/Analysis/new-ctor-malloc.cpp @@ -8,7 +8,7 @@ void *operator new(size_t size) throw() { void *x = malloc(size); // expected-note {{Memory is allocated}} - if (!x) // expected-note {{Assuming 'x' is non-null}} + if (!x) // expected-note {{Assuming 'x' is 'non-null'}} // expected-note@-1 {{Taking false branch}} return nullptr; return x; Index: test/Analysis/null-deref-path-notes.m =================================================================== --- test/Analysis/null-deref-path-notes.m +++ test/Analysis/null-deref-path-notes.m @@ -12,7 +12,7 @@ int testNull(Root *obj) { if (obj) return 0; - // expected-note@-1 {{Assuming 'obj' is nil}} + // expected-note@-1 {{Assuming 'obj' is 'nil'}} // expected-note@-2 {{Taking false branch}} int *x = &obj->uniqueID; // expected-note{{'x' initialized to a null pointer value}} @@ -27,7 +27,7 @@ - (id)initWithID:(int)newID { self = [super initWithID:newID]; // expected-note{{Value assigned to 'self'}} if (self) return self; - // expected-note@-1 {{Assuming 'self' is nil}} + // expected-note@-1 {{Assuming 'self' is 'nil'}} // expected-note@-2 {{Taking false branch}} uniqueID = newID; // expected-warning{{Access to instance variable 'uniqueID' results in a dereference of a null pointer (loaded from variable 'self')}} expected-note{{Access to instance variable 'uniqueID' results in a dereference of a null pointer (loaded from variable 'self')}} @@ -39,7 +39,7 @@ void repeatedStores(int coin) { int *p = 0; if (coin) { - // expected-note@-1 {{Assuming 'coin' is 0}} + // expected-note@-1 {{Assuming 'coin' is '0'}} // expected-note@-2 {{Taking false branch}} extern int *getPointer(); p = getPointer(); Index: test/Analysis/osobject-retain-release.cpp =================================================================== --- test/Analysis/osobject-retain-release.cpp +++ test/Analysis/osobject-retain-release.cpp @@ -498,7 +498,7 @@ void check_dynamic_cast_null_branch(OSObject *obj) { OSArray *arr1 = OSArray::withCapacity(10); // expected-note{{Call to method 'OSArray::withCapacity' returns an OSObject}} OSArray *arr = OSDynamicCast(OSArray, obj); // expected-note{{Assuming dynamic cast returns null due to type mismatch}} - if (!arr) // expected-note{{'arr' is null}} + if (!arr) // expected-note{{'arr' is 'null'}} // expected-note@-1{{Taking true branch}} return; // expected-warning{{Potential leak of an object stored into 'arr1'}} // expected-note@-1{{Object leaked}} @@ -601,13 +601,13 @@ { OSObjectPtr p(obj); // expected-note{{Calling constructor for 'smart_ptr'}} // expected-note@-1{{Returning from constructor for 'smart_ptr'}} - // expected-note@os_smart_ptr.h:13{{Field 'pointer' is non-null}} + // expected-note@os_smart_ptr.h:13{{Field 'pointer' is 'non-null'}} // expected-note@os_smart_ptr.h:13{{Taking true branch}} // expected-note@os_smart_ptr.h:14{{Calling 'smart_ptr::_retain'}} // expected-note@os_smart_ptr.h:71{{Reference count incremented. The object now has a +2 retain count}} // expected-note@os_smart_ptr.h:14{{Returning from 'smart_ptr::_retain'}} } // expected-note{{Calling '~smart_ptr'}} - // expected-note@os_smart_ptr.h:35{{Field 'pointer' is non-null}} + // expected-note@os_smart_ptr.h:35{{Field 'pointer' is 'non-null'}} // expected-note@os_smart_ptr.h:35{{Taking true branch}} // expected-note@os_smart_ptr.h:36{{Calling 'smart_ptr::_release'}} // expected-note@os_smart_ptr.h:76{{Reference count decremented. The object now has a +1 retain count}} @@ -623,13 +623,13 @@ { OSObjectPtr p(obj); // expected-note{{Calling constructor for 'smart_ptr'}} // expected-note@-1{{Returning from constructor for 'smart_ptr'}} - // expected-note@os_smart_ptr.h:13{{Field 'pointer' is non-null}} + // expected-note@os_smart_ptr.h:13{{Field 'pointer' is 'non-null'}} // expected-note@os_smart_ptr.h:13{{Taking true branch}} // expected-note@os_smart_ptr.h:14{{Calling 'smart_ptr::_retain'}} // expected-note@os_smart_ptr.h:71{{Reference count incremented. The object now has a +2 retain count}} // expected-note@os_smart_ptr.h:14{{Returning from 'smart_ptr::_retain'}} } // expected-note{{Calling '~smart_ptr'}} - // expected-note@os_smart_ptr.h:35{{Field 'pointer' is non-null}} + // expected-note@os_smart_ptr.h:35{{Field 'pointer' is 'non-null'}} // expected-note@os_smart_ptr.h:35{{Taking true branch}} // expected-note@os_smart_ptr.h:36{{Calling 'smart_ptr::_release'}} // expected-note@os_smart_ptr.h:76{{Reference count decremented. The object now has a +1 retain count}} Index: test/Analysis/retain-release-path-notes.m =================================================================== --- test/Analysis/retain-release-path-notes.m +++ test/Analysis/retain-release-path-notes.m @@ -204,7 +204,7 @@ @implementation MyObj -(id)initX { - if (Cond) // expected-note {{Assuming 'Cond' is not equal to 0}} + if (Cond) // expected-note {{Assuming 'Cond' is not equal to '0'}} // expected-note@-1{{Taking true branch}} return 0; self = [super init]; Index: test/Analysis/test-after-div-zero.c =================================================================== --- test/Analysis/test-after-div-zero.c +++ test/Analysis/test-after-div-zero.c @@ -57,7 +57,7 @@ } // expected-note@-1 {{Value being compared against zero has already been used for division}} void err_orig_checker(int x) { - if (x != 0) // expected-note {{Assuming 'x' is equal to 0}} expected-note {{Taking false branch}} + if (x != 0) // expected-note {{Assuming 'x' is equal to '0'}} expected-note {{Taking false branch}} return; var = 77 / x; // expected-warning {{Division by zero}} expected-note {{Division by zero}} if (!x) {} // no-warning Index: test/Analysis/uninit-vals.c =================================================================== --- test/Analysis/uninit-vals.c +++ test/Analysis/uninit-vals.c @@ -63,7 +63,7 @@ void f6(int x) { int a[20]; - if (x == 25) {} // expected-note{{Assuming 'x' is equal to 25}} + if (x == 25) {} // expected-note{{Assuming 'x' is equal to '25'}} // expected-note@-1{{Taking true branch}} if (a[x] == 123) {} // expected-warning{{The left operand of '==' is a garbage value due to array index out of bounds}} // expected-note@-1{{The left operand of '==' is a garbage value due to array index out of bounds}} Index: test/Analysis/uninit-vals.m =================================================================== --- test/Analysis/uninit-vals.m +++ test/Analysis/uninit-vals.m @@ -164,7 +164,7 @@ // expected-note@-1{{TRUE}} testObj->origin = makePoint(0.0, 0.0); - if (testObj->size > 0) { ; } // expected-note{{Assuming field 'size' is <= 0}} + if (testObj->size > 0) { ; } // expected-note{{Assuming field 'size' is <= '0'}} // expected-note@-1{{Taking false branch}} // FIXME: Assigning to 'testObj->origin' kills the default binding for the @@ -219,13 +219,13 @@ // expected-note@-1{{TRUE}} testObj->origin = makeIntPoint(1, 2); - if (testObj->size > 0) { ; } // expected-note{{Assuming field 'size' is <= 0}} + if (testObj->size > 0) { ; } // expected-note{{Assuming field 'size' is <= '0'}} // expected-note@-1{{Taking false branch}} - // expected-note@-2{{Assuming field 'size' is <= 0}} + // expected-note@-2{{Assuming field 'size' is <= '0'}} // expected-note@-3{{Taking false branch}} - // expected-note@-4{{Assuming field 'size' is <= 0}} + // expected-note@-4{{Assuming field 'size' is <= '0'}} // expected-note@-5{{Taking false branch}} - // expected-note@-6{{Assuming field 'size' is <= 0}} + // expected-note@-6{{Assuming field 'size' is <= '0'}} // expected-note@-7{{Taking false branch}} // FIXME: Assigning to 'testObj->origin' kills the default binding for the @@ -321,11 +321,11 @@ // expected-note@-1{{TRUE}} testObj->origin = makeIntPoint2D(1, 2); - if (testObj->size > 0) { ; } // expected-note{{Field 'size' is <= 0}} + if (testObj->size > 0) { ; } // expected-note{{Field 'size' is <= '0'}} // expected-note@-1{{Taking false branch}} - // expected-note@-2{{Field 'size' is <= 0}} + // expected-note@-2{{Field 'size' is <= '0'}} // expected-note@-3{{Taking false branch}} - // expected-note@-4{{Field 'size' is <= 0}} + // expected-note@-4{{Field 'size' is <= '0'}} // expected-note@-5{{Taking false branch}} clang_analyzer_eval(testObj->size == 0); // expected-warning{{TRUE}} Index: test/Analysis/use-after-move.cpp =================================================================== --- test/Analysis/use-after-move.cpp +++ test/Analysis/use-after-move.cpp @@ -223,10 +223,10 @@ A a; if (i == 1) { #ifndef PEACEFUL - // expected-note@-2 {{Assuming 'i' is not equal to 1}} + // expected-note@-2 {{Assuming 'i' is not equal to '1'}} // expected-note@-3 {{Taking false branch}} // And the other report: - // expected-note@-5 {{Assuming 'i' is not equal to 1}} + // expected-note@-5 {{Assuming 'i' is not equal to '1'}} // expected-note@-6 {{Taking false branch}} #endif A b; @@ -235,10 +235,10 @@ } if (i == 2) { #ifndef PEACEFUL - // expected-note@-2 {{Assuming 'i' is not equal to 2}} + // expected-note@-2 {{Assuming 'i' is not equal to '2'}} // expected-note@-3 {{Taking false branch}} // And the other report: - // expected-note@-5 {{Assuming 'i' is not equal to 2}} + // expected-note@-5 {{Assuming 'i' is not equal to '2'}} // expected-note@-6 {{Taking false branch}} #endif a.foo(); // no-warning @@ -248,18 +248,18 @@ A a; if (i == 1) { #ifndef PEACEFUL - // expected-note@-2 {{'i' is not equal to 1}} + // expected-note@-2 {{'i' is not equal to '1'}} // expected-note@-3 {{Taking false branch}} - // expected-note@-4 {{'i' is not equal to 1}} + // expected-note@-4 {{'i' is not equal to '1'}} // expected-note@-5 {{Taking false branch}} #endif std::move(a); } if (i == 2) { #ifndef PEACEFUL - // expected-note@-2 {{'i' is not equal to 2}} + // expected-note@-2 {{'i' is not equal to '2'}} // expected-note@-3 {{Taking false branch}} - // expected-note@-4 {{'i' is not equal to 2}} + // expected-note@-4 {{'i' is not equal to '2'}} // expected-note@-5 {{Taking false branch}} #endif a = A(); @@ -297,7 +297,7 @@ #endif if (i < 10) { #ifndef PEACEFUL - // expected-note@-2 {{Assuming 'i' is >= 10}} + // expected-note@-2 {{Assuming 'i' is >= '10'}} // expected-note@-3 {{Taking false branch}} #endif a = A(); @@ -305,7 +305,7 @@ if (i > 5) { a.foo(); #ifndef PEACEFUL - // expected-note@-3 {{'i' is > 5}} + // expected-note@-3 {{'i' is > '5'}} // expected-note@-4 {{Taking true branch}} // expected-warning@-4 {{Method called on moved-from object 'a'}} // expected-note@-5 {{Method called on moved-from object 'a'}} @@ -462,7 +462,7 @@ a.foo(); #ifndef PEACEFUL // expected-note@-5 {{Object 'a' is moved}} - // expected-note@-4 {{Assuming 'cond' is true}} + // expected-note@-4 {{Assuming 'cond' is 'true'}} // expected-note@-5 {{Taking true branch}} // expected-warning@-5 {{Method called on moved-from object 'a'}} // expected-note@-6 {{Method called on moved-from object 'a'}} @@ -650,7 +650,7 @@ A a; if (i > 0) { #ifndef PEACEFUL - // expected-note@-2 {{Assuming 'i' is > 0}} + // expected-note@-2 {{Assuming 'i' is > '0'}} // expected-note@-3 {{Taking true branch}} #endif A b; @@ -664,7 +664,7 @@ A a, b; i > 0 ? (void)(b = std::move(a)) : a.bar(); // no-warning #ifndef PEACEFUL - // expected-note@-2 {{'i' is > 0}} + // expected-note@-2 {{'i' is > '0'}} // expected-note@-3 {{'?' condition is true}} #endif } Index: test/Analysis/valist-uninitialized-no-undef.c =================================================================== --- test/Analysis/valist-uninitialized-no-undef.c +++ test/Analysis/valist-uninitialized-no-undef.c @@ -26,7 +26,7 @@ va_list va; vprintf(isstring ? "%s" : "%d", va); // expected-warning{{Function 'vprintf' is called with an uninitialized va_list argument}} // expected-note@-1{{Function 'vprintf' is called with an uninitialized va_list argument}} - // expected-note@-2{{Assuming 'isstring' is 0}} + // expected-note@-2{{Assuming 'isstring' is '0'}} // expected-note@-3{{'?' condition is false}} } Index: test/Analysis/valist-uninitialized.c =================================================================== --- test/Analysis/valist-uninitialized.c +++ test/Analysis/valist-uninitialized.c @@ -38,7 +38,7 @@ void f4(int cond, ...) { va_list va; - if (cond) { // expected-note{{Assuming 'cond' is 0}} + if (cond) { // expected-note{{Assuming 'cond' is '0'}} // expected-note@-1{{Taking false branch}} va_start(va, cond); (void)va_arg(va,int); Index: test/Analysis/virtualcall.cpp =================================================================== --- test/Analysis/virtualcall.cpp +++ test/Analysis/virtualcall.cpp @@ -164,9 +164,9 @@ X(int i) { if (i > 0) { #if !PUREONLY - // expected-note-re@-2 {{{{^}}'i' is > 0}} + // expected-note-re@-2 {{{{^}}'i' is > '0'}} // expected-note-re@-3 {{{{^}}Taking true branch}} - // expected-note-re@-4 {{{{^}}'i' is <= 0}} + // expected-note-re@-4 {{{{^}}'i' is <= '0'}} // expected-note-re@-5 {{{{^}}Taking false branch}} #endif X x(i - 1);