diff options
Diffstat (limited to 'clang/lib')
| -rw-r--r-- | clang/lib/Sema/SemaOverload.cpp | 8 | 
1 files changed, 5 insertions, 3 deletions
| diff --git a/clang/lib/Sema/SemaOverload.cpp b/clang/lib/Sema/SemaOverload.cpp index bae2783bea5..7905f5e6228 100644 --- a/clang/lib/Sema/SemaOverload.cpp +++ b/clang/lib/Sema/SemaOverload.cpp @@ -7796,10 +7796,12 @@ public:      if (!HasArithmeticOrEnumeralCandidateType)        return; -    for (unsigned Arith = (Op == OO_PlusPlus? 0 : 1); -         Arith < NumArithmeticTypes; ++Arith) { +    for (unsigned Arith = 0; Arith < NumArithmeticTypes; ++Arith) { +      const auto TypeOfT = ArithmeticTypes[Arith]; +      if (Op == OO_MinusMinus && TypeOfT == S.Context.BoolTy) +        continue;        addPlusPlusMinusMinusStyleOverloads( -        ArithmeticTypes[Arith], +        TypeOfT,          VisibleTypeConversionsQuals.hasVolatile(),          VisibleTypeConversionsQuals.hasRestrict());      } | 

