From 25d068e36ed2f4c1b526185fbb2763c38616a10f Mon Sep 17 00:00:00 2001 From: Sandeep Datta Date: Sun, 17 Jan 2016 14:08:01 +0530 Subject: [PATCH 01/17] Showed the difference between `map` and `and_then` with an example. --- src/doc/book/error-handling.md | 22 +++++++++++++++++----- 1 file changed, 17 insertions(+), 5 deletions(-) diff --git a/src/doc/book/error-handling.md b/src/doc/book/error-handling.md index 9b1d16170b97f..b5c0eabba9de7 100644 --- a/src/doc/book/error-handling.md +++ b/src/doc/book/error-handling.md @@ -351,11 +351,21 @@ fn file_name(file_path: &str) -> Option<&str> { ``` You might think that we could use the `map` combinator to reduce the case -analysis, but its type doesn't quite fit. Namely, `map` takes a function that -does something only with the inner value. The result of that function is then -*always* [rewrapped with `Some`](#code-option-map). Instead, we need something -like `map`, but which allows the caller to return another `Option`. Its generic -implementation is even simpler than `map`: +analysis, but its type doesn't quite fit... + +```rust +fn file_path_ext(file_path: &str) -> Option<&str> { + file_name(file_path).map(|x| extension(x)) //Compilation error +} +``` + +The `map` function here wraps the value returned by the `extension` function inside an `Option<_>` and since the `extension` function itself returns an `Option<&str>` the expression `file_name(file_path).map(|x| extension(x))` actually returns an `Option>`. + +But since `file_path_ext` just returns `Option<&str>` (and not `Option>`) we get a compilation error. + +The result of the function taken by map as input is *always* [rewrapped with `Some`](#code-option-map). Instead, we need something like `map`, but which allows the caller to return a `Option<_>` directly without wrapping it in another `Option<_>`. + +Its generic implementation is even simpler than `map`: ```rust fn and_then(option: Option, f: F) -> Option @@ -377,6 +387,8 @@ fn file_path_ext(file_path: &str) -> Option<&str> { } ``` +Side note: Since `and_then` essentially works like `map` but returns an `Option<_>` instead of an `Option>` it is known as `flatmap` in some other languages. + The `Option` type has many other combinators [defined in the standard library][5]. It is a good idea to skim this list and familiarize yourself with what's available—they can often reduce case analysis From 5f20143ccfd1a74a8a104ecac33f777ade12992f Mon Sep 17 00:00:00 2001 From: Sandeep Datta Date: Wed, 20 Jan 2016 19:48:00 +0530 Subject: [PATCH 02/17] Fixed line wrapping. --- src/doc/book/error-handling.md | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/src/doc/book/error-handling.md b/src/doc/book/error-handling.md index b5c0eabba9de7..d4df6a813bc80 100644 --- a/src/doc/book/error-handling.md +++ b/src/doc/book/error-handling.md @@ -359,11 +359,18 @@ fn file_path_ext(file_path: &str) -> Option<&str> { } ``` -The `map` function here wraps the value returned by the `extension` function inside an `Option<_>` and since the `extension` function itself returns an `Option<&str>` the expression `file_name(file_path).map(|x| extension(x))` actually returns an `Option>`. +The `map` function here wraps the value returned by the `extension` function +inside an `Option<_>` and since the `extension` function itself returns an +`Option<&str>` the expression `file_name(file_path).map(|x| extension(x))` +actually returns an `Option>`. -But since `file_path_ext` just returns `Option<&str>` (and not `Option>`) we get a compilation error. +But since `file_path_ext` just returns `Option<&str>` (and not +`Option>`) we get a compilation error. -The result of the function taken by map as input is *always* [rewrapped with `Some`](#code-option-map). Instead, we need something like `map`, but which allows the caller to return a `Option<_>` directly without wrapping it in another `Option<_>`. +The result of the function taken by map as input is *always* [rewrapped with +`Some`](#code-option-map). Instead, we need something like `map`, but which +allows the caller to return a `Option<_>` directly without wrapping it in +another `Option<_>`. Its generic implementation is even simpler than `map`: @@ -387,7 +394,9 @@ fn file_path_ext(file_path: &str) -> Option<&str> { } ``` -Side note: Since `and_then` essentially works like `map` but returns an `Option<_>` instead of an `Option>` it is known as `flatmap` in some other languages. +Side note: Since `and_then` essentially works like `map` but returns an +`Option<_>` instead of an `Option>` it is known as `flatmap` in some +other languages. The `Option` type has many other combinators [defined in the standard library][5]. It is a good idea to skim this list and familiarize From 5a5aacac1f6f06fdbff415e74e9f71ebf6443a4d Mon Sep 17 00:00:00 2001 From: Steve Klabnik Date: Mon, 25 Jan 2016 22:57:57 -0500 Subject: [PATCH 03/17] Document LTR vs RTL wrt trim_* The doc part of #30459 --- src/libcollections/str.rs | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/src/libcollections/str.rs b/src/libcollections/str.rs index 9ce1a111cf83a..03474a45fead7 100644 --- a/src/libcollections/str.rs +++ b/src/libcollections/str.rs @@ -1515,6 +1515,13 @@ impl str { /// 'Whitespace' is defined according to the terms of the Unicode Derived /// Core Property `White_Space`. /// + /// # Text directionality + /// + /// A string is a sequence of bytes. 'Left' in this context means the first + /// position of that byte string; for a language like Arabic or Hebrew + /// which are 'right to left' rather than 'left to right', this will be + /// the _right_ side, not the left. + /// /// # Examples /// /// Basic usage: @@ -1534,6 +1541,13 @@ impl str { /// 'Whitespace' is defined according to the terms of the Unicode Derived /// Core Property `White_Space`. /// + /// # Text directionality + /// + /// A string is a sequence of bytes. 'Right' in this context means the last + /// position of that byte string; for a language like Arabic or Hebrew + /// which are 'right to left' rather than 'left to right', this will be + /// the _left_ side, not the right. + /// /// # Examples /// /// Basic usage: @@ -1588,6 +1602,13 @@ impl str { /// /// [`char`]: primitive.char.html /// + /// # Text directionality + /// + /// A string is a sequence of bytes. 'Left' in this context means the first + /// position of that byte string; for a language like Arabic or Hebrew + /// which are 'right to left' rather than 'left to right', this will be + /// the _right_ side, not the left. + /// /// # Examples /// /// Basic usage: @@ -1612,6 +1633,13 @@ impl str { /// /// [`char`]: primitive.char.html /// + /// # Text directionality + /// + /// A string is a sequence of bytes. 'Right' in this context means the last + /// position of that byte string; for a language like Arabic or Hebrew + /// which are 'right to left' rather than 'left to right', this will be + /// the _left_ side, not the right. + /// /// # Examples /// /// Simple patterns: From f841f061ecdff7c5fd791f164b4d873399621bde Mon Sep 17 00:00:00 2001 From: Ruud van Asseldonk Date: Thu, 28 Jan 2016 22:23:47 +0100 Subject: [PATCH 04/17] Improve message for rustc --explain E0507 E0507 can occur when you try to move out of a member of a mutably borrowed struct, in which case `mem::replace` can help. Mentioning that here hopefully saves future users a trip to Google. --- src/librustc_borrowck/diagnostics.rs | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/src/librustc_borrowck/diagnostics.rs b/src/librustc_borrowck/diagnostics.rs index 7ad4d3ca70898..6cbea1abbb5bb 100644 --- a/src/librustc_borrowck/diagnostics.rs +++ b/src/librustc_borrowck/diagnostics.rs @@ -377,6 +377,33 @@ fn main() { } ``` +Moving out of a member of a mutably borrowed struct is fine if you put something +back. `mem::replace` can be used for that: + +``` +struct TheDarkKnight; + +impl TheDarkKnight { + fn nothing_is_true(self) {} +} + +struct Batcave { + knight: TheDarkKnight +} + +fn main() { + use std::mem; + + let mut cave = Batcave { + knight: TheDarkKnight + }; + let borrowed = &mut cave; + + borrowed.knight.nothing_is_true(); // E0507 + mem::replace(&mut borrowed.knight, TheDarkKnight).nothing_is_true(); // ok! +} +``` + You can find more information about borrowing in the rust-book: http://doc.rust-lang.org/stable/book/references-and-borrowing.html "##, From b5845c64275593a37a9c74dd8e9c74ee3df72b28 Mon Sep 17 00:00:00 2001 From: Oliver Schneider Date: Fri, 29 Jan 2016 11:25:20 +0100 Subject: [PATCH 05/17] fix overflow due to multiline error span --- src/libsyntax/errors/emitter.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libsyntax/errors/emitter.rs b/src/libsyntax/errors/emitter.rs index c1239bfd66db8..4b6f42db50d8e 100644 --- a/src/libsyntax/errors/emitter.rs +++ b/src/libsyntax/errors/emitter.rs @@ -518,7 +518,7 @@ impl EmitterWriter { }; let lo = self.cm.lookup_char_pos(sp.lo); let hi = self.cm.lookup_char_pos(sp.hi); - let elide_sp = (lo.line - hi.line) > MAX_SP_LINES; + let elide_sp = (hi.line - lo.line) > MAX_SP_LINES; let line_num = line.line_index + 1; if !(lo.line <= line_num && hi.line >= line_num) { From fe10914adc783472ae0847d5163385d0e49046a4 Mon Sep 17 00:00:00 2001 From: mitaa Date: Fri, 29 Jan 2016 13:45:15 +0100 Subject: [PATCH 06/17] Update emitter.rs --- src/libsyntax/errors/emitter.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libsyntax/errors/emitter.rs b/src/libsyntax/errors/emitter.rs index 4b6f42db50d8e..f6a01d2499515 100644 --- a/src/libsyntax/errors/emitter.rs +++ b/src/libsyntax/errors/emitter.rs @@ -1026,7 +1026,7 @@ mod test { \x20 ^ ^\n"; let expect0_end = "dummy.txt: 5 ccccc\n\ - \x20 ...\n\ + dummy.txt: 6 xxxxx\n\ dummy.txt: 7 yyyyy\n\ \x20 ^\n\ \x20 ...\n\ From 0922d7e68f3186aa57751af26f3342b1837a5140 Mon Sep 17 00:00:00 2001 From: Sandeep Datta Date: Sat, 30 Jan 2016 13:43:02 +0530 Subject: [PATCH 07/17] Ignoring demo code with compilation error. --- src/doc/book/error-handling.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/doc/book/error-handling.md b/src/doc/book/error-handling.md index d4df6a813bc80..cf78a21d26fd5 100644 --- a/src/doc/book/error-handling.md +++ b/src/doc/book/error-handling.md @@ -353,7 +353,7 @@ fn file_name(file_path: &str) -> Option<&str> { You might think that we could use the `map` combinator to reduce the case analysis, but its type doesn't quite fit... -```rust +```rust,ignore fn file_path_ext(file_path: &str) -> Option<&str> { file_name(file_path).map(|x| extension(x)) //Compilation error } From 54927ac57f95b4ac6747d29af45fef8e47225852 Mon Sep 17 00:00:00 2001 From: Oliver Schneider Date: Sat, 30 Jan 2016 13:40:40 +0100 Subject: [PATCH 08/17] off by one --- src/libsyntax/errors/emitter.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libsyntax/errors/emitter.rs b/src/libsyntax/errors/emitter.rs index f6a01d2499515..d3982f6a5b628 100644 --- a/src/libsyntax/errors/emitter.rs +++ b/src/libsyntax/errors/emitter.rs @@ -518,7 +518,7 @@ impl EmitterWriter { }; let lo = self.cm.lookup_char_pos(sp.lo); let hi = self.cm.lookup_char_pos(sp.hi); - let elide_sp = (hi.line - lo.line) > MAX_SP_LINES; + let elide_sp = (hi.line - lo.line) >= MAX_SP_LINES; let line_num = line.line_index + 1; if !(lo.line <= line_num && hi.line >= line_num) { From cee1695e0839d0672113e7445cec0722559585ee Mon Sep 17 00:00:00 2001 From: Dirk Gadsden Date: Sun, 31 Jan 2016 11:50:22 -0800 Subject: [PATCH 09/17] Safety docs about `std::process::Child` going out of scope There is no `Drop` implemented for `Child`, so if it goes out of scope in Rust-land and gets deallocated, the child process will continue to exist and execute. If users want a guarantee that the process has finished running and exited they must manually use `kill`, `wait`, or `wait_with_output`. Fixes #31289. --- src/libstd/process.rs | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/libstd/process.rs b/src/libstd/process.rs index 7197dfa8b2d47..2cfbef1e1b7d9 100644 --- a/src/libstd/process.rs +++ b/src/libstd/process.rs @@ -47,6 +47,14 @@ use thread::{self, JoinHandle}; /// /// assert!(ecode.success()); /// ``` +/// +/// # Safety +/// +/// Take note that there is no implementation of +/// [`Drop`](../../core/ops/trait.Drop.html) for child processes, so if you +/// not ensure the `Child` has exited (through `kill`, `wait`, or +/// `wait_with_output`) then it will continue to run even after the `Child` +/// handle to it has gone out of scope. #[stable(feature = "process", since = "1.0.0")] pub struct Child { handle: imp::Process, From 76839221ff9bc4fd65ab9e7c0f1cd8e7514446f0 Mon Sep 17 00:00:00 2001 From: Dirk Gadsden Date: Sun, 31 Jan 2016 12:33:37 -0800 Subject: [PATCH 10/17] Minor corrections in docs for `std::process::Child` --- src/libstd/process.rs | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/libstd/process.rs b/src/libstd/process.rs index 2cfbef1e1b7d9..5e0a54392d23d 100644 --- a/src/libstd/process.rs +++ b/src/libstd/process.rs @@ -48,13 +48,15 @@ use thread::{self, JoinHandle}; /// assert!(ecode.success()); /// ``` /// -/// # Safety +/// # Note /// /// Take note that there is no implementation of /// [`Drop`](../../core/ops/trait.Drop.html) for child processes, so if you -/// not ensure the `Child` has exited (through `kill`, `wait`, or -/// `wait_with_output`) then it will continue to run even after the `Child` -/// handle to it has gone out of scope. +/// do not ensure the `Child` has exited then it will continue to run, even +/// after the `Child` handle to the child process has gone out of scope. +/// +/// Calling `wait` (or other functions that wrap around it) will make the +/// parent process wait until the child has actually exited before continuing. #[stable(feature = "process", since = "1.0.0")] pub struct Child { handle: imp::Process, From 2043cd8623a81c6ee4bf722dd81a02368a2727cf Mon Sep 17 00:00:00 2001 From: Prayag Verma Date: Mon, 1 Feb 2016 12:15:33 +0530 Subject: [PATCH 11/17] Fix typo in doc/book/getting-started.md Spelling mistake - `familliar` > `familiar` --- src/doc/book/getting-started.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/doc/book/getting-started.md b/src/doc/book/getting-started.md index d7b6e15794ef4..e0ea42ce0cbdb 100644 --- a/src/doc/book/getting-started.md +++ b/src/doc/book/getting-started.md @@ -569,7 +569,7 @@ executable application, as opposed to a library. Executables are often called *binaries* (as in `/usr/bin`, if you’re on a Unix system). Cargo has generated two files and one directory for us: a `Cargo.toml` and a -*src* directory with a *main.rs* file inside. These should look familliar, +*src* directory with a *main.rs* file inside. These should look familiar, they’re exactly what we created by hand, above. This output is all you need to get started. First, open `Cargo.toml`. It should From 7aa41a1a86cb721bbb297ef394b91cc9ab027cf7 Mon Sep 17 00:00:00 2001 From: Reeze Xia Date: Mon, 1 Feb 2016 18:53:07 +0800 Subject: [PATCH 12/17] Comment fix --- src/libsyntax/ast.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/libsyntax/ast.rs b/src/libsyntax/ast.rs index e327adfaf892c..19bedab9d3054 100644 --- a/src/libsyntax/ast.rs +++ b/src/libsyntax/ast.rs @@ -70,9 +70,9 @@ pub struct Name(pub u32); /// A SyntaxContext represents a chain of macro-expandings /// and renamings. Each macro expansion corresponds to /// a fresh u32. This u32 is a reference to a table stored -// in thread-local storage. -// The special value EMPTY_CTXT is used to indicate an empty -// syntax context. +/// in thread-local storage. +/// The special value EMPTY_CTXT is used to indicate an empty +/// syntax context. #[derive(Clone, Copy, PartialEq, Eq, Hash, Debug, RustcEncodable, RustcDecodable)] pub struct SyntaxContext(pub u32); From 743bad470a701698f930677b40b836d73724b06c Mon Sep 17 00:00:00 2001 From: Steve Klabnik Date: Mon, 1 Feb 2016 11:26:23 -0500 Subject: [PATCH 13/17] Add doctests for directionality Thanks @nodakai --- src/libcollections/str.rs | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/src/libcollections/str.rs b/src/libcollections/str.rs index 03474a45fead7..c21cd81025703 100644 --- a/src/libcollections/str.rs +++ b/src/libcollections/str.rs @@ -1531,6 +1531,16 @@ impl str { /// /// assert_eq!("Hello\tworld\t", s.trim_left()); /// ``` + /// + /// Directionality: + /// + /// ``` + /// let s = " English"; + /// assert!(Some('E') == s.trim_left().chars().next()); + /// + /// let s = " עברית"; + /// assert!(Some('ע') == s.trim_left().chars().next()); + /// ``` #[stable(feature = "rust1", since = "1.0.0")] pub fn trim_left(&self) -> &str { UnicodeStr::trim_left(self) @@ -1557,6 +1567,16 @@ impl str { /// /// assert_eq!(" Hello\tworld", s.trim_right()); /// ``` + /// + /// Directionality: + /// + /// ``` + /// let s = "English "; + /// assert!(Some('E') == s.trim_right().chars().next()); + /// + /// let s = "עברית "; + /// assert!(Some('ת') == s.trim_right().chars().next()); + /// ``` #[stable(feature = "rust1", since = "1.0.0")] pub fn trim_right(&self) -> &str { UnicodeStr::trim_right(self) From 7df3bf1860d1821056a5e9d4193b7e99d2c9479d Mon Sep 17 00:00:00 2001 From: Steve Klabnik Date: Mon, 1 Feb 2016 11:52:00 -0500 Subject: [PATCH 14/17] make this example more obvious Fixes #31334 --- src/doc/book/loops.md | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/src/doc/book/loops.md b/src/doc/book/loops.md index 5b08c2fb04dbd..b5dde9be17fcb 100644 --- a/src/doc/book/loops.md +++ b/src/doc/book/loops.md @@ -125,7 +125,8 @@ Don't forget to add the parentheses around the range. #### On iterators: ```rust -# let lines = "hello\nworld".lines(); +let lines = "hello\nworld".lines(); + for (linenumber, line) in lines.enumerate() { println!("{}: {}", linenumber, line); } @@ -134,10 +135,8 @@ for (linenumber, line) in lines.enumerate() { Outputs: ```text -0: Content of line one -1: Content of line two -2: Content of line three -3: Content of line four +0: hello +1: world ``` ## Ending iteration early From ed087015392adf58c497f884ecf116dc07952ce3 Mon Sep 17 00:00:00 2001 From: Alexander Lopatin Date: Mon, 1 Feb 2016 21:09:19 +0300 Subject: [PATCH 15/17] Fix a documentation typo --- src/libcore/sync/atomic.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libcore/sync/atomic.rs b/src/libcore/sync/atomic.rs index 21b76c1f4bec1..700a577e20c92 100644 --- a/src/libcore/sync/atomic.rs +++ b/src/libcore/sync/atomic.rs @@ -711,7 +711,7 @@ impl AtomicUsize { /// ``` /// use std::sync::atomic::{AtomicUsize, Ordering}; /// - /// let some_usize= AtomicUsize::new(5); + /// let some_usize = AtomicUsize::new(5); /// /// assert_eq!(some_usize.swap(10, Ordering::Relaxed), 5); /// assert_eq!(some_usize.load(Ordering::Relaxed), 10); From 4289973a2d95fa95a45b225c02ca8937f2b8c09e Mon Sep 17 00:00:00 2001 From: Tshepang Lekhonkhobe Date: Wed, 27 Jan 2016 22:23:52 +0200 Subject: [PATCH 16/17] doc: bindings not needed for this example --- src/libcore/iter.rs | 38 ++++++++++---------------------------- 1 file changed, 10 insertions(+), 28 deletions(-) diff --git a/src/libcore/iter.rs b/src/libcore/iter.rs index 3f1c0f6a5492a..93514dbd6bb2f 100644 --- a/src/libcore/iter.rs +++ b/src/libcore/iter.rs @@ -2756,20 +2756,11 @@ pub trait Extend { /// /// let mut iter = numbers.iter(); /// -/// let n = iter.next(); -/// assert_eq!(Some(&1), n); -/// -/// let n = iter.next_back(); -/// assert_eq!(Some(&3), n); -/// -/// let n = iter.next_back(); -/// assert_eq!(Some(&2), n); -/// -/// let n = iter.next(); -/// assert_eq!(None, n); -/// -/// let n = iter.next_back(); -/// assert_eq!(None, n); +/// assert_eq!(Some(&1), iter.next()); +/// assert_eq!(Some(&3), iter.next_back()); +/// assert_eq!(Some(&2), iter.next_back()); +/// assert_eq!(None, iter.next()); +/// assert_eq!(None, iter.next_back()); /// ``` #[stable(feature = "rust1", since = "1.0.0")] pub trait DoubleEndedIterator: Iterator { @@ -2789,20 +2780,11 @@ pub trait DoubleEndedIterator: Iterator { /// /// let mut iter = numbers.iter(); /// - /// let n = iter.next(); - /// assert_eq!(Some(&1), n); - /// - /// let n = iter.next_back(); - /// assert_eq!(Some(&3), n); - /// - /// let n = iter.next_back(); - /// assert_eq!(Some(&2), n); - /// - /// let n = iter.next(); - /// assert_eq!(None, n); - /// - /// let n = iter.next_back(); - /// assert_eq!(None, n); + /// assert_eq!(Some(&1), iter.next()); + /// assert_eq!(Some(&3), iter.next_back()); + /// assert_eq!(Some(&2), iter.next_back()); + /// assert_eq!(None, iter.next()); + /// assert_eq!(None, iter.next_back()); /// ``` #[stable(feature = "rust1", since = "1.0.0")] fn next_back(&mut self) -> Option; From 0574b395efa0f95aed4eaacaf4445fc78687c4cd Mon Sep 17 00:00:00 2001 From: Alex Crichton Date: Fri, 29 Jan 2016 11:10:44 -0800 Subject: [PATCH 17/17] doc: Move 32-bit MSVC to a tier 1 platform Some other shufflings as well: * Three powerpc triples for Linux have been added recently * An armv7 linux triple was added recently * The 64-bit Solaris triple is now mentioned in tier 3 We are currently now also building nightlies for iOS, powerpc triples, and armv7, but there hasn't been much vetting of the triples themselves so I've left them in tier 3 for now. --- src/doc/book/getting-started.md | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/doc/book/getting-started.md b/src/doc/book/getting-started.md index d7b6e15794ef4..980f72fe70c83 100644 --- a/src/doc/book/getting-started.md +++ b/src/doc/book/getting-started.md @@ -39,6 +39,7 @@ Specifically they will each satisfy the following requirements: | Target | std |rustc|cargo| notes | |-------------------------------|-----|-----|-----|----------------------------| +| `i686-pc-windows-msvc` | ✓ | ✓ | ✓ | 32-bit MSVC (Windows 7+) | | `x86_64-pc-windows-msvc` | ✓ | ✓ | ✓ | 64-bit MSVC (Windows 7+) | | `i686-pc-windows-gnu` | ✓ | ✓ | ✓ | 32-bit MinGW (Windows 7+) | | `x86_64-pc-windows-gnu` | ✓ | ✓ | ✓ | 64-bit MinGW (Windows 7+) | @@ -62,7 +63,6 @@ these platforms are required to have each of the following: | Target | std |rustc|cargo| notes | |-------------------------------|-----|-----|-----|----------------------------| -| `i686-pc-windows-msvc` | ✓ | ✓ | ✓ | 32-bit MSVC (Windows 7+) | | `x86_64-unknown-linux-musl` | ✓ | | | 64-bit Linux with MUSL | | `arm-linux-androideabi` | ✓ | | | ARM Android | | `arm-unknown-linux-gnueabi` | ✓ | ✓ | | ARM Linux (2.6.18+) | @@ -85,6 +85,9 @@ unofficial locations. | `i686-linux-android` | ✓ | | | 32-bit x86 Android | | `aarch64-linux-android` | ✓ | | | ARM64 Android | | `powerpc-unknown-linux-gnu` | ✓ | | | PowerPC Linux (2.6.18+) | +| `powerpc64-unknown-linux-gnu` | ✓ | | | PPC64 Linux (2.6.18+) | +|`powerpc64le-unknown-linux-gnu`| ✓ | | | PPC64LE Linux (2.6.18+) | +|`armv7-unknown-linux-gnueabihf`| ✓ | | | ARMv7 Linux (2.6.18+) | | `i386-apple-ios` | ✓ | | | 32-bit x86 iOS | | `x86_64-apple-ios` | ✓ | | | 64-bit x86 iOS | | `armv7-apple-ios` | ✓ | | | ARM iOS | @@ -97,6 +100,7 @@ unofficial locations. | `x86_64-unknown-bitrig` | ✓ | ✓ | | 64-bit Bitrig | | `x86_64-unknown-dragonfly` | ✓ | ✓ | | 64-bit DragonFlyBSD | | `x86_64-rumprun-netbsd` | ✓ | | | 64-bit NetBSD Rump Kernel | +| `x86_64-sun-solaris` | ✓ | ✓ | | 64-bit Solaris/SunOS | | `i686-pc-windows-msvc` (XP) | ✓ | | | Windows XP support | | `x86_64-pc-windows-msvc` (XP) | ✓ | | | Windows XP support |