Move tests to library/core/tests

This commit is contained in:
Albin Hedman 2021-08-09 22:44:01 +02:00
parent aaf902bf8f
commit 3051bb9c81
No known key found for this signature in database
GPG key ID: 1F501ECD1BBD70A7
2 changed files with 5 additions and 7 deletions

View file

@ -1,20 +0,0 @@
// run-pass
#![feature(const_trait_impl)]
#![feature(const_identity_convert)]
fn main() {
const fn from(x: i32) -> i32 {
i32::from(x)
}
const FOO: i32 = from(42);
assert_eq!(FOO, 42);
const fn into(x: Vec<String>) -> Vec<String> {
x.into()
}
const BAR: Vec<String> = into(Vec::new());
assert_eq!(BAR, Vec::<String>::new());
}