Cargo build: print cause build failure?


I saw many times when cargo build -v -v failed, while cargo build work without problems.

For example if you use iron that depend on typemap, with cargo build -v -v you will see:

error: defaults for type parameters are only allowed in `struct`, `enum`, `type`, or `trait` definitions., #[deny(invalid_type_param_default)] on by default
   --> /home/evgeniy/.cargo/registry/src/
185 | impl<'a, K: Key, A: ?Sized + UnsafeAnyExt + 'a = UnsafeAny> Entry<'a, K, A> {
    |                  ^

Or for example if you use syntex library, with cargo build -v -v you will see:

error: unused `#[macro_use]` import
  --> /home/evgeniy/.cargo/registry/src/
22 | #[macro_use]
   | ^^^^^^^^^^^^

error: aborting due to 2 previous errors

So is cargo build -v -v not only make output more verbose, but turn on something like "error on warning mode?


My team ran into the same problem this past week as well. I spent a few hours narrowing down the problem. It’s definitely specific to -vv.

Unfortunately our code is private so I’m going to have to reproduce it an example codebase to file a bug. It’s on my todo list for this week if no one else has filed it (I haven’t checked yet).


I create the but report