Merge pull request #1305 from matthiasbeyer/libimagerror/writeln-fix
Use writeln!() instead of write!()
This commit is contained in:
commit
944b81195b
1 changed files with 2 additions and 2 deletions
|
@ -36,10 +36,10 @@ impl<'a, T> Display for ImagTrace<'a, T>
|
||||||
where T: ChainedError
|
where T: ChainedError
|
||||||
{
|
{
|
||||||
fn fmt(&self, fmt: &mut Formatter) -> FmtResult {
|
fn fmt(&self, fmt: &mut Formatter) -> FmtResult {
|
||||||
try!(write!(fmt, "{}: {}", Red.blink().paint("ERROR[ 0]"), self.0));
|
try!(writeln!(fmt, "{}: {}", Red.blink().paint("ERROR[ 0]"), self.0));
|
||||||
|
|
||||||
for (i, e) in self.0.iter().enumerate().skip(1) {
|
for (i, e) in self.0.iter().enumerate().skip(1) {
|
||||||
try!(write!(fmt, "{}: {}", Red.blink().paint(format!("ERROR[{:>4}]", i)), e));
|
try!(writeln!(fmt, "{}: {}", Red.blink().paint(format!("ERROR[{:>4}]", i)), e));
|
||||||
}
|
}
|
||||||
|
|
||||||
if let Some(backtrace) = self.0.backtrace() {
|
if let Some(backtrace) = self.0.backtrace() {
|
||||||
|
|
Loading…
Reference in a new issue