Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unclear example on mutability #33716

Closed
mark-summerfield opened this issue May 18, 2016 · 1 comment
Closed

Unclear example on mutability #33716

mark-summerfield opened this issue May 18, 2016 · 1 comment

Comments

@mark-summerfield
Copy link
Contributor

mark-summerfield commented May 18, 2016

This is copied from rust-lang/book#102 (comment) as requested:


In https://doc.rust-lang.org/book/mutability.html at the end of the Mutability section it has these examples:

let (mut x, y) = (5, 6);

fn foo(mut x: i32) {

I think there should be some following text, e.g.

Note that here, x is mutable, but y is not.

In the link I was given: http://rust-lang.github.io/book/variable-bindings.html#Mutable there is an updated explanation which explains this clearly.

@mark-summerfield
Copy link
Contributor Author

I tried fixing this one: #33720

Manishearth added a commit to Manishearth/rust that referenced this issue May 19, 2016
…abnik

Clarified that `let(mut x, y) =` only makes x mutable, not y

Closes rust-lang#33716
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants