Skip to content

Commit 2f84bfc

Browse files
committed
Auto merge of #1561 - RalfJung:rustup, r=RalfJung
rustup; fix tests
2 parents 462243e + 67c5067 commit 2f84bfc

6 files changed

+7
-7
lines changed

rust-version

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
a6008fac97f81a3fc51668b0c7fa0e2e6f2a599b
1+
78a089487b5f6d5e4205ac4500410b442857bced

tests/compile-fail/alloc/deallocate-bad-alignment.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
use std::alloc::{alloc, dealloc, Layout};
22

3-
// error-pattern: allocation has size 1 and alignment 1, but gave size 1 and alignment 2
3+
// error-pattern: has size 1 and alignment 1, but gave size 1 and alignment 2
44

55
fn main() {
66
unsafe {

tests/compile-fail/alloc/deallocate-bad-size.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
use std::alloc::{alloc, dealloc, Layout};
22

3-
// error-pattern: allocation has size 1 and alignment 1, but gave size 2 and alignment 1
3+
// error-pattern: has size 1 and alignment 1, but gave size 2 and alignment 1
44

55
fn main() {
66
unsafe {

tests/compile-fail/alloc/reallocate-bad-size.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
use std::alloc::{alloc, realloc, Layout};
22

3-
// error-pattern: allocation has size 1 and alignment 1, but gave size 2 and alignment 1
3+
// error-pattern: has size 1 and alignment 1, but gave size 2 and alignment 1
44

55
fn main() {
66
unsafe {

tests/compile-fail/alloc/stack_free.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
// Validation/SB changes why we fail
22
// compile-flags: -Zmiri-disable-validation -Zmiri-disable-stacked-borrows
33

4-
// error-pattern: deallocating stack variable memory using Rust heap deallocation operation
4+
// error-pattern: which is stack variable memory, using Rust heap deallocation operation
55

66
fn main() {
77
let x = 42;

tests/run-pass/heap_allocator.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ use std::ptr::NonNull;
44
use std::alloc::{Global, AllocRef, Layout, System};
55
use std::slice;
66

7-
fn check_alloc<T: AllocRef>(mut allocator: T) { unsafe {
7+
fn check_alloc<T: AllocRef>(allocator: T) { unsafe {
88
for &align in &[4, 8, 16, 32] {
99
let layout_20 = Layout::from_size_align(20, align).unwrap();
1010
let layout_40 = Layout::from_size_align(40, 4*align).unwrap();
@@ -42,7 +42,7 @@ fn check_alloc<T: AllocRef>(mut allocator: T) { unsafe {
4242
}
4343
} }
4444

45-
fn check_align_requests<T: AllocRef>(mut allocator: T) {
45+
fn check_align_requests<T: AllocRef>(allocator: T) {
4646
for &size in &[2, 8, 64] { // size less than and bigger than alignment
4747
for &align in &[4, 8, 16, 32] { // Be sure to cover less than and bigger than `MIN_ALIGN` for all architectures
4848
let iterations = 32;

0 commit comments

Comments
 (0)