Skip to content

Commit

Permalink
Don't use static default method
Browse files Browse the repository at this point in the history
 - also removed redundant assignment to is_mutbl
 - updated copyright
  • Loading branch information
j16r committed Jul 9, 2013
1 parent eaaf3f6 commit 56d1987
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
1 change: 0 additions & 1 deletion src/libsyntax/parse/parser.rs
Expand Up @@ -1086,7 +1086,6 @@ impl Parser {
self.expect(&token::COLON);
pat
} else {
is_mutbl = false;
ast_util::ident_to_pat(self.get_id(),
*self.last_span,
special_idents::invalid)
Expand Down
4 changes: 2 additions & 2 deletions src/test/run-pass/traits-default-method-mut.rs
@@ -1,4 +1,4 @@
// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
// Copyright 2013 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
Expand All @@ -11,7 +11,7 @@
#[allow(default_methods)];

trait Foo {
fn foo(mut v: int) { v = 1; }
fn foo(&self, mut v: int) { v = 1; }
}

fn main() {}

5 comments on commit 56d1987

@bors
Copy link
Contributor

@bors bors commented on 56d1987 Jul 10, 2013

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@bors
Copy link
Contributor

@bors bors commented on 56d1987 Jul 10, 2013

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

merging excepttheweasel/rust/mut_default_param_list_issue_7483 = 56d1987 into auto

@bors
Copy link
Contributor

@bors bors commented on 56d1987 Jul 10, 2013

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

excepttheweasel/rust/mut_default_param_list_issue_7483 = 56d1987 merged ok, testing candidate = 8fa0973

@bors
Copy link
Contributor

@bors bors commented on 56d1987 Jul 10, 2013

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fast-forwarding master to auto = 8fa0973

Please sign in to comment.