about summary refs log tree commit diff
path: root/src/libcore
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2019-02-05 16:22:26 +0000
committerbors <bors@rust-lang.org>2019-02-05 16:22:26 +0000
commit8bf7fda6b5fec99a11ae0fb8d5c3dbd150063741 (patch)
tree2cb242a9ee8d27df1217d15e6126f936f7a3b9c9 /src/libcore
parentb2c6b8c29f13f8d1f242da89e587960b95337819 (diff)
parentc23871a4c424d2c78656fc6c49a5c3cc248bed42 (diff)
downloadrust-8bf7fda6b5fec99a11ae0fb8d5c3dbd150063741.tar.gz
rust-8bf7fda6b5fec99a11ae0fb8d5c3dbd150063741.zip
Auto merge of #58189 - kennytm:rollup, r=kennytm
Rollup of 23 pull requests

Successful merges:

 - #58001 (proc_macro: make `TokenStream::from_streams` pre-allocate its vector.)
 - #58096 (Transition linkchecker to 2018 edition)
 - #58097 (Transition remote test to Rust 2018)
 - #58106 (libfmt_macros => 2018)
 - #58107 (libgraphviz => 2018)
 - #58108 (Add NVPTX target to a build manifest)
 - #58109 (librustc_privacy => 2018)
 - #58112 (libpanic_abort => 2018)
 - #58113 (Transition build-manifest to 2018 edition)
 - #58114 (Transition tidy and unstable-book-gen to 2018 edition)
 - #58116 (Include the span of attributes of the lhs to the span of the assignment expression)
 - #58117 (Transition rustdoc-theme to 2018 edition)
 - #58128 (libunwind => 2018)
 - #58138 (Fix #58101)
 - #58139 (hir: add more HirId methods)
 - #58141 (Remove weasel word in docs for iter's take_while())
 - #58142 (Remove stray FIXME)
 - #58145 (Add #[must_use] to core::task::Poll)
 - #58162 (Add more debugging code to track down appveyor 259 exit code)
 - #58169 (Update contributor name in .mailmap)
 - #58172 (update split docs)
 - #58182 (SGX target: handle empty user buffers correctly)
 - #58186 (Add Rustlings to the doc index)

Failed merges:

r? @ghost
Diffstat (limited to 'src/libcore')
-rw-r--r--src/libcore/iter/traits/iterator.rs3
-rw-r--r--src/libcore/str/mod.rs28
-rw-r--r--src/libcore/task/poll.rs1
3 files changed, 16 insertions, 16 deletions
diff --git a/src/libcore/iter/traits/iterator.rs b/src/libcore/iter/traits/iterator.rs
index 9dfa83f473b..218c7199f35 100644
--- a/src/libcore/iter/traits/iterator.rs
+++ b/src/libcore/iter/traits/iterator.rs
@@ -952,8 +952,7 @@ pub trait Iterator {
     /// ```
     ///
     /// The `3` is no longer there, because it was consumed in order to see if
-    /// the iteration should stop, but wasn't placed back into the iterator or
-    /// some similar thing.
+    /// the iteration should stop, but wasn't placed back into the iterator.
     #[inline]
     #[stable(feature = "rust1", since = "1.0.0")]
     fn take_while<P>(self, predicate: P) -> TakeWhile<Self, P> where
diff --git a/src/libcore/str/mod.rs b/src/libcore/str/mod.rs
index 130142103a9..e9190cc3ddf 100644
--- a/src/libcore/str/mod.rs
+++ b/src/libcore/str/mod.rs
@@ -2961,8 +2961,8 @@ impl str {
     /// An iterator over substrings of this string slice, separated by
     /// characters matched by a pattern.
     ///
-    /// The pattern can be a `&str`, [`char`], or a closure that determines the
-    /// split.
+    /// The pattern can be any type that implements the Pattern trait. Notable
+    /// examples are `&str`, [`char`], and closures that determines the split.
     ///
     /// # Iterator behavior
     ///
@@ -3078,8 +3078,8 @@ impl str {
     /// An iterator over substrings of the given string slice, separated by
     /// characters matched by a pattern and yielded in reverse order.
     ///
-    /// The pattern can be a `&str`, [`char`], or a closure that determines the
-    /// split.
+    /// The pattern can be any type that implements the Pattern trait. Notable
+    /// examples are `&str`, [`char`], and closures that determines the split.
     ///
     /// # Iterator behavior
     ///
@@ -3128,8 +3128,8 @@ impl str {
     /// An iterator over substrings of the given string slice, separated by
     /// characters matched by a pattern.
     ///
-    /// The pattern can be a `&str`, [`char`], or a closure that determines the
-    /// split.
+    /// The pattern can be any type that implements the Pattern trait. Notable
+    /// examples are `&str`, [`char`], and closures that determines the split.
     ///
     /// Equivalent to [`split`], except that the trailing substring
     /// is skipped if empty.
@@ -3175,8 +3175,8 @@ impl str {
     /// An iterator over substrings of `self`, separated by characters
     /// matched by a pattern and yielded in reverse order.
     ///
-    /// The pattern can be a simple `&str`, [`char`], or a closure that
-    /// determines the split.
+    /// The pattern can be any type that implements the Pattern trait. Notable
+    /// examples are `&str`, [`char`], and closures that determines the split.
     /// Additional libraries might provide more complex patterns like
     /// regular expressions.
     ///
@@ -3222,8 +3222,8 @@ impl str {
     /// If `n` substrings are returned, the last substring (the `n`th substring)
     /// will contain the remainder of the string.
     ///
-    /// The pattern can be a `&str`, [`char`], or a closure that determines the
-    /// split.
+    /// The pattern can be any type that implements the Pattern trait. Notable
+    /// examples are `&str`, [`char`], and closures that determines the split.
     ///
     /// # Iterator behavior
     ///
@@ -3275,8 +3275,8 @@ impl str {
     /// If `n` substrings are returned, the last substring (the `n`th substring)
     /// will contain the remainder of the string.
     ///
-    /// The pattern can be a `&str`, [`char`], or a closure that
-    /// determines the split.
+    /// The pattern can be any type that implements the Pattern trait. Notable
+    /// examples are `&str`, [`char`], and closures that determines the split.
     ///
     /// # Iterator behavior
     ///
@@ -3319,8 +3319,8 @@ impl str {
     /// An iterator over the disjoint matches of a pattern within the given string
     /// slice.
     ///
-    /// The pattern can be a `&str`, [`char`], or a closure that
-    /// determines if a character matches.
+    /// The pattern can be any type that implements the Pattern trait. Notable
+    /// examples are `&str`, [`char`], and closures that determines the split.
     ///
     /// # Iterator behavior
     ///
diff --git a/src/libcore/task/poll.rs b/src/libcore/task/poll.rs
index 27b1139e15c..ac656153519 100644
--- a/src/libcore/task/poll.rs
+++ b/src/libcore/task/poll.rs
@@ -7,6 +7,7 @@ use result::Result;
 
 /// Indicates whether a value is available or if the current task has been
 /// scheduled to receive a wakeup instead.
+#[must_use = "this `Poll` may be a `Pending` variant, which should be handled"]
 #[derive(Copy, Clone, Debug, Eq, PartialEq, Ord, PartialOrd, Hash)]
 pub enum Poll<T> {
     /// Represents that a value is immediately ready.