Skip to content

Commit e8ec682

Browse files
committed
---
yaml --- r: 277605 b: refs/heads/try c: f080b13 h: refs/heads/master i: 277603: 8b99d65
1 parent cd231f8 commit e8ec682

File tree

3 files changed

+13
-9
lines changed

3 files changed

+13
-9
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
refs/heads/master: 6dbb0e86aec11050480beb76eade6fb805010ba7
33
refs/heads/snap-stage3: 235d77457d80b549dad3ac36d94f235208a1eafb
4-
refs/heads/try: 10737a5a45ed9a1d9ae73b996fae893da1d62512
4+
refs/heads/try: f080b13c6beaa409c2bb643dd997a73ce0e75b89
55
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
66
refs/tags/release-0.2: c870d2dffb391e14efb05aa27898f1f6333a9596
77
refs/tags/release-0.3: b5f0d0f648d9a6153664837026ba1be43d3e2503

branches/try/src/test/compile-fail/const-eval-overflow-4b.rs

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@
1515

1616
#![allow(unused_imports)]
1717

18-
use std::fmt;
1918
use std::{i8, i16, i32, i64, isize};
2019
use std::{u8, u16, u32, u64, usize};
2120

@@ -26,10 +25,15 @@ const A_I8_T
2625
//~| found `u8` [E0250]
2726
= [0; (i8::MAX as usize) + 1];
2827

29-
fn main() {
30-
foo(&A_I8_T[..]);
31-
}
3228

33-
fn foo<T:fmt::Debug>(x: T) {
34-
println!("{:?}", x);
35-
}
29+
const A_CHAR_USIZE
30+
: [u32; 5u8 as char as usize]
31+
= [0; 5];
32+
33+
34+
const A_BAD_CHAR_USIZE
35+
: [u32; 5i8 as char as usize]
36+
//~^ ERROR only `u8` can be cast as `char`, not `i8`
37+
= [0; 5];
38+
39+
fn main() {}

branches/try/src/test/run-pass/const-err.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright 2015 The Rust Project Developers. See the COPYRIGHT
1+
// Copyright 2016 The Rust Project Developers. See the COPYRIGHT
22
// file at the top-level directory of this distribution and at
33
// http://rust-lang.org/COPYRIGHT.
44
//

0 commit comments

Comments
 (0)