8000 Rollup of 21 pull requests by pietroalbini · Pull Request #53798 · rust-lang/rust · GitHub
[go: up one dir, main page]

Skip to content

Rollup of 21 pull requests #53798

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 49 commits into from
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
49 commits
Select commit Hold shift + click to select a range
931eb4c
Add one more example for Cow that shows how to keep Cow in a struct
kpp Aug 6, 2018
9a3a12e
Fix review notes
kpp Aug 15, 2018
34b65db
document effect of join on memory ordering
RalfJung Aug 15, 2018
5bfb785
Review fix
kpp Aug 15, 2018
b73843f
Force-inline `shallow_resolve` at its hottest call site.
nnethercote Aug 17, 2018
3995bff
Add another PartialEq example
GuillaumeGomez Aug 21, 2018
9395a02
Fix stabilisation version for macro_vis_matcher.
jkozlowski Aug 25, 2018
1f421d6
call span_suggestion with applicability
jcpst Aug 26, 2018
09a615c
Reduce number of syscalls in `rand`
tbu- Aug 26, 2018
26f38c0
Do not suggest dereferencing in macro
estebank Aug 26, 2018
a2722f3
readd final newline
estebank Aug 27, 2018
4570ace
save-analysis: Differentiate foreign functions and statics.
emilio Aug 18, 2018
c874e36
add llvm-readobj to llvm-tools-preview
japaric Aug 27, 2018
8486efa
fix a typo: taget_env -> target_env
oconnor663 Aug 27, 2018
1d79d8b
Fix source automatic scroll
GuillaumeGomez Aug 27, 2018
04b4c40
Fix invalid display of unstable messages
GuillaumeGomez Aug 27, 2018
f77ad5c
remove `let x = baz` which was obscuring the real error
nikomatsakis Aug 6, 2018
e6dcdee
expand keep-stage --help text
RalfJung Aug 28, 2018
31b63d0
split paragraph
RalfJung Aug 28, 2018
1311339
Fix typo in comment
dmerejkowsky Aug 28, 2018
84796cb
sort
japaric Aug 28, 2018
93f3f5b
Use FxHash{Map,Set} instead of the default Hash{Map,Set} everywhere i…
eddyb Aug 18, 2018
6628d39
move file-extension based .gitignore down to src/
RalfJung Aug 28, 2018
da4febd
Add partialeq implementation for TryFromIntError type
GuillaumeGomez Aug 18, 2018
6d47737
Don't leak the file descriptor in `rand`
tbu- Aug 29, 2018
890d04d
Fix a comment in src/libcore/slice/mod.rs
tbu- Aug 29, 2018
e477a13
Replace usages of 'bad_style' with 'nonstandard_style'.
frewsxcv Aug 29, 2018
003cab2
Generalize `async_idents` to all new keywords
alexcrichton Aug 24, 2018
2deda32
Rollup merge of #51760 - GuillaumeGomez:add-another-partialeq-example…
pietroalbini Aug 29, 2018
8b35394
Rollup merge of #53113 - kpp:more_docs_for_cow, r=GuillaumeGomez
pietroalbini Aug 29, 2018
94dbcfa
Rollup merge of #53129 - nikomatsakis:issue-51172-tweak-test, r=pnkfelix
pietroalbini Aug 29, 2018
474cda8
Rollup merge of #53389 - RalfJung:thread-join, r=sfackler
pietroalbini Aug 29, 2018
64ff1e5
Rollup merge of #53472 - eddyb:fx-pls, r=pnkfelix
pietroalbini Aug 29, 2018
dbf633f
Rollup merge of #53476 - GuillaumeGomez:try-from-int-error-partial-eq…
pietroalbini Aug 29, 2018
0516314
Rollup merge of #53513 - nnethercote:inline-shallow_resolve, r=varkor
pietroalbini Aug 29, 2018
bcd6880
Rollup merge of #53655 - jcpst:with_applicability, r=estebank
pietroalbini Aug 29, 2018
b917b7b
Rollup merge of #53685 - alexcrichton:more-keywords, r=varkor
pietroalbini Aug 29, 2018
a22c6e4
Rollup merge of #53702 - jkozlowski:correct_version_for_macro_vis_mat…
pietroalbini Aug 29, 2018
b18ecbd
Rollup merge of #53725 - tbu-:pr_getrandom_syscalls, r=alexcrichton
pietroalbini Aug 29, 2018
491c4bb
Rollup merge of #53727 - estebank:incorrect-deref-suggestion, r=nikom…
pietroalbini Aug 29, 2018
ef9a675
Rollup merge of #53732 - emilio:foreign-fn, r=nrc
pietroalbini Aug 29, 2018
3848009
Rollup merge of #53740 - japaric:readobj, r=alexcrichton
pietroalbini Aug 29, 2018
3062a0c
Rollup merge of #53743 - oconnor663:target_env, r=kennytm
pietroalbini Aug 29, 2018
8b119b9
Rollup merge of #53747 - GuillaumeGomez:rustdoc-fixes, r=QuietMisdreavus
pietroalbini Aug 29, 2018
e02e048
Rollup merge of #53753 - RalfJung:keep-stage, r=nikomatsakis
pietroalbini Aug 29, 2018
c308206
Rollup merge of #53756 - dmerejkowsky:fix-comment, r=KodrAus
pietroalbini Aug 29, 2018
ad115fc
Rollup merge of #53768 - RalfJung:gitignore, r=nikomatsakis
pietroalbini Aug 29, 2018
b5c3f58
Rollup merge of #53785 - tbu-:pr_comment, r=Mark-Simulacrum
pietroalbini Aug 29, 2018
31a6f9f
Rollup merge of #53786 - frewsxcv:frewsxcv-bad-style, r=Manishearth
pietroalbini Aug 29, 2018
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Add partialeq implementation for TryFromIntError type
  • Loading branch information
GuillaumeGomez committed Aug 28, 2018
commit da4febd51e96f312f80f1c8cc7c7d65b00c50df6
2 changes: 1 addition & 1 deletion src/libcore/num/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4248,7 +4248,7 @@ from_str_radix_int_impl! { isize i8 i16 i32 i64 i128 usize u8 u16 u32 u64 u128 }

/// The error type returned when a checked integral type conversion fails.
#[unstable(feature = "try_from", issue = "33417")]
#[derive(Debug, Copy, Clone)]
#[derive(Debug, Copy, Clone, PartialEq, Eq)]
pub struct TryFromIntError(());

impl TryFromIntError {
Expand Down
21 changes: 21 additions & 0 deletions src/test/run-pass/try-from-int-error-partial-eq.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
// Copyright 2018 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.

#![feature(try_from)]
#![allow(unused_must_use)]

use std::convert::TryFrom;
use std::num::TryFromIntError;

fn main() {
let x: u32 = 125;
let y: Result<u8, TryFromIntError> = u8::try_from(x);
y == Ok(125);
}
0