1
Fork 0
rust/tests/ui/tydesc-name.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

15 lines
225 B
Rust
Raw Normal View History

//@ run-pass
#![allow(dead_code)]
use std::any::type_name;
2013-09-03 18:22:11 -04:00
struct Foo<T> {
x: T
}
pub fn main() {
assert_eq!(type_name::<isize>(), "isize");
assert_eq!(type_name::<Foo<usize>>(), "tydesc_name::Foo<usize>");
2013-09-03 18:22:11 -04:00
}