The hack that I've seen people use the most is to write a line like this:
() = foo;
Then rustc will print out an error that includes the type of `foo`. () = foo;
Then rustc will print out an error that includes the type of `foo`.Personally, I use the technique a lot for debugging template errors in the language.
template<typename T> struct TD;
Instantiate this as ‘TD<decltype(foo)>’ to get the full name of the type.
Rust’s does seem more concise.