]> granicus.if.org Git - clang/commitdiff
Minor API change. No change in functionality.
authorFariborz Jahanian <fjahanian@apple.com>
Mon, 28 Sep 2009 22:03:07 +0000 (22:03 +0000)
committerFariborz Jahanian <fjahanian@apple.com>
Mon, 28 Sep 2009 22:03:07 +0000 (22:03 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83022 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Sema/SemaDeclCXX.cpp
lib/Sema/SemaOverload.cpp

index 1c5415900b9f4b9947b57d733a45225495063a39..f2dfe3615f5494e21b2c9b4b7105ce7090bc4bf3 100644 (file)
@@ -3694,7 +3694,7 @@ Sema::CheckReferenceInit(Expr *&Init, QualType DeclType,
     if (badConversion) {
       if ((Conversions.ConversionKind  == 
             ImplicitConversionSequence::BadConversion)
-          && Conversions.ConversionFunctionSet.size() > 0) {
+          && !Conversions.ConversionFunctionSet.empty()) {
         Diag(DeclLoc, 
              diag::err_lvalue_to_rvalue_ambig_ref) << Init->getSourceRange();
         for (int j = Conversions.ConversionFunctionSet.size()-1; 
index 885f59c5aacf06a83460f8b3ba9b1c1bfa32c151..42f3511e57980924f25c6018b5436eec11eea41d 100644 (file)
@@ -2241,7 +2241,7 @@ Sema::AddOverloadCandidate(FunctionDecl *Function,
       // ranking implicit conversion sequences as described in 13.3.3.2, the ambiguous 
       // conversion sequence is treated as a user-defined sequence that is 
       // indistinguishable from any other user-defined conversion sequence
-        if (Candidate.Conversions[ArgIdx].ConversionFunctionSet.size() > 0)
+        if (!Candidate.Conversions[ArgIdx].ConversionFunctionSet.empty())
           Candidate.Conversions[ArgIdx].ConversionKind =
             ImplicitConversionSequence::UserDefinedConversion;
         else {