mirror of
https://github.com/rust-lang/rust
synced 2024-09-05 16:57:03 +00:00
partial set of fixes for fallout in tests/run-pass
This commit is contained in:
parent
b85c4d16d5
commit
c8bf5f5d97
|
@ -16,10 +16,10 @@
|
|||
#![deny(overflowing_literals)]
|
||||
|
||||
pub fn main() {
|
||||
assert_eq!(0xffffffff, (-1 as u32));
|
||||
assert_eq!(4294967295, (-1 as u32));
|
||||
assert_eq!(0xffffffffffffffff, (-1 as u64));
|
||||
assert_eq!(18446744073709551615, (-1 as u64));
|
||||
assert_eq!(0xffffffff, (!0 as u32));
|
||||
assert_eq!(4294967295, (!0 as u32));
|
||||
assert_eq!(0xffffffffffffffff, (!0 as u64));
|
||||
assert_eq!(18446744073709551615, (!0 as u64));
|
||||
|
||||
assert_eq!((-2147483648i32).wrapping_sub(1), 2147483647);
|
||||
}
|
||||
|
|
|
@ -8,6 +8,7 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#![feature(negate_unsigned)]
|
||||
|
||||
#[cfg(any(target_arch = "x86", target_arch = "arm"))]
|
||||
fn target() {
|
||||
|
|
|
@ -10,6 +10,7 @@
|
|||
|
||||
// pretty-expanded FIXME #23616
|
||||
|
||||
#![feature(negate_unsigned)]
|
||||
#![feature(intrinsics)]
|
||||
|
||||
mod rusti {
|
||||
|
|
|
@ -10,10 +10,10 @@
|
|||
|
||||
// pretty-expanded FIXME #23616
|
||||
|
||||
static X2: u64 = -1 as u16 as u64;
|
||||
static Y2: u64 = -1 as u32 as u64;
|
||||
const X: u64 = -1 as u16 as u64;
|
||||
const Y: u64 = -1 as u32 as u64;
|
||||
static X2: u64 = !0 as u16 as u64;
|
||||
static Y2: u64 = !0 as u32 as u64;
|
||||
const X: u64 = !0 as u16 as u64;
|
||||
const Y: u64 = !0 as u32 as u64;
|
||||
|
||||
fn main() {
|
||||
assert_eq!(match 1 {
|
||||
|
|
Loading…
Reference in a new issue