From d695d6bb7323672e29dbb1556a3dafde3d3b2732 Mon Sep 17 00:00:00 2001 From: Sebastian Redl Date: Sun, 5 Jun 2011 13:59:05 +0000 Subject: [PATCH] Remove more references to FailedSequence. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@132666 91177308-0d34-0410-b5e6-96231b3b80d8 --- include/clang/Sema/Initialization.h | 2 +- lib/Sema/SemaInit.cpp | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/include/clang/Sema/Initialization.h b/include/clang/Sema/Initialization.h index 3aee66c89f..a7b0f51131 100644 --- a/include/clang/Sema/Initialization.h +++ b/include/clang/Sema/Initialization.h @@ -825,7 +825,7 @@ public: /// \brief Determine why initialization failed. FailureKind getFailureKind() const { - assert(getKind() == FailedSequence && "Not an initialization failure!"); + assert(Failed() && "Not an initialization failure!"); return Failure; } diff --git a/lib/Sema/SemaInit.cpp b/lib/Sema/SemaInit.cpp index d9ceb352b7..09816fda3b 100644 --- a/lib/Sema/SemaInit.cpp +++ b/lib/Sema/SemaInit.cpp @@ -2137,7 +2137,7 @@ bool InitializationSequence::isDirectReferenceBinding() const { } bool InitializationSequence::isAmbiguous() const { - if (getKind() != FailedSequence) + if (!Failed()) return false; switch (getFailureKind()) { @@ -3650,7 +3650,7 @@ InitializationSequence::Perform(Sema &S, const InitializationKind &Kind, MultiExprArg Args, QualType *ResultType) { - if (SequenceKind == FailedSequence) { + if (Failed()) { unsigned NumArgs = Args.size(); Diagnose(S, Entity, Kind, (Expr **)Args.release(), NumArgs); return ExprError(); @@ -4216,7 +4216,7 @@ bool InitializationSequence::Diagnose(Sema &S, const InitializedEntity &Entity, const InitializationKind &Kind, Expr **Args, unsigned NumArgs) { - if (SequenceKind != FailedSequence) + if (!Failed()) return false; QualType DestType = Entity.getType(); -- 2.40.0