Fix typo
This commit is contained in:
parent
850fc6a479
commit
6f288ea337
1 changed files with 1 additions and 1 deletions
|
@ -2169,7 +2169,7 @@ impl<T: fmt::Display + ?Sized> ToString for T {
|
||||||
use core::fmt::Write;
|
use core::fmt::Write;
|
||||||
let mut buf = String::new();
|
let mut buf = String::new();
|
||||||
buf.write_fmt(format_args!("{}", self))
|
buf.write_fmt(format_args!("{}", self))
|
||||||
.expect("a Display implementation return an error unexpectedly");
|
.expect("a Display implementation returned an error unexpectedly");
|
||||||
buf.shrink_to_fit();
|
buf.shrink_to_fit();
|
||||||
buf
|
buf
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue