fn a<T: Send + 'static>(v: T) {
std::panic::panic_any(v); //~ WARN panic message is not a string literal
+ assert!(false, v); //~ WARN panic message is not a string literal
}
fn b<T: std::fmt::Debug + Send + 'static>(v: T) {
std::panic::panic_any(v); //~ WARN panic message is not a string literal
+ assert!(false, "{:?}", v); //~ WARN panic message is not a string literal
}
fn c<T: std::fmt::Display + Send + 'static>(v: T) {
std::panic::panic_any(v); //~ WARN panic message is not a string literal
+ assert!(false, "{}", v); //~ WARN panic message is not a string literal
}
fn d<T: std::fmt::Display + std::fmt::Debug + Send + 'static>(v: T) {
std::panic::panic_any(v); //~ WARN panic message is not a string literal
+ assert!(false, "{}", v); //~ WARN panic message is not a string literal
}