Skip to content

Commit

Permalink
Remove innapropriate string mutability section.
Browse files Browse the repository at this point in the history
Fixes #14948
  • Loading branch information
steveklabnik committed Aug 18, 2014
1 parent 776c17f commit 2f80444
Showing 1 changed file with 0 additions and 11 deletions.
11 changes: 0 additions & 11 deletions src/libcollections/str.rs
Expand Up @@ -44,17 +44,6 @@ the string is valid for the `'static` lifetime, otherwise known as the
lifetime of the entire program. As can be inferred from the type, these static
strings are not mutable.
# Mutability
Many languages have immutable strings by default, and Rust has a particular
flavor on this idea. As with the rest of Rust types, strings are immutable by
default. If a string is declared as `mut`, however, it may be mutated. This
works the same way as the rest of Rust's type system in the sense that if
there's a mutable reference to a string, there may only be one mutable reference
to that string. With these guarantees, strings can easily transition between
being mutable/immutable with the same benefits of having mutable strings in
other languages.
# Representation
Rust's string type, `str`, is a sequence of unicode scalar values encoded as a
Expand Down

5 comments on commit 2f80444

@bors
Copy link
Contributor

@bors bors commented on 2f80444 Aug 19, 2014

Choose a reason for hiding this comment

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

saw approval from pcwalton
at steveklabnik@2f80444

@bors
Copy link
Contributor

@bors bors commented on 2f80444 Aug 19, 2014

Choose a reason for hiding this comment

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

merging steveklabnik/rust/gh1498 = 2f80444 into auto

@bors
Copy link
Contributor

@bors bors commented on 2f80444 Aug 19, 2014

Choose a reason for hiding this comment

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

steveklabnik/rust/gh1498 = 2f80444 merged ok, testing candidate = ef5ad07

@bors
Copy link
Contributor

@bors bors commented on 2f80444 Aug 19, 2014

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 = ef5ad07

Please sign in to comment.