syntax/rustc: implement isize/usize
This commit is contained in:
parent
6539cb417f
commit
abcbe27695
22 changed files with 81 additions and 78 deletions
|
|
@ -8,8 +8,8 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
// error-pattern:assertion failed: 1i == 2
|
||||
// error-pattern:assertion failed: 1is == 2
|
||||
|
||||
fn main() {
|
||||
assert!(1i == 2);
|
||||
assert!(1is == 2);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -8,8 +8,5 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
|
||||
|
||||
|
||||
// error-pattern:1i == 2
|
||||
fn main() { assert!((1i == 2)); }
|
||||
// error-pattern:1is == 2
|
||||
fn main() { assert!((1is == 2)); }
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@ struct Foo<T> {
|
|||
|
||||
pub fn main() {
|
||||
unsafe {
|
||||
assert_eq!((*get_tydesc::<int>()).name, "int");
|
||||
assert_eq!((*get_tydesc::<Foo<uint>>()).name, "Foo<uint>");
|
||||
assert_eq!((*get_tydesc::<int>()).name, "isize");
|
||||
assert_eq!((*get_tydesc::<Foo<uint>>()).name, "Foo<usize>");
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue