Closed
Description
Consider this code:
struct Foo;
fn main() {
println!("{:?} {:?}",
/* 1 */ Foo,
/* 2 */ std::fs::OpenOptions::new());
}
Both marked lines print the error that Debug
is not satisfied and note that "if it is defined in your crate, add #[derive(Debug)]
or manually implement it". The compiler should be able to check and issue the note only for (1), instead of printing the confusing "if it is defined in your crate".