[cfe-commits] r61763 - /cfe/trunk/lib/Sema/SemaExpr.cpp
Daniel Dunbar
daniel at zuster.org
Mon Jan 5 14:42:10 PST 2009
Author: ddunbar
Date: Mon Jan 5 16:42:10 2009
New Revision: 61763
URL: http://llvm.org/viewvc/llvm-project?rev=61763&view=rev
Log:
Use CheckVectorOperands when % is applied to a vector type.
Modified:
cfe/trunk/lib/Sema/SemaExpr.cpp
Modified: cfe/trunk/lib/Sema/SemaExpr.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaExpr.cpp?rev=61763&r1=61762&r2=61763&view=diff
==============================================================================
--- cfe/trunk/lib/Sema/SemaExpr.cpp (original)
+++ cfe/trunk/lib/Sema/SemaExpr.cpp Mon Jan 5 16:42:10 2009
@@ -2361,9 +2361,7 @@
inline QualType Sema::CheckMultiplyDivideOperands(
Expr *&lex, Expr *&rex, SourceLocation Loc, bool isCompAssign)
{
- QualType lhsType = lex->getType(), rhsType = rex->getType();
-
- if (lhsType->isVectorType() || rhsType->isVectorType())
+ if (lex->getType()->isVectorType() || rex->getType()->isVectorType())
return CheckVectorOperands(Loc, lex, rex);
QualType compType = UsualArithmeticConversions(lex, rex, isCompAssign);
@@ -2376,7 +2374,8 @@
inline QualType Sema::CheckRemainderOperands(
Expr *&lex, Expr *&rex, SourceLocation Loc, bool isCompAssign)
{
- QualType lhsType = lex->getType(), rhsType = rex->getType();
+ if (lex->getType()->isVectorType() || rex->getType()->isVectorType())
+ return CheckVectorOperands(Loc, lex, rex);
QualType compType = UsualArithmeticConversions(lex, rex, isCompAssign);
More information about the cfe-commits
mailing list