1
0
Fork 0

fix 80col breaches

This commit is contained in:
dtb 2023-10-31 23:00:08 -06:00
parent 6ad17fef83
commit ba05e57b72
1 changed files with 6 additions and 3 deletions

View File

@ -2203,11 +2203,13 @@ For more information about this error, try `rustc --explain E0412`.
Okay.
$ sed -e '1a use std::ffi::OsString' <echo.rs >echo.2.rs
$ rustc echo.2.rs
error[E0277]: a value of type `Vec<OsString>` cannot be built from an iterator over elements of type `String`
error[E0277]: a value of type `Vec<OsString>` cannot be built from an iterator
over elements of type `String`
--> echo.rs:5:43
|
5 | let args: Vec<OsString> = env::args().collect();
| ^^^^^^^ value of type `Vec<OsString>` cannot be built from `std::iter::Iterator<Item=String>`
| ^^^^^^^ value of type `Vec<OsStri
ng>` cannot be built from `std::iter::Iterator<Item=String>`
|
= help: the trait `FromIterator<String>` is not implemented for `Vec<OsString>`
= help: the trait `FromIterator<T>` is implemented for `Vec<T>`
@ -2225,7 +2227,8 @@ error[E0425]: cannot find function `os_args` in module `env`
--> echo.rs:5:36
|
5 | let args: Vec<OsString> = env::os_args().collect();
| ^^^^^^^ help: a function with a similar name exists: `args_os`
| ^^^^^^^ help: a function with a similar
name exists: `args_os`
--> /builddir/rust-1.73.0/library/std/src/env.rs:793:1
|
= note: similarly named function `args_os` defined here