From ad900dae925b11c7999fc5dbb2dc7eba3dd274b4 Mon Sep 17 00:00:00 2001 From: Brian Anderson Date: Tue, 3 Nov 2015 12:46:06 -0800 Subject: [PATCH 01/11] mk: Move some old docs to the deprecated list --- mk/docs.mk | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mk/docs.mk b/mk/docs.mk index 644fbde323c9..b0872c88c141 100644 --- a/mk/docs.mk +++ b/mk/docs.mk @@ -22,14 +22,14 @@ # L10N_LANGS are the languages for which the docs have been # translated. ###################################################################### -DOCS := index intro tutorial \ +DOCS := index \ complement-lang-faq complement-design-faq complement-project-faq \ rustdoc reference grammar # Legacy guides, preserved for a while to reduce the number of 404s DOCS += guide-crates guide-error-handling guide-ffi guide-macros guide \ guide-ownership guide-plugins guide-pointers guide-strings guide-tasks \ - guide-testing + guide-testing tutorial intro RUSTDOC_DEPS_reference := doc/full-toc.inc From be9afcca8928a5fc484efe06f93d7256c95c00b6 Mon Sep 17 00:00:00 2001 From: Brian Anderson Date: Tue, 3 Nov 2015 12:47:57 -0800 Subject: [PATCH 02/11] doc: Remove irrelevant info about rbe --- src/doc/index.md | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/doc/index.md b/src/doc/index.md index 992b6eef5e80..70d3e9781aac 100644 --- a/src/doc/index.md +++ b/src/doc/index.md @@ -14,9 +14,8 @@ concepts. Upon completing the book, you'll be an intermediate Rust developer, and will have a good grasp of the fundamental ideas behind Rust. -[Rust By Example][rbe] was originally a community resource, but was then -donated to the Rust project. As the name implies, it teaches you Rust through a -series of small examples. +[Rust By Example][rbe] teaches you Rust through a series of small +examples. [rbe]: http://rustbyexample.com/ From f553292cf69afcaf9975bb0226e4167caa4eebd4 Mon Sep 17 00:00:00 2001 From: Brian Anderson Date: Tue, 3 Nov 2015 12:48:47 -0800 Subject: [PATCH 03/11] doc: Remove non-documentation tool links --- src/doc/index.md | 4 ---- 1 file changed, 4 deletions(-) diff --git a/src/doc/index.md b/src/doc/index.md index 70d3e9781aac..e60468e483f1 100644 --- a/src/doc/index.md +++ b/src/doc/index.md @@ -39,10 +39,6 @@ beyond the standard one, and its website contains lots of good documentation. [`rustdoc`](book/documentation.html) is the Rust's documentation generator, a tool converting annotated source code into HTML docs. -A bunch of non-official tools are available, such as [Racer](https://github.com/phildawes/racer) -(code completion engine), or [rustfmt](https://github.com/nrc/rustfmt) (source code formatter), -or text editor plugins. - # Community & Getting Help If you need help with something, or just want to talk about Rust with others, From 53fad90608491474cfde1604ccb54dbde68cea40 Mon Sep 17 00:00:00 2001 From: Brian Anderson Date: Tue, 3 Nov 2015 12:49:21 -0800 Subject: [PATCH 04/11] doc: Remove community info --- src/doc/index.md | 31 ------------------------------- 1 file changed, 31 deletions(-) diff --git a/src/doc/index.md b/src/doc/index.md index e60468e483f1..d0dde957a751 100644 --- a/src/doc/index.md +++ b/src/doc/index.md @@ -39,37 +39,6 @@ beyond the standard one, and its website contains lots of good documentation. [`rustdoc`](book/documentation.html) is the Rust's documentation generator, a tool converting annotated source code into HTML docs. -# Community & Getting Help - -If you need help with something, or just want to talk about Rust with others, -there are a few places you can do that: - -The Rust IRC channels on [irc.mozilla.org](irc://irc.mozilla.org/) are the -fastest way to get help. -[`#rust`](http://chat.mibbit.com/?server=irc.mozilla.org&channel=%23rust) is -the general discussion channel, and you'll find people willing to help you with -any questions you may have. - -There are also three specialty channels: -[`#rust-gamedev`](http://chat.mibbit.com/?server=irc.mozilla.org&channel=%23rust-gamedev) -and -[`#rust-osdev`](http://chat.mibbit.com/?server=irc.mozilla.org&channel=%23rust-osdev) -are for game development and operating system development, respectively. -There's also -[`#rust-internals`](http://chat.mibbit.com/?server=irc.mozilla.org&channel=%23rust-internals), which is for discussion of the development of Rust itself. - -You can also get help on [Stack -Overflow](https://stackoverflow.com/questions/tagged/rust). Searching for your -problem might reveal someone who has asked it before! - -There is an active [subreddit](https://reddit.com/r/rust) with lots of -discussion and news about Rust. - -There is also a [user forum](https://users.rust-lang.org), for all -user-oriented discussion, and a [developer -forum](https://internals.rust-lang.org/), where the development of Rust -itself is discussed. - # FAQs There are questions that are asked quite often, so we've made FAQs for them: From 6ca0fa9af2ec96439ef2cbb4047f78c7adb2fe5e Mon Sep 17 00:00:00 2001 From: Brian Anderson Date: Tue, 3 Nov 2015 12:52:18 -0800 Subject: [PATCH 05/11] doc: Add the Rustonomicon --- src/doc/index.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/doc/index.md b/src/doc/index.md index d0dde957a751..79f3e0aad4d0 100644 --- a/src/doc/index.md +++ b/src/doc/index.md @@ -31,6 +31,13 @@ library](std/index.html). There's a list of crates on the left with more specific sections, or you can use the search bar at the top to search for something if you know its name. +# The Rustonomicon + +[The Rustonomicon] is an entire book dedicated dedicated to explaining +how to write `unsafe` Rust code. It is for advanced Rust programmers. + +[The Rustonomicon]: nomicon/index.html + # Tools [Cargo](https://crates.io) is the Rust's package manager providing access to libraries From 48c170df36ed5e7ee47ca011b0169a0a7acd199c Mon Sep 17 00:00:00 2001 From: Brian Anderson Date: Tue, 3 Nov 2015 12:55:03 -0800 Subject: [PATCH 06/11] doc: Link to cargo docs, not just crates.io --- src/doc/index.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/doc/index.md b/src/doc/index.md index 79f3e0aad4d0..89fa45a3ad6f 100644 --- a/src/doc/index.md +++ b/src/doc/index.md @@ -40,7 +40,7 @@ how to write `unsafe` Rust code. It is for advanced Rust programmers. # Tools -[Cargo](https://crates.io) is the Rust's package manager providing access to libraries +[Cargo](http://doc.crates.io/index.html) is the Rust's package manager providing access to libraries beyond the standard one, and its website contains lots of good documentation. [`rustdoc`](book/documentation.html) is the Rust's documentation generator, a tool converting From 0b510641d3a4c4db54fed5b49fe923b1482c8ab4 Mon Sep 17 00:00:00 2001 From: Barosl Lee Date: Thu, 12 Nov 2015 18:05:45 +0900 Subject: [PATCH 07/11] Improve the detailed error message for E0432 The command-line error message for E0432 does mention the possibility of missing the `extern crate` declaration, but the detailed error message for it doesn't. Fixes #29517. --- src/librustc_resolve/diagnostics.rs | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/librustc_resolve/diagnostics.rs b/src/librustc_resolve/diagnostics.rs index 4147f2bea485..6ce70ecdd552 100644 --- a/src/librustc_resolve/diagnostics.rs +++ b/src/librustc_resolve/diagnostics.rs @@ -806,6 +806,15 @@ mod something { pub struct Foo; } ``` + +Or, if you tried to use a module from an external crate, you may have missed +the `extern crate` declaration: + +``` +extern crate homura; // Required to use the `homura` crate + +use homura::Madoka; +``` "##, E0433: r##" From d84d92bbdd049aafd7962d2133bd91b2afcfdad5 Mon Sep 17 00:00:00 2001 From: arcnmx Date: Sat, 14 Nov 2015 23:11:20 -0500 Subject: [PATCH 08/11] AUTHORS and .mailmap cleanup --- .mailmap | 124 +++++++++++++++++++++++++++++++++-------- AUTHORS.txt | 19 +------ src/etc/add-authors.sh | 4 +- 3 files changed, 104 insertions(+), 43 deletions(-) mode change 100644 => 100755 src/etc/add-authors.sh diff --git a/.mailmap b/.mailmap index 8eaf8f16e4b6..317a92b8f43c 100644 --- a/.mailmap +++ b/.mailmap @@ -7,142 +7,218 @@ Aaron Todd Abhishek Chanda Abhishek Chanda +Adolfo Ochagavía +Adrien Tétar Ahmed Charles -Aydin Kim aydin.kim Alex Burka Alex Burka Alex Lyon Alex Newman Alex HotShot Newman Alex Rønne Petersen +Alexander Light Alexander Light +Alexis Beingessner Alfie John Alfie John +Anatoly Ikorsky +Andre Bogus Andreas Gal Andrew Kuchev <0coming.soon@gmail.com> Andrew <0coming.soon@gmail.com> Andrew Poelstra Anton Löfgren -Ariel Ben-Yehuda arielb1 +Areski Belaid areski Ariel Ben-Yehuda Ariel Ben-Yehuda +Ariel Ben-Yehuda arielb1 Austin Seipp +Aydin Kim aydin.kim +Barosl Lee Barosl LEE Ben Alpert -Ben Sago Ben S Ben S +Ben Sago Ben S +Ben Sago Ben S Benjamin Jackman +Bheesham Persaud Bheesham Persaud Björn Steinbrink blake2-ppc Boris Egorov +Brandon Sanderson Brandon Sanderson +Brett Cannon Brett Cannon Brian Anderson Brian Dawn +Brian Leibig Brian Leibig Carl-Anton Ingmarsson Carol (Nichols || Goulding) Carol Nichols +Carol (Nichols || Goulding) Carol Nichols Carol Willing Chris C Cerami Chris C Cerami Chris Pressey +Chris Thorn Chris Thorn Clark Gaebel +Clinton Ryan Corey Farwell Corey Farwell Corey Richardson Elaine "See More" Nemo +Damien Schoof +Daniel Ramos David Klein David Manescu -Damien Schoof +David Ross Derek Chiang Derek Chiang (Enchi Jiang) Diggory Hardy Diggory Hardy Dylan Braithwaite -Eduardo Bautista +Dzmitry Malyshau Eduardo Bautista <=> +Eduardo Bautista Elliott Slaughter Elly Fong-Jones Emily Dunham edunham -Eric Holk Eric Holk +Eric Holk Eric Holmes Eric Reed Erick Tryzelaar Evgeny Sologubov Falco Hirschenberger Felix S. Klock II Felix S Klock II +Flaper Fesp +Florian Wilkens Florian Wilkens Gareth Daniel Smith gareth +Gareth Daniel Smith Gareth Smith Georges Dubus -Graham Fawcett +Graham Fawcett Graham Fawcett Graydon Hoare Graydon Hoare -Heather +Guillaume Gomez Heather +Heather +Herman J. Radtke III Herman J. Radtke III Ilyong Cho +Ivan Ivaschenko J. J. Weber Jakub Bukaj Jakub Bukaj +Jakub Bukaj Jakub Bukaj James Deng James Miller -Jason Orendorff +James Perry +Jason Fager Jason Orendorff +Jason Orendorff +Jason Toffaletti Jason Toffaletti +Jauhien Piatlicki Jauhien Piatlicki +Jay True Jeremy Letang -Jihyun Yu jihyun -Jihyun Yu -Johann Hofmann Johann Johann Hofmann +Jihyun Yu +Jihyun Yu jihyun +Jihyun Yu Jihyun Yu +Johann Hofmann Johann John Clements John Hodge John Hodge -Jorge Aparicio +John Kåre Alsaker +John Talling Jonathan Bailey +Jonathan S Jonathan S +Jorge Aparicio +Joseph Martin +João Oliveira joaoxsouls Junyoung Cho Jyun-Yan You Kang Seonghoon -Keegan McAllister +Keegan McAllister +Kevin Butler Kyeongwoon Lee -Lee Wondong Lee Jeffery Lee Jeffery +Lee Wondong Lennart Kudling +Léo Testard Lindsey Kuper Lindsey Kuper -Luqman Aden -Luqman Aden Luke Metz +Luqman Aden +Luqman Aden Makoto Nakashima Makoto Nakashima gifnksm -Markus Westerlind Markus +Makoto Nakashima NAKASHIMA, Makoto +Marcell Pardavi Margaret Meyerhofer Mark Sinclair Mark Sinclair =Mark Sinclair <=125axel125@gmail.com> +Markus Westerlind Markus Matej Lach Matej Ľach Matt Brubeck Matthew Auld Matthew McPherrin Matthijs Hofstra Michael Williams -Michael Woerister Michael Woerister +Michael Woerister +Mickaël Raybaud-Roig m-r-r Ms2ger +Mukilan Thiagarajan +NAKASHIMA, Makoto +Nathan Wilson +Nathaniel Herman Nathaniel Herman Neil Pankey Nicholas Mazzuca Nicholas -Oliver Schneider Oliver 'ker' Schneider -Oliver Schneider Oliver Schneider Oliver Schneider Oliver Schneider +Nick Platt +Nif Ward +Oliver Schneider oli-obk +Oliver Schneider Oliver 'ker' Schneider +Oliver Schneider Oliver Schneider +Oliver Schneider Oliver Schneider +Oliver Schneider Oliver Schneider +Oliver Schneider Oliver Schneider Ožbolt Menegatti gareins Paul Faria Paul Faria Peer Aramillo Irizar parir Peter Elmers +Peter Zotov +Phil Dawes Phil Dawes Philipp Brüschweiler Philipp Brüschweiler -Pradeep Kumar Przemysław Wesołek Przemek Wesołek +Rafael Ávila de Espíndola Rafael Avila de Espindola Ralph Giles Ralph Giles +Renato Riccieri Santos Zannon Richard Diamond Rob Arnold +Rob Arnold Rob Arnold Robert Foss robertfoss Robert Gawdzik Robert Gawdzik ☢ Robert Millar +Rohit Joshi Rohit Joshi +Russell Johnston Ruud van Asseldonk Ruud van Asseldonk Ryan Scheel +S Pradeep Kumar +Scott Olson Scott Olson Sean Gillespie swgillespie Seonghyun Kim Simon Barber-Dueck Simon BD Simon Sapin +Simonas Kazlauskas Simonas Kazlauskas startling +Stepan Koltsov Stepan Koltsov Steven Fackler Steven Stewart-Gallus +Stuart Pernsteiner Stuart Pernsteiner Tamir Duberstein Tamir Duberstein +Tero Hänninen Tero Hänninen +Theo Belaire Theo Belaire Thiago Pontes thiagopnts +Thomas Bracht Laumann Jespersen Ticki Ticki <@> +Tim Brooks Tim Brooks Tim Chevalier +Tim JIANG +Tim Joseph Dumol Torsten Weber -Ulrik Sverdrup Ulrik Sverdrup +Ty Overby +Ulrik Sverdrup bluss Ulrik Sverdrup bluss bluss +Ulrik Sverdrup Ulrik Sverdrup +Vadim Petrochenkov Vadim Petrochenkov petrochenkov Vitali Haravy Vitali Haravy William Ting -Xuefeng Wu Xuefeng Wu XuefengWu +Xuefeng Wu Xuefeng Wu +Xuefeng Wu XuefengWu +York Xiang Youngsoo Son +Zach Pomerantz Zack Corr Zack Slayton +Zbigniew Siciarz Zbigniew Siciarz diff --git a/AUTHORS.txt b/AUTHORS.txt index 5f316744021e..b7fa4a5a4a73 100644 --- a/AUTHORS.txt +++ b/AUTHORS.txt @@ -98,7 +98,6 @@ Anton Löfgren Antti Keränen Aram Visser arcnmx -Arcterus Areski Belaid Ariel Ben-Yehuda Arjan Topolovec @@ -136,7 +135,6 @@ Ben Gesoff Ben Harris Ben Kelly Ben Noordhuis -Ben S Ben Sago Ben Striegel benaryorg @@ -434,7 +432,6 @@ Gábor Horváth Gábor Lehel Gabriel gamazeps -gareth Gareth Daniel Smith Garming Sam Garrett Heel @@ -495,7 +492,6 @@ Igor Strebezhev Ilya Dmitrichenko Ilyong Cho Ingo Blechschmidt -inrustwetrust Irving A.J. Rivas Z. Isaac Aggrey Isaac Dupree @@ -733,7 +729,6 @@ Liam Monahan Liigo Zhuang Lindsey Kuper Lionel Flandrin -llogiq Logan Chien Loïc Damien Lorenz @@ -760,7 +755,7 @@ Manuel Hoffmann Marc-Antoine Perennou Marcel Müller Marcel Rodrigues -marcell +Marcell Pardavi Marcello Seri Marcus Klaas Margaret Meyerhofer @@ -924,9 +919,7 @@ Oak OGINO Masanori OlegTsyba Oliver Schneider -Oliver Schneider -Oliver Schneider -Oliver Schneider +Oliver Schneider Olivier Saut olivren Olle Jonsson @@ -937,7 +930,6 @@ Oren Hazi Orphée Lafond-Lummis Orpheus Lummis osa1 -Overmind JIANG Ožbolt Menegatti P1start Pablo Brasero @@ -978,7 +970,6 @@ Peter Schuller Peter Williams Peter Zotov Petter Remen -pez Phil Dawes Phil Ruffwind Philip Munksgaard @@ -1065,7 +1056,6 @@ Ryan Pendleton Ryan Prichard Ryan Riginding Ryan Scheel -Ryman Ryo Munakata S Pradeep Kumar Sae-bom Kim @@ -1153,7 +1143,6 @@ Swaroop C H Sylvestre Ledru Taliesin Beynon Tamir Duberstein -Tamir Duberstein Taras Shpot tav Taylor Hutchison @@ -1169,7 +1158,6 @@ Thiago Pontes Thomas Backman Thomas Bracht Laumann Jespersen Thomas Daede -Thomas Jespersen Thomas Karpiniec Tiago Nobrega Tibor Benke @@ -1255,7 +1243,6 @@ Wei-Ming Yang Wendell Smith Wesley Wiser whataloadofwhat -whitequark wickerwaka Wilfred Hughes Will @@ -1275,8 +1262,6 @@ Xavier Shay Xiao Chuan Yu Xue Fuqiao Xuefeng Wu -Xuefeng Wu -XuefengWu Yasuhiro Fujii YawarRaza7349 Yazhong Liu diff --git a/src/etc/add-authors.sh b/src/etc/add-authors.sh old mode 100644 new mode 100755 index 3ae0ec73957e..e45b803fa07e --- a/src/etc/add-authors.sh +++ b/src/etc/add-authors.sh @@ -30,8 +30,8 @@ range="$1" authors_file="./AUTHORS.txt" tmp_file="./AUTHORS.txt.tmp" old_authors="$(cat "$authors_file" | tail -n +2 | sed "/^$/d" | sort)" -new_authors="$(git log "$range" --format="%aN <%aE>" | sort | uniq)" +new_authors="$(git log "$range" --use-mailmap --format="%aN <%aE>" | sort | uniq)" printf "%s\n\n" "Rust was written by these fine people:" > "$tmp_file" -printf "%s\n%s" "$old_authors" "$new_authors" | sort | uniq >> "$tmp_file" +printf "%s\n%s" "$old_authors" "$new_authors" | sort -fs | uniq >> "$tmp_file" mv -f "$tmp_file" "$authors_file" From ca4ab32a1e9659630b319e381e0088f5011e6070 Mon Sep 17 00:00:00 2001 From: Steve Klabnik Date: Mon, 16 Nov 2015 12:04:25 -0500 Subject: [PATCH 09/11] Nomicon: mention tuple structs with repr(c) Fixes #29526 --- src/doc/nomicon/other-reprs.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/doc/nomicon/other-reprs.md b/src/doc/nomicon/other-reprs.md index e361fbb7ae86..2639c1d4d6f7 100644 --- a/src/doc/nomicon/other-reprs.md +++ b/src/doc/nomicon/other-reprs.md @@ -26,6 +26,9 @@ still consumes a byte of space. * DSTs, tuples, and tagged unions are not a concept in C and as such are never FFI safe. +* Tuple structs are like structs with regards to `repr(C)`, as the only + difference from a struct is that the fields aren’t named. + * **If the type would have any [drop flags], they will still be added** * This is equivalent to one of `repr(u*)` (see the next section) for enums. The From 55ca08969428e185b896bb9b2518372f57522126 Mon Sep 17 00:00:00 2001 From: Andrew Paseltiner Date: Mon, 16 Nov 2015 12:56:18 -0500 Subject: [PATCH 10/11] Correct comment in `Mutex` example --- src/libstd/sync/mutex.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libstd/sync/mutex.rs b/src/libstd/sync/mutex.rs index c0cd6d127d28..48631bfc5f9d 100644 --- a/src/libstd/sync/mutex.rs +++ b/src/libstd/sync/mutex.rs @@ -66,7 +66,7 @@ use sys_common::poison::{self, TryLockError, TryLockResult, LockResult}; /// for _ in 0..10 { /// let (data, tx) = (data.clone(), tx.clone()); /// thread::spawn(move || { -/// // The shared static can only be accessed once the lock is held. +/// // The shared state can only be accessed once the lock is held. /// // Our non-atomic increment is safe because we're the only thread /// // which can access the shared state when the lock is held. /// // From 5cc0a37123258fd5207a6e67723ea2c83bc89101 Mon Sep 17 00:00:00 2001 From: Brian Anderson Date: Mon, 16 Nov 2015 11:48:18 -0800 Subject: [PATCH 11/11] Minor tweaks to doc index --- src/doc/index.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/doc/index.md b/src/doc/index.md index 89fa45a3ad6f..5f2ef6107298 100644 --- a/src/doc/index.md +++ b/src/doc/index.md @@ -33,14 +33,14 @@ something if you know its name. # The Rustonomicon -[The Rustonomicon] is an entire book dedicated dedicated to explaining +[The Rustonomicon] is an entire book dedicated to explaining how to write `unsafe` Rust code. It is for advanced Rust programmers. [The Rustonomicon]: nomicon/index.html # Tools -[Cargo](http://doc.crates.io/index.html) is the Rust's package manager providing access to libraries +[Cargo](http://doc.crates.io/index.html) is the Rust package manager providing access to libraries beyond the standard one, and its website contains lots of good documentation. [`rustdoc`](book/documentation.html) is the Rust's documentation generator, a tool converting