Delete imports that are already in the prelude

`Vec` and `String` are in the prelude, so qualifying them with
`vec::Vec` and `string::String` is unnecessary.
This commit is contained in:
rrokkam 2020-07-19 12:35:37 -07:00
parent a699803ce7
commit 2a53bf5db5
2 changed files with 6 additions and 7 deletions

4
rust/Cargo.lock generated
View File

@ -1,4 +1,6 @@
[root] # This file is automatically @generated by Cargo.
# It is not intended for manual editing.
[[package]]
name = "rust" name = "rust"
version = "0.1.0" version = "0.1.0"

View File

@ -1,8 +1,5 @@
use std::string;
use std::vec;
pub struct Item { pub struct Item {
pub name: string::String, pub name: String,
pub sell_in: i32, pub sell_in: i32,
pub quality: i32, pub quality: i32,
} }
@ -18,11 +15,11 @@ impl Item {
} }
pub struct GildedRose { pub struct GildedRose {
pub items: vec::Vec<Item>, pub items: Vec<Item>,
} }
impl GildedRose { impl GildedRose {
pub fn new(items: vec::Vec<Item>) -> GildedRose { pub fn new(items: Vec<Item>) -> GildedRose {
GildedRose { items: items } GildedRose { items: items }
} }