/// \brief About to call the constructor for a matcher.
enum ConstructMatcherEnum { ConstructMatcher };
Context(ConstructMatcherEnum, Diagnostics *Error, StringRef MatcherName,
- const SourceRange &MatcherRange);
+ SourceRange MatcherRange);
/// \brief About to recurse into parsing one argument for a matcher.
enum MatcherArgEnum { MatcherArg };
Context(MatcherArgEnum, Diagnostics *Error, StringRef MatcherName,
- const SourceRange &MatcherRange, unsigned ArgNumber);
+ SourceRange MatcherRange, unsigned ArgNumber);
~Context();
private:
/// All the context information will be kept on the error message.
/// \return a helper class to allow the caller to pass the arguments for the
/// error message, using the << operator.
- ArgStream addError(const SourceRange &Range, ErrorType Error);
+ ArgStream addError(SourceRange Range, ErrorType Error);
/// \brief Information stored for one frame of the context.
struct ContextFrame {
/// matcher if an error occurred. In that case, \c Error will contain a
/// description of the error.
virtual VariantMatcher actOnMatcherExpression(MatcherCtor Ctor,
- const SourceRange &NameRange,
+ SourceRange NameRange,
StringRef BindID,
ArrayRef<ParserValue> Args,
Diagnostics *Error) = 0;
lookupMatcherCtor(StringRef MatcherName) override;
VariantMatcher actOnMatcherExpression(MatcherCtor Ctor,
- const SourceRange &NameRange,
+ SourceRange NameRange,
StringRef BindID,
ArrayRef<ParserValue> Args,
Diagnostics *Error) override;
/// the signature. In that case \c Error will contain the description of
/// the error.
static VariantMatcher constructMatcher(MatcherCtor Ctor,
- const SourceRange &NameRange,
+ SourceRange NameRange,
ArrayRef<ParserValue> Args,
Diagnostics *Error);
/// If the matcher is not bindable, it sets an error in \c Error and returns
/// a null matcher.
static VariantMatcher constructBoundMatcher(MatcherCtor Ctor,
- const SourceRange &NameRange,
+ SourceRange NameRange,
StringRef BindID,
ArrayRef<ParserValue> Args,
Diagnostics *Error);
}
inline const DiagnosticBuilder &operator<<(const DiagnosticBuilder &DB,
- const SourceRange &R) {
+ SourceRange R) {
DB.AddSourceRange(CharSourceRange::getTokenRange(R));
return DB;
}
inline const DiagnosticBuilder &operator<<(const DiagnosticBuilder &DB,
ArrayRef<SourceRange> Ranges) {
- for (const SourceRange &R: Ranges)
+ for (SourceRange R : Ranges)
DB.AddSourceRange(CharSourceRange::getTokenRange(R));
return DB;
}
}
friend inline const PartialDiagnostic &operator<<(const PartialDiagnostic &PD,
- const SourceRange &R) {
+ SourceRange R) {
PD.AddSourceRange(CharSourceRange::getTokenRange(R));
return PD;
}
SourceLocation getBegin() const { return Range.getBegin(); }
SourceLocation getEnd() const { return Range.getEnd(); }
- const SourceRange &getAsRange() const { return Range; }
+ SourceRange getAsRange() const { return Range; }
void setBegin(SourceLocation b) { Range.setBegin(b); }
void setEnd(SourceLocation e) { Range.setEnd(e); }
NestedNameSpecifierLocBuilder Builder;
public:
- const SourceRange &getRange() const { return Range; }
- void setRange(const SourceRange &R) { Range = R; }
+ SourceRange getRange() const { return Range; }
+ void setRange(SourceRange R) { Range = R; }
void setBeginLoc(SourceLocation Loc) { Range.setBegin(Loc); }
void setEndLoc(SourceLocation Loc) { Range.setEnd(Loc); }
SourceLocation getBeginLoc() const { return Range.getBegin(); }
CXXScopeSpec &getTypeSpecScope() { return TypeScope; }
const CXXScopeSpec &getTypeSpecScope() const { return TypeScope; }
- const SourceRange &getSourceRange() const LLVM_READONLY { return Range; }
+ SourceRange getSourceRange() const LLVM_READONLY { return Range; }
SourceLocation getLocStart() const LLVM_READONLY { return Range.getBegin(); }
SourceLocation getLocEnd() const LLVM_READONLY { return Range.getEnd(); }
}
/// \brief Get the source range that spans this declarator.
- const SourceRange &getSourceRange() const LLVM_READONLY { return Range; }
+ SourceRange getSourceRange() const LLVM_READONLY { return Range; }
SourceLocation getLocStart() const LLVM_READONLY { return Range.getBegin(); }
SourceLocation getLocEnd() const LLVM_READONLY { return Range.getEnd(); }
/// given declspec, unless its location is invalid. Adopts the range start if
/// the current range start is invalid.
void ExtendWithDeclSpec(const DeclSpec &DS) {
- const SourceRange &SR = DS.getSourceRange();
+ SourceRange SR = DS.getSourceRange();
if (Range.getBegin().isInvalid())
Range.setBegin(SR.getBegin());
if (!SR.getEnd().isInvalid())
const FunctionProtoType *FPT);
void UpdateExceptionSpec(FunctionDecl *FD,
const FunctionProtoType::ExceptionSpecInfo &ESI);
- bool CheckSpecifiedExceptionType(QualType &T, const SourceRange &Range);
+ bool CheckSpecifiedExceptionType(QualType &T, SourceRange Range);
bool CheckDistantExceptionSpec(QualType T);
bool CheckEquivalentExceptionSpec(FunctionDecl *Old, FunctionDecl *New);
bool CheckEquivalentExceptionSpec(
ExprResult &SrcExpr,
bool DoFunctionPointerConverion = false,
bool Complain = false,
- const SourceRange& OpRangeForComplaining = SourceRange(),
+ SourceRange OpRangeForComplaining = SourceRange(),
QualType DestTypeForComplaining = QualType(),
unsigned DiagIDForComplaining = 0);
ActOnUnaryExprOrTypeTraitExpr(SourceLocation OpLoc,
UnaryExprOrTypeTrait ExprKind,
bool IsType, void *TyOrEx,
- const SourceRange &ArgRange);
+ SourceRange ArgRange);
ExprResult CheckPlaceholderExpr(Expr *E);
bool CheckVecStepExpr(Expr *E);
public:
bool isPoint;
- PathDiagnosticRange(const SourceRange &R, bool isP = false)
+ PathDiagnosticRange(SourceRange R, bool isP = false)
: SourceRange(R), isPoint(isP) {}
PathDiagnosticRange() : isPoint(false) {}
Diagnostics::Context::Context(ConstructMatcherEnum, Diagnostics *Error,
StringRef MatcherName,
- const SourceRange &MatcherRange)
+ SourceRange MatcherRange)
: Error(Error) {
Error->pushContextFrame(CT_MatcherConstruct, MatcherRange) << MatcherName;
}
Diagnostics::Context::Context(MatcherArgEnum, Diagnostics *Error,
StringRef MatcherName,
- const SourceRange &MatcherRange,
+ SourceRange MatcherRange,
unsigned ArgNumber)
: Error(Error) {
Error->pushContextFrame(CT_MatcherArg, MatcherRange) << ArgNumber
return *this;
}
-Diagnostics::ArgStream Diagnostics::addError(const SourceRange &Range,
+Diagnostics::ArgStream Diagnostics::addError(SourceRange Range,
ErrorType Error) {
Errors.emplace_back();
ErrorContent &Last = Errors.back();
}
}
-static void maybeAddLineAndColumn(const SourceRange &Range,
+static void maybeAddLineAndColumn(SourceRange Range,
llvm::raw_ostream &OS) {
if (Range.Start.Line > 0 && Range.Start.Column > 0) {
OS << Range.Start.Line << ":" << Range.Start.Column << ": ";
class MatcherDescriptor {
public:
virtual ~MatcherDescriptor() {}
- virtual VariantMatcher create(const SourceRange &NameRange,
+ virtual VariantMatcher create(SourceRange NameRange,
ArrayRef<ParserValue> Args,
Diagnostics *Error) const = 0;
public:
typedef VariantMatcher (*MarshallerType)(void (*Func)(),
StringRef MatcherName,
- const SourceRange &NameRange,
+ SourceRange NameRange,
ArrayRef<ParserValue> Args,
Diagnostics *Error);
RetKinds(RetKinds.begin(), RetKinds.end()),
ArgKinds(ArgKinds.begin(), ArgKinds.end()) {}
- VariantMatcher create(const SourceRange &NameRange,
+ VariantMatcher create(SourceRange NameRange,
ArrayRef<ParserValue> Args,
Diagnostics *Error) const override {
return Marshaller(Func, MatcherName, NameRange, Args, Error);
template <typename ResultT, typename ArgT,
ResultT (*Func)(ArrayRef<const ArgT *>)>
VariantMatcher
-variadicMatcherDescriptor(StringRef MatcherName, const SourceRange &NameRange,
+variadicMatcherDescriptor(StringRef MatcherName, SourceRange NameRange,
ArrayRef<ParserValue> Args, Diagnostics *Error) {
ArgT **InnerArgs = new ArgT *[Args.size()]();
class VariadicFuncMatcherDescriptor : public MatcherDescriptor {
public:
typedef VariantMatcher (*RunFunc)(StringRef MatcherName,
- const SourceRange &NameRange,
+ SourceRange NameRange,
ArrayRef<ParserValue> Args,
Diagnostics *Error);
BuildReturnTypeVector<ResultT>::build(RetKinds);
}
- VariantMatcher create(const SourceRange &NameRange,
+ VariantMatcher create(SourceRange NameRange,
ArrayRef<ParserValue> Args,
Diagnostics *Error) const override {
return Func(MatcherName, NameRange, Args, Error);
/// \brief 0-arg marshaller function.
template <typename ReturnType>
static VariantMatcher matcherMarshall0(void (*Func)(), StringRef MatcherName,
- const SourceRange &NameRange,
+ SourceRange NameRange,
ArrayRef<ParserValue> Args,
Diagnostics *Error) {
typedef ReturnType (*FuncType)();
/// \brief 1-arg marshaller function.
template <typename ReturnType, typename ArgType1>
static VariantMatcher matcherMarshall1(void (*Func)(), StringRef MatcherName,
- const SourceRange &NameRange,
+ SourceRange NameRange,
ArrayRef<ParserValue> Args,
Diagnostics *Error) {
typedef ReturnType (*FuncType)(ArgType1);
/// \brief 2-arg marshaller function.
template <typename ReturnType, typename ArgType1, typename ArgType2>
static VariantMatcher matcherMarshall2(void (*Func)(), StringRef MatcherName,
- const SourceRange &NameRange,
+ SourceRange NameRange,
ArrayRef<ParserValue> Args,
Diagnostics *Error) {
typedef ReturnType (*FuncType)(ArgType1, ArgType2);
~OverloadedMatcherDescriptor() override {}
- VariantMatcher create(const SourceRange &NameRange,
+ VariantMatcher create(SourceRange NameRange,
ArrayRef<ParserValue> Args,
Diagnostics *Error) const override {
std::vector<VariantMatcher> Constructed;
: MinCount(MinCount), MaxCount(MaxCount), Op(Op),
MatcherName(MatcherName) {}
- VariantMatcher create(const SourceRange &NameRange,
+ VariantMatcher create(SourceRange NameRange,
ArrayRef<ParserValue> Args,
Diagnostics *Error) const override {
if (Args.size() < MinCount || MaxCount < Args.size()) {
}
VariantMatcher Parser::RegistrySema::actOnMatcherExpression(
- MatcherCtor Ctor, const SourceRange &NameRange, StringRef BindID,
+ MatcherCtor Ctor, SourceRange NameRange, StringRef BindID,
ArrayRef<ParserValue> Args, Diagnostics *Error) {
if (BindID.empty()) {
return Registry::constructMatcher(Ctor, NameRange, Args, Error);
// static
VariantMatcher Registry::constructMatcher(MatcherCtor Ctor,
- const SourceRange &NameRange,
+ SourceRange NameRange,
ArrayRef<ParserValue> Args,
Diagnostics *Error) {
return Ctor->create(NameRange, Args, Error);
// static
VariantMatcher Registry::constructBoundMatcher(MatcherCtor Ctor,
- const SourceRange &NameRange,
+ SourceRange NameRange,
StringRef BindID,
ArrayRef<ParserValue> Args,
Diagnostics *Error) {
}
WhitespaceManager::Change::Change(
- bool CreateReplacement, const SourceRange &OriginalWhitespaceRange,
+ bool CreateReplacement, SourceRange OriginalWhitespaceRange,
unsigned IndentLevel, int Spaces, unsigned StartOfTokenColumn,
unsigned NewlinesBefore, StringRef PreviousLinePostfix,
StringRef CurrentLinePrefix, tok::TokenKind Kind, bool ContinuesPPDirective,
}
}
-void WhitespaceManager::storeReplacement(const SourceRange &Range,
+void WhitespaceManager::storeReplacement(SourceRange Range,
StringRef Text) {
unsigned WhitespaceLength = SourceMgr.getFileOffset(Range.getEnd()) -
SourceMgr.getFileOffset(Range.getBegin());
///
/// \p StartOfTokenColumn and \p InPPDirective will be used to lay out
/// trailing comments and escaped newlines.
- Change(bool CreateReplacement, const SourceRange &OriginalWhitespaceRange,
+ Change(bool CreateReplacement, SourceRange OriginalWhitespaceRange,
unsigned IndentLevel, int Spaces, unsigned StartOfTokenColumn,
unsigned NewlinesBefore, StringRef PreviousLinePostfix,
StringRef CurrentLinePrefix, tok::TokenKind Kind,
void generateChanges();
/// \brief Stores \p Text as the replacement for the whitespace in \p Range.
- void storeReplacement(const SourceRange &Range, StringRef Text);
+ void storeReplacement(SourceRange Range, StringRef Text);
void appendNewlineText(std::string &Text, unsigned Newlines);
void appendNewlineText(std::string &Text, unsigned Newlines,
unsigned PreviousEndOfTokenColumn,
unsigned getBitWidth() const { return Val.getBitWidth(); }
bool isUnsigned() const { return Val.isUnsigned(); }
- const SourceRange &getRange() const { return Range; }
+ SourceRange getRange() const { return Range; }
void setRange(SourceLocation L) { Range.setBegin(L); Range.setEnd(L); }
void setRange(SourceLocation B, SourceLocation E) {
DiagnosticBuilder DB =
Diag(MacroName,
diag::note_init_list_at_beginning_of_macro_argument);
- for (const SourceRange &Range : InitLists)
+ for (SourceRange Range : InitLists)
DB << Range;
}
return nullptr;
return nullptr;
DiagnosticBuilder DB = Diag(MacroName, diag::note_suggest_parens_for_macro);
- for (const SourceRange &ParenLocation : ParenHints) {
+ for (SourceRange ParenLocation : ParenHints) {
DB << FixItHint::CreateInsertion(ParenLocation.getBegin(), "(");
DB << FixItHint::CreateInsertion(ParenLocation.getEnd(), ")");
}
}
static void diagnoseDynamicExceptionSpecification(
- Parser &P, const SourceRange &Range, bool IsNoexcept) {
+ Parser &P, SourceRange Range, bool IsNoexcept) {
if (P.getLangOpts().CPlusPlus11) {
const char *Replacement = IsNoexcept ? "noexcept" : "noexcept(false)";
P.Diag(Range.getBegin(), diag::warn_exception_spec_deprecated) << Range;
unsigned &msg);
static TryCastResult TryStaticReferenceDowncast(Sema &Self, Expr *SrcExpr,
QualType DestType, bool CStyle,
- const SourceRange &OpRange,
+ SourceRange OpRange,
unsigned &msg,
CastKind &Kind,
CXXCastPath &BasePath);
static TryCastResult TryStaticPointerDowncast(Sema &Self, QualType SrcType,
QualType DestType, bool CStyle,
- const SourceRange &OpRange,
+ SourceRange OpRange,
unsigned &msg,
CastKind &Kind,
CXXCastPath &BasePath);
static TryCastResult TryStaticDowncast(Sema &Self, CanQualType SrcType,
CanQualType DestType, bool CStyle,
- const SourceRange &OpRange,
+ SourceRange OpRange,
QualType OrigSrcType,
QualType OrigDestType, unsigned &msg,
CastKind &Kind,
static TryCastResult TryStaticMemberPointerUpcast(Sema &Self, ExprResult &SrcExpr,
QualType SrcType,
QualType DestType,bool CStyle,
- const SourceRange &OpRange,
+ SourceRange OpRange,
unsigned &msg,
CastKind &Kind,
CXXCastPath &BasePath);
static TryCastResult TryStaticImplicitCast(Sema &Self, ExprResult &SrcExpr,
QualType DestType,
Sema::CheckedConversionKind CCK,
- const SourceRange &OpRange,
+ SourceRange OpRange,
unsigned &msg, CastKind &Kind,
bool ListInitialization);
static TryCastResult TryStaticCast(Sema &Self, ExprResult &SrcExpr,
QualType DestType,
Sema::CheckedConversionKind CCK,
- const SourceRange &OpRange,
+ SourceRange OpRange,
unsigned &msg, CastKind &Kind,
CXXCastPath &BasePath,
bool ListInitialization);
unsigned &msg);
static TryCastResult TryReinterpretCast(Sema &Self, ExprResult &SrcExpr,
QualType DestType, bool CStyle,
- const SourceRange &OpRange,
+ SourceRange OpRange,
unsigned &msg,
CastKind &Kind);
static TryCastResult TryStaticCast(Sema &Self, ExprResult &SrcExpr,
QualType DestType,
Sema::CheckedConversionKind CCK,
- const SourceRange &OpRange, unsigned &msg,
+ SourceRange OpRange, unsigned &msg,
CastKind &Kind, CXXCastPath &BasePath,
bool ListInitialization) {
// Determine whether we have the semantics of a C-style cast.
/// Tests whether a conversion according to C++ 5.2.9p5 is valid.
TryCastResult
TryStaticReferenceDowncast(Sema &Self, Expr *SrcExpr, QualType DestType,
- bool CStyle, const SourceRange &OpRange,
+ bool CStyle, SourceRange OpRange,
unsigned &msg, CastKind &Kind,
CXXCastPath &BasePath) {
// C++ 5.2.9p5: An lvalue of type "cv1 B", where B is a class type, can be
/// Tests whether a conversion according to C++ 5.2.9p8 is valid.
TryCastResult
TryStaticPointerDowncast(Sema &Self, QualType SrcType, QualType DestType,
- bool CStyle, const SourceRange &OpRange,
+ bool CStyle, SourceRange OpRange,
unsigned &msg, CastKind &Kind,
CXXCastPath &BasePath) {
// C++ 5.2.9p8: An rvalue of type "pointer to cv1 B", where B is a class
/// DestType is possible and allowed.
TryCastResult
TryStaticDowncast(Sema &Self, CanQualType SrcType, CanQualType DestType,
- bool CStyle, const SourceRange &OpRange, QualType OrigSrcType,
+ bool CStyle, SourceRange OpRange, QualType OrigSrcType,
QualType OrigDestType, unsigned &msg,
CastKind &Kind, CXXCastPath &BasePath) {
// We can only work with complete types. But don't complain if it doesn't work
TryCastResult
TryStaticMemberPointerUpcast(Sema &Self, ExprResult &SrcExpr, QualType SrcType,
QualType DestType, bool CStyle,
- const SourceRange &OpRange,
+ SourceRange OpRange,
unsigned &msg, CastKind &Kind,
CXXCastPath &BasePath) {
const MemberPointerType *DestMemPtr = DestType->getAs<MemberPointerType>();
TryCastResult
TryStaticImplicitCast(Sema &Self, ExprResult &SrcExpr, QualType DestType,
Sema::CheckedConversionKind CCK,
- const SourceRange &OpRange, unsigned &msg,
+ SourceRange OpRange, unsigned &msg,
CastKind &Kind, bool ListInitialization) {
if (DestType->isRecordType()) {
if (Self.RequireCompleteType(OpRange.getBegin(), DestType,
static TryCastResult TryReinterpretCast(Sema &Self, ExprResult &SrcExpr,
QualType DestType, bool CStyle,
- const SourceRange &OpRange,
+ SourceRange OpRange,
unsigned &msg,
CastKind &Kind) {
bool IsLValueCast = false;
return Context.getFunctionType(Context.VoidTy, None, EPI);
}
-static void extendLeft(SourceRange &R, const SourceRange &Before) {
+static void extendLeft(SourceRange &R, SourceRange Before) {
if (Before.isInvalid())
return;
R.setBegin(Before.getBegin());
R.setEnd(Before.getEnd());
}
-static void extendRight(SourceRange &R, const SourceRange &After) {
+static void extendRight(SourceRange &R, SourceRange After) {
if (After.isInvalid())
return;
if (R.getBegin().isInvalid())
///
/// \param[in,out] T The exception type. This will be decayed to a pointer type
/// when the input is an array or a function type.
-bool Sema::CheckSpecifiedExceptionType(QualType &T, const SourceRange &Range) {
+bool Sema::CheckSpecifiedExceptionType(QualType &T, SourceRange Range) {
// C++11 [except.spec]p2:
// A type cv T, "array of T", or "function returning T" denoted
// in an exception-specification is adjusted to type T, "pointer to T", or
ExprResult
Sema::ActOnUnaryExprOrTypeTraitExpr(SourceLocation OpLoc,
UnaryExprOrTypeTrait ExprKind, bool IsType,
- void *TyOrEx, const SourceRange &ArgRange) {
+ void *TyOrEx, SourceRange ArgRange) {
// If error parsing type, ignore.
if (!TyOrEx) return ExprError();
/// \brief Helper to set loop counter variable and its initializer.
bool SetVarAndLB(VarDecl *NewVar, DeclRefExpr *NewVarRefExpr, Expr *NewLB);
/// \brief Helper to set upper bound.
- bool SetUB(Expr *NewUB, bool LessOp, bool StrictOp, const SourceRange &SR,
+ bool SetUB(Expr *NewUB, bool LessOp, bool StrictOp, SourceRange SR,
SourceLocation SL);
/// \brief Helper to set loop increment.
bool SetStep(Expr *NewStep, bool Subtract);
}
bool OpenMPIterationSpaceChecker::SetUB(Expr *NewUB, bool LessOp, bool StrictOp,
- const SourceRange &SR,
- SourceLocation SL) {
+ SourceRange SR, SourceLocation SL) {
// State consistency checking to ensure correct usage.
assert(Var != nullptr && LB != nullptr && UB == nullptr && Step == nullptr &&
!TestIsLessOp && !TestIsStrictOp);
// returns true if 'complain' is set.
bool Sema::ResolveAndFixSingleFunctionTemplateSpecialization(
ExprResult &SrcExpr, bool doFunctionPointerConverion,
- bool complain, const SourceRange& OpRangeForComplaining,
+ bool complain, SourceRange OpRangeForComplaining,
QualType DestTypeForComplaining,
unsigned DiagIDForComplaining) {
assert(SrcExpr.get()->getType() == Context.OverloadTy);
BT.reset(new BuiltinBug(this, desc));
}
bool uninitRefOrPointer(CheckerContext &C, const SVal &V,
- const SourceRange &ArgRange,
+ SourceRange ArgRange,
const Expr *ArgEx, std::unique_ptr<BugType> &BT,
const ParmVarDecl *ParamDecl, const char *BD) const;
};
bool CallAndMessageChecker::uninitRefOrPointer(CheckerContext &C,
const SVal &V,
- const SourceRange &ArgRange,
+ SourceRange ArgRange,
const Expr *ArgEx,
std::unique_ptr<BugType> &BT,
const ParmVarDecl *ParamDecl,
hash.AddPointer(GetCurrentOrPreviousStmt(ErrorNode));
}
- for (SmallVectorImpl<SourceRange>::const_iterator I =
- Ranges.begin(), E = Ranges.end(); I != E; ++I) {
- const SourceRange range = *I;
+ for (SourceRange range : Ranges) {
if (!range.isValid())
continue;
hash.AddInteger(range.getBegin().getRawEncoding());
PathDiagnosticLocation L = exampleReport->getLocation(getSourceManager());
auto piece = llvm::make_unique<PathDiagnosticEventPiece>(
L, exampleReport->getDescription());
- for (const SourceRange &Range : exampleReport->getRanges())
+ for (SourceRange Range : exampleReport->getRanges())
piece->addRange(Range);
D->setEndOfPath(std::move(piece));
}
// special ranges for this report.
auto P = llvm::make_unique<PathDiagnosticEventPiece>(
L, BR.getDescription(), Ranges.begin() == Ranges.end());
- for (const SourceRange &Range : Ranges)
+ for (SourceRange Range : Ranges)
P->addRange(Range);
return std::move(P);
typedef SmallVector<SourceRange, 4> RefNamePieces;
RefNamePieces
buildPieces(unsigned NameFlags, bool IsMemberRefExpr,
- const DeclarationNameInfo &NI, const SourceRange &QLoc,
+ const DeclarationNameInfo &NI, SourceRange QLoc,
const ASTTemplateArgumentListInfo *TemplateArgs = nullptr) {
const bool WantQualifier = NameFlags & CXNameRange_WantQualifier;
const bool WantTemplateArgs = NameFlags & CXNameRange_WantTemplateArgs;