partial set of fixes for fallout in tests/run-pass

This commit is contained in:
Felix S. Klock II 2015-04-02 01:09:05 +02:00
parent b85c4d16d5
commit c8bf5f5d97
4 changed files with 10 additions and 8 deletions

View file

@ -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);
}

View file

@ -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() {

View file

@ -10,6 +10,7 @@
// pretty-expanded FIXME #23616
#![feature(negate_unsigned)]
#![feature(intrinsics)]
mod rusti {

View file

@ -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 {