Upgrade to rustc 1.3.0-dev (87055a68c 2015-07-30)

This commit is contained in:
Simon Sapin 2015-07-30 16:58:26 +02:00
parent a3c0366bd6
commit 930921b0c3
7 changed files with 170 additions and 77 deletions

View file

@ -22,7 +22,7 @@ impl LintPass for StrToStringPass {
fn check_expr(&mut self, cx: &Context, expr: &ast::Expr) {
match expr.node {
ast::ExprMethodCall(ref method, _, ref args)
if method.node.as_str() == "to_string"
if method.node.name.as_str() == "to_string"
&& is_str(cx, &*args[0]) => {
cx.span_lint(STR_TO_STRING, expr.span,
"str.to_owned() is more efficient than str.to_string(), please use it instead");