Skip to content

Commit d6906f4

Browse files
committed
---
yaml --- r: 188324 b: refs/heads/master c: 4394720 h: refs/heads/master v: v3
1 parent 9f93191 commit d6906f4

File tree

4 files changed

+16
-7
lines changed

4 files changed

+16
-7
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
refs/heads/master: e7c986105f8af0b4ec4a91a63fbd1706282d401c
2+
refs/heads/master: 4394720dae12c119a9b1aed492b1b24ee089d808
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
44
refs/heads/snap-stage3: 3a96d6a9818fe2affc98a187fb1065120458cee9
55
refs/heads/try: 649d35e4d830b27806705dc5352c86ab6d6fd1a1

trunk/src/test/run-fail/overflowing-add.rs

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,11 @@
88
// option. This file may not be copied, modified, or distributed
99
// except according to those terms.
1010

11-
// error-pattern:thread '<main>' panicked at 'arithmatic operation overflowed'
11+
// error-pattern:thread '<main>' panicked at 'arithmetic operation overflowed'
12+
13+
// (Work around constant-evaluation)
14+
fn value() -> u8 { 200 }
1215

1316
fn main() {
14-
let x = 200u8 + 200u8 + 200u8;
17+
let _x = value() + value() + value();
1518
}

trunk/src/test/run-fail/overflowing-mul.rs

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,11 @@
88
// option. This file may not be copied, modified, or distributed
99
// except according to those terms.
1010

11-
// error-pattern:thread '<main>' panicked at 'arithmatic operation overflowed'
11+
// error-pattern:thread '<main>' panicked at 'arithmetic operation overflowed'
12+
13+
// (Work around constant-evaluation)
14+
fn value() -> u8 { 200 }
1215

1316
fn main() {
14-
let x = 200u8 + 4u8;
17+
let x = value() * 4;
1518
}

trunk/src/test/run-fail/overflowing-sub.rs

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,11 @@
88
// option. This file may not be copied, modified, or distributed
99
// except according to those terms.
1010

11-
// error-pattern:thread '<main>' panicked at 'arithmatic operation overflowed'
11+
// error-pattern:thread '<main>' panicked at 'arithmetic operation overflowed'
12+
13+
// (Work around constant-evaluation)
14+
fn value() -> u8 { 42 }
1215

1316
fn main() {
14-
let x = 42u8 - 43u8;
17+
let _x = value() - (value() + 1);
1518
}

0 commit comments

Comments
 (0)