diff options
| author | Graydon Hoare <[email protected]> | 2011-05-02 16:24:09 -0700 |
|---|---|---|
| committer | Graydon Hoare <[email protected]> | 2011-05-02 17:35:33 -0700 |
| commit | d08b443fffb1181d8d45ae5d061412f202dd4118 (patch) | |
| tree | ad75b4e4fc9407aa1201f9068012f30664d17b64 /src/test/run-fail | |
| parent | Add a regression test that exports can expose unexported items (diff) | |
| download | rust-d08b443fffb1181d8d45ae5d061412f202dd4118.tar.xz rust-d08b443fffb1181d8d45ae5d061412f202dd4118.zip | |
Revert "Use different syntax for checks that matter to typestate"
This reverts commit aa25f22f197682de3b18fc4c8ba068d1feda220f. It broke stage2, not sure why yet.
Diffstat (limited to 'src/test/run-fail')
| -rw-r--r-- | src/test/run-fail/fail.rs | 2 | ||||
| -rw-r--r-- | src/test/run-fail/linked-failure.rs | 2 | ||||
| -rw-r--r-- | src/test/run-fail/str-overrun.rs | 4 | ||||
| -rw-r--r-- | src/test/run-fail/vec-overrun.rs | 4 | ||||
| -rw-r--r-- | src/test/run-fail/vec-underrun.rs | 4 |
5 files changed, 8 insertions, 8 deletions
diff --git a/src/test/run-fail/fail.rs b/src/test/run-fail/fail.rs index c688a404..e8c9cf71 100644 --- a/src/test/run-fail/fail.rs +++ b/src/test/run-fail/fail.rs @@ -2,5 +2,5 @@ // error-pattern:1 == 2 fn main() { - assert (1 == 2); + check (1 == 2); } diff --git a/src/test/run-fail/linked-failure.rs b/src/test/run-fail/linked-failure.rs index 60e82200..7def7c11 100644 --- a/src/test/run-fail/linked-failure.rs +++ b/src/test/run-fail/linked-failure.rs @@ -4,7 +4,7 @@ // error-pattern:1 == 2 fn child() { - assert (1 == 2); + check (1 == 2); } fn main() { diff --git a/src/test/run-fail/str-overrun.rs b/src/test/run-fail/str-overrun.rs index 68b1e263..4388cb3a 100644 --- a/src/test/run-fail/str-overrun.rs +++ b/src/test/run-fail/str-overrun.rs @@ -6,12 +6,12 @@ fn main() { let str s = "hello"; let int x = 0; - assert (s.(x) == (0x68 as u8)); + check (s.(x) == (0x68 as u8)); // NB: at the moment a string always has a trailing NULL, // so the largest index value on the string above is 5, not // 4. Possibly change this. // Bounds-check failure. - assert (s.(x + 6) == (0x0 as u8)); + check (s.(x + 6) == (0x0 as u8)); } diff --git a/src/test/run-fail/vec-overrun.rs b/src/test/run-fail/vec-overrun.rs index 810feb39..961da730 100644 --- a/src/test/run-fail/vec-overrun.rs +++ b/src/test/run-fail/vec-overrun.rs @@ -6,7 +6,7 @@ fn main() { let vec[int] v = vec(10); let int x = 0; - assert (v.(x) == 10); + check (v.(x) == 10); // Bounds-check failure. - assert (v.(x + 2) == 20); + check (v.(x + 2) == 20); } diff --git a/src/test/run-fail/vec-underrun.rs b/src/test/run-fail/vec-underrun.rs index f1998da5..a230d1be 100644 --- a/src/test/run-fail/vec-underrun.rs +++ b/src/test/run-fail/vec-underrun.rs @@ -6,7 +6,7 @@ fn main() { let vec[int] v = vec(10, 20); let int x = 0; - assert (v.(x) == 10); + check (v.(x) == 10); // Bounds-check failure. - assert (v.(x-1) == 20); + check (v.(x-1) == 20); } |