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

Skip to content

Rollup of 7 pull requests #65586

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 50 commits into from
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
50 commits
Select commit Hold shift + click to select a range
23d3ff1
Fix zero-size uninitialized boxes
SimonSapin Oct 6, 2019
9d5208a
Remove sanitizer runtime crates
tmiasko Oct 6, 2019
c1b5249
Remove sanitizer_runtime attribute
tmiasko Oct 7, 2019
87c3eed
Link sanitizer runtimes instead of injecting crate dependencies
tmiasko Oct 6, 2019
ac3cf6b
Compile main executable with rustc in staticlib test
tmiasko Oct 7, 2019
7864cb4
Enable sanitizer-leak test case
tmiasko Oct 8, 2019
f721547
ci: move install-awscli.sh into scripts/
pietroalbini Oct 4, 2019
e9974f9
ci: extract dumping the environment into a script
pietroalbini Oct 4, 2019
6b89d59
ci: extract installing sccache into a script
pietroalbini Oct 4, 2019
aa76006
ci: extract installing clang into a script
pietroalbini Oct 4, 2019
7c23f58
ci: extract switching xcode into a script
pietroalbini Oct 7, 2019
6cfe5d9
ci: extract parts of windows-build-deps into scripts
pietroalbini Oct 7, 2019
1ac2ad3
ci: extract disabling git crlf handling into a script
pietroalbini Oct 7, 2019
f828a41
ci: extract installing msys2 into a script
pietroalbini Oct 7, 2019
a5ea6ce
ci: extract installing mingw into a script
pietroalbini Oct 8, 2019
69a946a
ci: extract installing ninja into a script
pietroalbini Oct 8, 2019
d778f95
ci: extract enabling ipv6 on docker into a script
pietroalbini Oct 8, 2019
09bf3cf
ci: extract checking out submodules into a script
pietroalbini Oct 8, 2019
646da3a
ci: extract verifying line endings into a script
pietroalbini Oct 8, 2019
c139db7
ci: use shared.sh in scripts/install-awscli.sh
pietroalbini Oct 8, 2019
9458c9b
ci: cleanup platform detection
pietroalbini Oct 8, 2019
11173f8
ci: fix tidy
pietroalbini Oct 8, 2019
11c59e3
ci: reuse the mirrors base url from shared.sh in scripts
pietroalbini Oct 9, 2019
6351efb
ci: fix innosetup installation
pietroalbini Oct 15, 2019
01008e4
Update libc to 0.2.64
mati865 Oct 16, 2019
c2c290e
Document sanitizers in unstable-book
tmiasko Oct 16, 2019
ca1cfda
Uninitialized boxes: check for zero-size allocation based on Layout::…
SimonSapin Oct 16, 2019
dd4d6a9
Verify that sanitizer runtime is not part of staticlib
tmiasko Oct 17, 2019
75f4dac
Add regression test for #65394
ecstatic-morse Oct 17, 2019
22a0856
Enable `drain_filter`
ecstatic-morse Oct 17, 2019
af691de
Suppress validation mismatch ICE in the presence of mut borrows
ecstatic-morse Oct 17, 2019
6de4924
Update emscripten functions declarations
mati865 Oct 17, 2019
1101101
Refer to "associated functions" instead of "static methods"
estebank Oct 18, 2019
d8fca9e
Use `with` in `Symbol` trait methods.
nnethercote Oct 17, 2019
3532863
Change how `Symbol::Debug` works.
nnethercote Oct 17, 2019
f65a492
Point at enclosing function without `self` receiver
estebank Oct 18, 2019
0879f63
Remove `Copy` and `Clone` impls for `LocalInternedString`.
nnethercote Oct 18, 2019
d343ee8
Remove `Hash` impls for `DefPath`, `DisambiguatedDefPathData`, and `D…
nnethercote Oct 18, 2019
375e34d
ci: fix wrong path being set in install-msys2.sh
pietroalbini Oct 18, 2019
865c4bc
review comments: help wording
estebank Oct 18, 2019
bd813bf
review comment: span bug label
estebank Oct 18, 2019
2b76c8b
review comments
estebank Oct 18, 2019
227db40
Uninitialized boxes: add test for zero-size allocations
SimonSapin Oct 16, 2019
76a7e3e
Rollup merge of #65174 - SimonSapin:zero-box, r=alexcrichton
Centril Oct 19, 2019
a2d9bb7
Rollup merge of #65202 - pietroalbini:scriptify-ci-config, r=alexcric…
Centril Oct 19, 2019
109ecb6
Rollup merge of #65241 - tmiasko:no-std-san, r=nikomatsakis
Centril Oct 19, 2019
94102ef
Rollup merge of #65469 - mati865:libc, r=alexcrichton
Centril Oct 19, 2019
cc633f4
Rollup merge of #65485 - ecstatic-morse:const-validation-mismatch-ugl…
Centril Oct 19, 2019
e74345a
Rollup merge of #65542 - estebank:kill-static-methods, r=Centril
Centril Oct 19, 2019
e76132e
Rollup merge of #65545 - nnethercote:more-symbol-cleanups, r=petroche…
Centril Oct 19, 2019
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
Uninitialized boxes: add test for zero-size allocations
  • Loading branch information
SimonSapin committed Oct 18, 2019
commit 227db40a98e5bd903aa3658c16f19a3d6f694deb
18 changes: 18 additions & 0 deletions src/liballoc/tests/boxed.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
use std::ptr::NonNull;
use std::mem::MaybeUninit;

#[test]
fn unitialized_zero_size_box() {
assert_eq!(
&*Box::<()>::new_uninit() as *const _,
NonNull::<MaybeUninit<()>>::dangling().as_ptr(),
);
assert_eq!(
Box::<[()]>::new_uninit_slice(4).as_ptr(),
NonNull::<MaybeUninit<()>>::dangling().as_ptr(),
);
assert_eq!(
Box::<[String]>::new_uninit_slice(0).as_ptr(),
NonNull::<MaybeUninit<String>>::dangling().as_ptr(),
);
}
2 changes: 2 additions & 0 deletions src/liballoc/tests/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
#![feature(box_syntax)]
#![feature(drain_filter)]
#![feature(exact_size_is_empty)]
#![feature(new_uninit)]
#![feature(option_flattening)]
#![feature(pattern)]
#![feature(repeat_generic_slice)]
Expand All @@ -15,6 +16,7 @@ use std::collections::hash_map::DefaultHasher;

mod arc;
mod binary_heap;
mod boxed;
mod btree;
mod cow_str;
mod fmt;
Expand Down
0