corresponds to another argument being valid.
This makes it clear that the code is correct despite the PVS-Studio
report that a pointer might be dereferenced prior to being checked for
whether it is null. It likely is also enough for static analyzers to not
flag the code.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@285982
91177308-0d34-0410-b5e6-
96231b3b80d8
SourceLocation RBracLoc,
MultiExprArg ArgsIn,
bool isImplicit) {
+ assert((Receiver || SuperLoc.isValid()) && "If the Receiver is null, the "
+ "SuperLoc must be valid so we can "
+ "use it instead.");
+
// The location of the receiver.
SourceLocation Loc = SuperLoc.isValid()? SuperLoc : Receiver->getLocStart();
SourceRange RecRange =