You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
enumE{A,B(i32),}pubfnfoo(i:i32) -> i32{let e = if i == 0{E::A}else{E::B(i)};match e {E::A => 1,E::B(x) => x,}}#[cfg(test)]mod tests {#[test]fnit_works(){usecrate::foo;assert_eq!(foo(0),1);assert_eq!(foo(2),2);}}
I get a false positive for an uncovered line 7 (match e).
impl fmt::DisplayforDateError{fnfmt(&self,f:&mut fmt::Formatter<'_>) -> fmt::Result{match*self{Self::InvalidMonth => write!(f,"invalid month"),Self::InvalidDay => write!(f,"invalid day of the month"),}}}
The match *self { is shown as not covered.
Anything we can do on our side to help you pinpoint/fix the issue? 🙂
For this code
I get a false positive for an uncovered line 7 (
match e
).The text was updated successfully, but these errors were encountered: