coverage: Tweak individual tests to be unaffected by rustfmt
Some of these tests use non-standard formatting that we can simulate by strategically adding `//` line comments. One contains `where` clauses that would be split across multiple lines, which we can keep on one line by moving the bounds to the generic type instead.
This commit is contained in:
parent
f1494425bb
commit
1f9353ae2c
11 changed files with 57 additions and 45 deletions
|
@ -1,18 +1,18 @@
|
|||
#![allow(unused_assignments)]
|
||||
// failure-status: 1
|
||||
|
||||
struct Firework<T> where T: Copy + std::fmt::Display {
|
||||
struct Firework<T: Copy + std::fmt::Display> {
|
||||
strength: T,
|
||||
}
|
||||
|
||||
impl<T> Firework<T> where T: Copy + std::fmt::Display {
|
||||
impl<T: Copy + std::fmt::Display> Firework<T> {
|
||||
#[inline(always)]
|
||||
fn set_strength(&mut self, new_strength: T) {
|
||||
self.strength = new_strength;
|
||||
}
|
||||
}
|
||||
|
||||
impl<T> Drop for Firework<T> where T: Copy + std::fmt::Display {
|
||||
impl<T: Copy + std::fmt::Display> Drop for Firework<T> {
|
||||
#[inline(always)]
|
||||
fn drop(&mut self) {
|
||||
println!("BOOM times {}!!!", self.strength);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue