forked from OSchip/llvm-project
Don't drop the computed implicit conversions when building a call to
overloaded operator[] or overloaded postfix unary operator (++, --). Thanks to Eli for finding this bug! llvm-svn: 72460
This commit is contained in:
parent
b909bf4937
commit
2517f334b4
|
@ -1609,6 +1609,7 @@ Sema::ActOnPostfixUnaryOp(Scope *S, SourceLocation OpLoc,
|
|||
UsualUnaryConversions(FnExpr);
|
||||
|
||||
Input.release();
|
||||
Args[0] = Arg;
|
||||
return Owned(new (Context) CXXOperatorCallExpr(Context, OverOp, FnExpr,
|
||||
Args, 2, ResultTy,
|
||||
OpLoc));
|
||||
|
@ -1725,6 +1726,8 @@ Sema::ActOnArraySubscriptExpr(Scope *S, ExprArg Base, SourceLocation LLoc,
|
|||
|
||||
Base.release();
|
||||
Idx.release();
|
||||
Args[0] = LHSExp;
|
||||
Args[1] = RHSExp;
|
||||
return Owned(new (Context) CXXOperatorCallExpr(Context, OO_Subscript,
|
||||
FnExpr, Args, 2,
|
||||
ResultTy, LLoc));
|
||||
|
|
Loading…
Reference in New Issue