From: Robert Wilhelm Date: Fri, 9 Aug 2013 18:02:13 +0000 (+0000) Subject: Omit llvm:: before ArrayRef, as we have using llvm::ArrayRef in include/clang/Basic... X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=834c058cb6b57465e60a4590afdab86c4ea6921d;p=clang Omit llvm:: before ArrayRef, as we have using llvm::ArrayRef in include/clang/Basic/LLVM.h. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@188089 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/Sema/SemaCodeComplete.cpp b/lib/Sema/SemaCodeComplete.cpp index bf575978de..b415993170 100644 --- a/lib/Sema/SemaCodeComplete.cpp +++ b/lib/Sema/SemaCodeComplete.cpp @@ -3846,7 +3846,7 @@ namespace { }; } -static bool anyNullArguments(llvm::ArrayRef Args) { +static bool anyNullArguments(ArrayRef Args) { if (Args.size() && !Args.data()) return true; @@ -3857,8 +3857,7 @@ static bool anyNullArguments(llvm::ArrayRef Args) { return false; } -void Sema::CodeCompleteCall(Scope *S, Expr *FnIn, - llvm::ArrayRef Args) { +void Sema::CodeCompleteCall(Scope *S, Expr *FnIn, ArrayRef Args) { if (!CodeCompleter) return; diff --git a/lib/Sema/SemaDecl.cpp b/lib/Sema/SemaDecl.cpp index 330d0cbb58..077fc086d7 100644 --- a/lib/Sema/SemaDecl.cpp +++ b/lib/Sema/SemaDecl.cpp @@ -9298,8 +9298,10 @@ Decl *Sema::ActOnStartOfFunctionDef(Scope *FnBodyScope, Decl *D) { // If we had any tags defined in the function prototype, // introduce them into the function scope. if (FnBodyScope) { - for (llvm::ArrayRef::iterator I = FD->getDeclsInPrototypeScope().begin(), - E = FD->getDeclsInPrototypeScope().end(); I != E; ++I) { + for (ArrayRef::iterator + I = FD->getDeclsInPrototypeScope().begin(), + E = FD->getDeclsInPrototypeScope().end(); + I != E; ++I) { NamedDecl *D = *I; // Some of these decls (like enums) may have been pinned to the translation unit @@ -11497,11 +11499,9 @@ void Sema::ActOnLastBitfield(SourceLocation DeclLoc, AllIvarDecls.push_back(Ivar); } -void Sema::ActOnFields(Scope* S, - SourceLocation RecLoc, Decl *EnclosingDecl, - llvm::ArrayRef Fields, - SourceLocation LBrac, SourceLocation RBrac, - AttributeList *Attr) { +void Sema::ActOnFields(Scope *S, SourceLocation RecLoc, Decl *EnclosingDecl, + ArrayRef Fields, SourceLocation LBrac, + SourceLocation RBrac, AttributeList *Attr) { assert(EnclosingDecl && "missing record or interface decl"); // If this is an Objective-C @implementation or category and we have @@ -11539,7 +11539,7 @@ void Sema::ActOnFields(Scope* S, SmallVector RecFields; bool ARCErrReported = false; - for (llvm::ArrayRef::iterator i = Fields.begin(), end = Fields.end(); + for (ArrayRef::iterator i = Fields.begin(), end = Fields.end(); i != end; ++i) { FieldDecl *FD = cast(*i); diff --git a/lib/Sema/SemaExpr.cpp b/lib/Sema/SemaExpr.cpp index 8515cb2f53..268a2fd343 100644 --- a/lib/Sema/SemaExpr.cpp +++ b/lib/Sema/SemaExpr.cpp @@ -1655,7 +1655,7 @@ Sema::DecomposeUnqualifiedId(const UnqualifiedId &Id, bool Sema::DiagnoseEmptyLookup(Scope *S, CXXScopeSpec &SS, LookupResult &R, CorrectionCandidateCallback &CCC, TemplateArgumentListInfo *ExplicitTemplateArgs, - llvm::ArrayRef Args) { + ArrayRef Args) { DeclarationName Name = R.getLookupName(); unsigned diagnostic = diag::err_undeclared_var_use; diff --git a/lib/Sema/SemaLookup.cpp b/lib/Sema/SemaLookup.cpp index fc8b6b9c09..e95ffce054 100644 --- a/lib/Sema/SemaLookup.cpp +++ b/lib/Sema/SemaLookup.cpp @@ -2215,11 +2215,10 @@ addAssociatedClassesAndNamespaces(AssociatedLookup &Result, QualType Ty) { /// This routine computes the sets of associated classes and associated /// namespaces searched by argument-dependent lookup /// (C++ [basic.lookup.argdep]) for a given set of arguments. -void -Sema::FindAssociatedClassesAndNamespaces(SourceLocation InstantiationLoc, - llvm::ArrayRef Args, - AssociatedNamespaceSet &AssociatedNamespaces, - AssociatedClassSet &AssociatedClasses) { +void Sema::FindAssociatedClassesAndNamespaces( + SourceLocation InstantiationLoc, ArrayRef Args, + AssociatedNamespaceSet &AssociatedNamespaces, + AssociatedClassSet &AssociatedClasses) { AssociatedNamespaces.clear(); AssociatedClasses.clear(); @@ -2794,8 +2793,7 @@ void ADLResult::insert(NamedDecl *New) { } void Sema::ArgumentDependentLookup(DeclarationName Name, bool Operator, - SourceLocation Loc, - llvm::ArrayRef Args, + SourceLocation Loc, ArrayRef Args, ADLResult &Result) { // Find all of the associated namespaces and classes based on the // arguments we have. @@ -3626,8 +3624,8 @@ void NamespaceSpecifierSet::AddNamespace(NamespaceDecl *ND) { SmallVector NewNameSpecifierIdentifiers; getNestedNameSpecifierIdentifiers(NNS, NewNameSpecifierIdentifiers); NumSpecifiers = llvm::ComputeEditDistance( - llvm::ArrayRef(CurNameSpecifierIdentifiers), - llvm::ArrayRef(NewNameSpecifierIdentifiers)); + ArrayRef(CurNameSpecifierIdentifiers), + ArrayRef(NewNameSpecifierIdentifiers)); } isSorted = false; diff --git a/lib/Sema/SemaOverload.cpp b/lib/Sema/SemaOverload.cpp index 1a9b82962b..ec7c3a4609 100644 --- a/lib/Sema/SemaOverload.cpp +++ b/lib/Sema/SemaOverload.cpp @@ -7658,11 +7658,10 @@ public: /// on the operator @p Op and the arguments given. For example, if the /// operator is a binary '+', this routine might add "int /// operator+(int, int)" to cover integer addition. -void -Sema::AddBuiltinOperatorCandidates(OverloadedOperatorKind Op, - SourceLocation OpLoc, - llvm::ArrayRef Args, - OverloadCandidateSet& CandidateSet) { +void Sema::AddBuiltinOperatorCandidates(OverloadedOperatorKind Op, + SourceLocation OpLoc, + ArrayRef Args, + OverloadCandidateSet &CandidateSet) { // Find all of the types that the arguments can convert to, but only // if the operator we're looking at has built-in operator candidates // that make use of these types. Also record whether we encounter non-record diff --git a/lib/Sema/SemaTemplateDeduction.cpp b/lib/Sema/SemaTemplateDeduction.cpp index e5a1d7a3d4..65d21fabf7 100644 --- a/lib/Sema/SemaTemplateDeduction.cpp +++ b/lib/Sema/SemaTemplateDeduction.cpp @@ -3257,12 +3257,10 @@ DeduceTemplateArgumentByListElement(Sema &S, /// about template argument deduction. /// /// \returns the result of template argument deduction. -Sema::TemplateDeductionResult -Sema::DeduceTemplateArguments(FunctionTemplateDecl *FunctionTemplate, - TemplateArgumentListInfo *ExplicitTemplateArgs, - llvm::ArrayRef Args, - FunctionDecl *&Specialization, - TemplateDeductionInfo &Info) { +Sema::TemplateDeductionResult Sema::DeduceTemplateArguments( + FunctionTemplateDecl *FunctionTemplate, + TemplateArgumentListInfo *ExplicitTemplateArgs, ArrayRef Args, + FunctionDecl *&Specialization, TemplateDeductionInfo &Info) { if (FunctionTemplate->isInvalidDecl()) return TDK_Invalid; diff --git a/lib/Sema/SemaTemplateInstantiate.cpp b/lib/Sema/SemaTemplateInstantiate.cpp index 25eb72ce1c..83c4c115fa 100644 --- a/lib/Sema/SemaTemplateInstantiate.cpp +++ b/lib/Sema/SemaTemplateInstantiate.cpp @@ -759,9 +759,8 @@ namespace { bool TryExpandParameterPacks(SourceLocation EllipsisLoc, SourceRange PatternRange, - llvm::ArrayRef Unexpanded, - bool &ShouldExpand, - bool &RetainExpansion, + ArrayRef Unexpanded, + bool &ShouldExpand, bool &RetainExpansion, Optional &NumExpansions) { return getSema().CheckParameterPacksForExpansion(EllipsisLoc, PatternRange, Unexpanded,