Skip to content

Instantly share code, notes, and snippets.

@steveklabnik
Created December 20, 2014 13:39
Show Gist options
  • Select an option

  • Save steveklabnik/600204773f074b18c81f to your computer and use it in GitHub Desktop.

Select an option

Save steveklabnik/600204773f074b18c81f to your computer and use it in GitHub Desktop.
<std macros>:3:22: 3:40 error: mismatched types: expected `error::Error`, found `collections::string::String` (expected trait error::Error, found struct collections::string::String)
<std macros>:3 format_args!(::std::fmt::format, $($arg)*)
^~~~~~~~~~~~~~~~~~
note: in expansion of format_args!
<std macros>:3:9: 3:51 note: expansion site
<std macros>:1:1: 5:2 note: in expansion of format!
/home/steve/src/rust-book/src/build.rs:113:36: 116:34 note: expansion site
/home/steve/src/rust-book/src/build.rs:113:32: 116:45 error: the trait `core::kinds::Sized` is not implemented for the type `error::Error`
/home/steve/src/rust-book/src/build.rs:113 return Err(box format!("{}\n{}",
/home/steve/src/rust-book/src/build.rs:114 String::from_utf8_lossy(output.output[]),
/home/steve/src/rust-book/src/build.rs:115 String::from_utf8_lossy(output.error[]))
/home/steve/src/rust-book/src/build.rs:116 as Box<Error>);
/home/steve/src/rust-book/src/build.rs:113:32: 116:45 note: only sized types can be made into objects
/home/steve/src/rust-book/src/build.rs:113 return Err(box format!("{}\n{}",
/home/steve/src/rust-book/src/build.rs:114 String::from_utf8_lossy(output.output[]),
/home/steve/src/rust-book/src/build.rs:115 String::from_utf8_lossy(output.error[]))
/home/steve/src/rust-book/src/build.rs:116 as Box<Error>);
/home/steve/src/rust-book/src/build.rs:113:32: 116:45 error: the trait `error::Error` is not implemented for the type `error::Error`
/home/steve/src/rust-book/src/build.rs:113 return Err(box format!("{}\n{}",
/home/steve/src/rust-book/src/build.rs:114 String::from_utf8_lossy(output.output[]),
/home/steve/src/rust-book/src/build.rs:115 String::from_utf8_lossy(output.error[]))
/home/steve/src/rust-book/src/build.rs:116 as Box<Error>);
/home/steve/src/rust-book/src/build.rs:113:32: 116:45 note: required for the cast to the object type `error::Error`
/home/steve/src/rust-book/src/build.rs:113 return Err(box format!("{}\n{}",
/home/steve/src/rust-book/src/build.rs:114 String::from_utf8_lossy(output.output[]),
/home/steve/src/rust-book/src/build.rs:115 String::from_utf8_lossy(output.error[]))
/home/steve/src/rust-book/src/build.rs:116 as Box<Error>);
<std macros>:3:22: 3:40 error: mismatched types: expected `error::Error`, found `collections::string::String` (expected trait error::Error, found struct collections::string::String)
<std macros>:3 format_args!(::std::fmt::format, $($arg)*)
^~~~~~~~~~~~~~~~~~
note: in expansion of format_args!
<std macros>:3:9: 3:51 note: expansion site
<std macros>:1:1: 5:2 note: in expansion of format!
/home/steve/src/rust-book/src/build.rs:120:32: 120:80 note: expansion site
/home/steve/src/rust-book/src/build.rs:120:28: 120:91 error: the trait `core::kinds::Sized` is not implemented for the type `error::Error`
/home/steve/src/rust-book/src/build.rs:120 return Err(box format!("Could not execute `rustdoc`: {}", e) as Box<Error>);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/home/steve/src/rust-book/src/build.rs:120:28: 120:91 note: only sized types can be made into objects
/home/steve/src/rust-book/src/build.rs:120 return Err(box format!("Could not execute `rustdoc`: {}", e) as Box<Error>);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/home/steve/src/rust-book/src/build.rs:120:28: 120:91 error: the trait `error::Error` is not implemented for the type `error::Error`
/home/steve/src/rust-book/src/build.rs:120 return Err(box format!("Could not execute `rustdoc`: {}", e) as Box<Error>);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/home/steve/src/rust-book/src/build.rs:120:28: 120:91 note: required for the cast to the object type `error::Error`
/home/steve/src/rust-book/src/build.rs:120 return Err(box format!("Could not execute `rustdoc`: {}", e) as Box<Error>);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
error: aborting due to 6 previous errors
Could not compile `rustbook`.
To learn more, run the command again with --verbose.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment