about summary refs log tree commit diff
path: root/src/doc/trpl/ownership.md
AgeCommit message (Collapse)AuthorLines
2015-11-19src/doc/trpl -> src/doc/bookSteve Klabnik-238/+0
The book was located under 'src/doc/trpl' because originally, it was going to be hosted under that URL. Late in the game, before 1.0, we decided that /book was a better one, so we changed the output, but not the input. This causes confusion for no good reason. So we'll change the source directory to look like the output directory, like for every other thing in src/doc.
2015-11-17Fix grammarJean Maillard-1/+1
Change conditional perfect to past perfect.
2015-10-19Clean whitespaceCarlos Liam-3/+3
Remove leading newlines; replace lines containing only whitespace with empty lines; replace multiple trailing newlines with a single newline; remove trailing whitespace in lines
2015-10-06Replace multiple trailing newlines with a single trailing newlineCarlos Liam-10/+0
Sorry I didn’t get this in the last PR (#28864), I hadn’t thought of it.
2015-07-13minor grammatical updateFrank McSherry-2/+2
Grammatical update (and passive -> active, but I'm not sure if "Rust" is often used as a subject in the book; feel free to revert that part for style, but keep the subject-verb agreement)
2015-06-08Updated with requested changesMathieu David-4/+1
2015-05-30Proposal to explain the copy trait more clearly Mathieu David-0/+43
As mentioned in #25893 the copy trait is not very well explained for beginners. There is no clear mention that all primitive types implement the copy trait and there are not a lot of examples. With this change I try to make it more visible and understandable for new users. I myself have struggled with this, see [my question on stackoverflow](http://stackoverflow.com/questions/30540419/why-are-booleans-copyable-even-though-the-documentation-doesnt-indicate-that). And I want to make it more transparent for others. I filed issue #25893 but I thought that I could give it a shot myself to relieve some of the work from the devs :) If it is not well written or there are some changes to be made before it can be merged, let me know. Cheers, Mathieu
2015-05-13Merge branch 'doc-fixes' of https://github.com/wheals/rust into rollupSteve Klabnik-1/+1
2015-05-12book: typo fixes, wording improvements.Shmuale Mark-1/+1
The text in iterators.md wasn't wrong, but it read awkwardly to my ear.
2015-05-11Fixed one textual mistake and one casing error.Michał Czardybon-14/+14
Corrected "Ownership": - [`Variable bindings`] link was not processed properly. - Changed the paragraph about move semantics with two vectors, because it was confusing. - Removed "So it may not be as inefficient as it initially seems", because there is nothing that seems inefficient in copying pointers only. - Other text corrections. Fixed copied-and-pasted text mistakes. Revised the paragraph about moving a vector (taking into account suggestions by echochamber). Fixed markdown. Fixes requested by steveklabnik. Brought back a sentence about supposed inefficiency.
2015-05-10Rollup merge of #25188 - tincann:patch-1, r=steveklabnikSteve Klabnik-1/+1
2015-05-08v2 gets a copy of the pointer, not a copy of the dataSimon Kern-1/+1
2015-05-08two minor fixesSimon Kern-1/+2
2015-05-07Another typoTincan-1/+1
2015-05-07Typo in ownership.mdTincan-1/+1
2015-05-05TRPL: ownership, borrowing, and lifetimesSteve Klabnik-459/+111
Also, as @huonw guessed, move semantics really _does_ make more sense as a sub-chapter of ownership.
2015-03-31Fix spellingSteve Klabnik-1/+1
2015-03-31Rollup merge of #23558 - steveklabnik:explain_elision, r=gankroManish Goregaokar-4/+9
2015-03-30Explain why 'elision'Steve Klabnik-4/+9
2015-03-23Improve the wording of the example section description on the ownership pageLiam Monahan-2/+2
to make it more clear.
2015-03-23Fix a typo in the Rust Book ownership page.Liam Monahan-2/+2
2015-02-17Rollup merge of #22027 - iblech:patch-1, r=steveklabnikManish Goregaokar-1/+1
The first commit adds a short note which I believe will reduce worries in people who work with closures very often and read the Rust book for their first time. The second commit consists solely of tiny typo fixes. In some cases, I changed "logical" quotations like She said, "I like programming". to She said, "I like programming." because the latter seems to be the prevalent style in the book.
2015-02-12Updated documentation to use range notation syntax.Nick Sarten-2/+2
Replaced outdated use of the `range(start, end)` function where approriate with `start..end`, and tweaked the examples to compile and run with the latest rust. I also fixed two periphery compile issues in reference.md which were occluding whether there were any new errors created by these changes, so I fixed them.
2015-02-07Fix several tiny typosIngo Blechschmidt-1/+1
2015-02-04Fix for misspelled comments.Joseph Crail-1/+1
The spelling corrections were made in both documentation comments and regular comments.
2015-01-25Add example for Lifetime Elision with two inputsTyler Thrailkill-0/+1
Lifetime elision with two input references is not clear. Closes #21284
2015-01-22Reference correct fn during lifetime ellisionSean T Allen-8/+8
2015-01-18fix an error about the static lifetimeJay True-1/+1
The reference should be `x`, not `FOO` itself.
2015-01-17doc: Remove extra whitespace in the middle of lines to provide alignmentNick Howell-13/+13
"Idiomatic code should not use extra whitespace in the middle of a line to provide alignment." http://aturon.github.io/style/whitespace.html I realize the linked page still needs an RFC, but the docs should be written in accordance with the guidelines nevertheless.
2015-01-17Fix up titles of TRPL chaptersSteve Klabnik-1/+1
2015-01-17Intpocalypse, book edition.Steve Klabnik-2/+2
Fix all usage of int/uint/i/u in the book.
2015-01-16Merge pull request #21214 from sleepynate/spacing-in-bookbors-3/+3
Fix commented graphs in src/doc/trpl/ownership.md Reviewed-by: huonw
2015-01-15Fix commented graphs in src/doc/trpl/ownership.mdnathan dotz-3/+3
2015-01-15rollup merge of #21029: steveklabnik/gh19924Alex Crichton-4/+20
Fixes #19924
2015-01-12Improve the ownership guide a tadSteve Klabnik-4/+20
Fixes #19924
2015-01-12Ease parsing of an English sentenceLauri Lehmijoki-1/+1
2015-01-11Fixing integer usage in ownership docStrahinja Val Markovic-39/+39
`int` doesn't exist anymore. Usage of its equivalent `isize` is discouraged since its size is platform-dependent. `i32` is used instead in the examples. Also, integer suffixes aren't needed in the examples anymore so we can just write `5` instead of `5i`.
2015-01-10Merge pull request #20818 from rgs1/fix-guidebors-1/+1
Remove extra dangling period Reviewed-by: alexcrichton
2015-01-09Remove extra dangling periodRaul Gutierrez S-1/+1
Signed-off-by: Raul Gutierrez S <rgs@itevenworks.net>
2015-01-08Standardize punctuation & formatting of TRPLKevin Yap-22/+22
This commit is an attempt to standardize the use of punctuation and formatting in "The Rust Programming Language" as discussed in #19823. - Convert bold text to italicized textcwhen referring to terminology. - Convert single-quoted text to italicized or double-quoted text, depending on context. - Use double quotes only in the case of scare quotes or quotations.
2015-01-08Fix dead links in the guide and reorganizeAlex Crichton-0/+533