Use statements



examples/other/use-statements/src/main.rs
// Use one-by-one

//#[allow(unused_imports)]
//use std::io::Read;
//#[allow(unused_imports)]
//use std::io::Write;
#[allow(unused_imports)]
use std::fs::File;
#[allow(unused_imports)]
use std::io;

// Combine two
//#[allow(unused_imports)]
//use std::io::{Read, Write};

// Combine crate and function
//#[allow(unused_imports)]
//use std::io::{self, Write};

// Combine several, unrelated
//#[allow(unused_imports)]
//use {
//    std::io::Read,
//    std::io::Write,
//    std::fs::File,
//    std::io,
//};

fn main() {
    println!("Hello, world!");
}