Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit f577b0e

Browse files
committedDec 3, 2019
Auto merge of #66982 - Centril:rollup-yq2281i, r=Centril
Rollup of 6 pull requests Successful merges: - #66148 (Show the sign for signed ops on `exact_div`) - #66651 (Add `enclosing scope` parameter to `rustc_on_unimplemented`) - #66904 (Adding docs for keyword match, move) - #66935 (syntax: Unify macro and attribute arguments in AST) - #66941 (Remove `ord` lang item) - #66967 (Remove hack for top-level or-patterns in match checking) Failed merges: r? @ghost
2 parents 7d80865 + bce7798 commit f577b0e

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

63 files changed

+1096
-551
lines changed
 

‎src/libcore/cmp.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -534,7 +534,6 @@ impl<T: Ord> Ord for Reverse<T> {
534534
/// }
535535
/// }
536536
/// ```
537-
#[lang = "ord"]
538537
#[doc(alias = "<")]
539538
#[doc(alias = ">")]
540539
#[doc(alias = "<=")]

‎src/libcore/ops/try.rs

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,19 +5,20 @@
55
/// extracting those success or failure values from an existing instance and
66
/// creating a new instance from a success or failure value.
77
#[unstable(feature = "try_trait", issue = "42327")]
8-
#[rustc_on_unimplemented(
8+
#[cfg_attr(not(bootstrap), rustc_on_unimplemented(
99
on(all(
1010
any(from_method="from_error", from_method="from_ok"),
1111
from_desugaring="QuestionMark"),
1212
message="the `?` operator can only be used in {ItemContext} \
1313
that returns `Result` or `Option` \
1414
(or another type that implements `{Try}`)",
15-
label="cannot use the `?` operator in {ItemContext} that returns `{Self}`"),
15+
label="cannot use the `?` operator in {ItemContext} that returns `{Self}`",
16+
enclosing_scope="this function should return `Result` or `Option` to accept `?`"),
1617
on(all(from_method="into_result", from_desugaring="QuestionMark"),
1718
message="the `?` operator can only be applied to values \
1819
that implement `{Try}`",
1920
label="the `?` operator cannot be applied to type `{Self}`")
20-
)]
21+
))]
2122
#[doc(alias = "?")]
2223
pub trait Try {
2324
/// The type of this value when viewed as successful.

0 commit comments

Comments
 (0)