提交 5caebb23 编写于 作者: J Jorge Aparicio

Tell regionck that user unops are by value

上级 b98c3bd4
......@@ -682,10 +682,12 @@ fn visit_expr(rcx: &mut Rcx, expr: &ast::Expr) {
visit::walk_expr(rcx, expr);
}
ast::ExprUnary(_, ref lhs) if has_method_map => {
ast::ExprUnary(op, ref lhs) if has_method_map => {
let implicitly_ref_args = !ast_util::is_by_value_unop(op);
// As above.
constrain_call(rcx, expr, Some(&**lhs),
None::<ast::Expr>.iter(), true);
None::<ast::Expr>.iter(), implicitly_ref_args);
visit::walk_expr(rcx, expr);
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册