diff options
| author | Douglas Gregor <dgregor@apple.com> | 2008-11-13 20:12:29 +0000 |
|---|---|---|
| committer | Douglas Gregor <dgregor@apple.com> | 2008-11-13 20:12:29 +0000 |
| commit | 58e008d2a61a73aaa2af07958b15c6f451b92eac (patch) | |
| tree | ff0b4a4394e483dbf20d7465359c48f83053d8d4 /clang/lib/Sema/SemaExpr.cpp | |
| parent | f8cfd1647ec0be5fe9310c838eabdc1af8313d64 (diff) | |
| download | bcm5719-llvm-58e008d2a61a73aaa2af07958b15c6f451b92eac.tar.gz bcm5719-llvm-58e008d2a61a73aaa2af07958b15c6f451b92eac.zip | |
Some cleanup for the implementation of built-in operator
candidates. Thanks to Chris for the review!
llvm-svn: 59260
Diffstat (limited to 'clang/lib/Sema/SemaExpr.cpp')
| -rw-r--r-- | clang/lib/Sema/SemaExpr.cpp | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/clang/lib/Sema/SemaExpr.cpp b/clang/lib/Sema/SemaExpr.cpp index 21bf990fba1..c9f311a204a 100644 --- a/clang/lib/Sema/SemaExpr.cpp +++ b/clang/lib/Sema/SemaExpr.cpp @@ -130,15 +130,10 @@ QualType Sema::UsualArithmeticConversionsType(QualType lhs, QualType rhs) { // lhs == rhs check. Also, for conversion purposes, we ignore any // qualifiers. For example, "const float" and "float" are // equivalent. - if (lhs->isPromotableIntegerType()) - lhs = Context.IntTy; - else - lhs = Context.getCanonicalType(lhs).getUnqualifiedType(); - - if (rhs->isPromotableIntegerType()) - rhs = Context.IntTy; - else - rhs = Context.getCanonicalType(rhs).getUnqualifiedType(); + if (lhs->isPromotableIntegerType()) lhs = Context.IntTy; + else lhs = lhs.getUnqualifiedType(); + if (rhs->isPromotableIntegerType()) rhs = Context.IntTy; + else rhs = rhs.getUnqualifiedType(); // If both types are identical, no conversion is needed. if (lhs == rhs) |

