Skip to content

Commit b211acf

Browse files
committed
Re-blessed the partial_eq.rs coverage test
1 parent 625803d commit b211acf

File tree

2 files changed

+5
-35
lines changed

2 files changed

+5
-35
lines changed

src/test/run-make-fulldeps/coverage-reports/expected_show_coverage.partial_eq.txt

+3-18
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,11 @@
22
2| |// structure of this test.
33
3| |
44
4| 2|#[derive(Clone, Debug, PartialEq, Eq, PartialOrd, Ord)]
5-
^0 ^0 ^0 ^0 ^1 ^0 ^0^0
5+
^0 ^0 ^0 ^0 ^1 ^1 ^0^0
66
5| |pub struct Version {
77
6| | major: usize,
8-
7| 1| minor: usize, // Count: 1 - `PartialOrd` compared `minor` values in 3.2.1 vs. 3.3.0
9-
8| 0| patch: usize, // Count: 0 - `PartialOrd` was determined by `minor` (2 < 3)
8+
7| | minor: usize,
9+
8| | patch: usize,
1010
9| |}
1111
10| |
1212
11| |impl Version {
@@ -45,19 +45,4 @@
4545
44| |`function_source_hash` without a code region, if necessary.
4646
45| |
4747
46| |*/
48-
47| |
49-
48| |// FIXME(#79626): The derived traits get coverage, which is great, but some of the traits appear
50-
49| |// to get two coverage execution counts at different positions:
51-
50| |//
52-
51| |// ```text
53-
52| |// 4| 2|#[derive(Clone, Debug, PartialEq, Eq, PartialOrd, Ord)]
54-
53| |// ^0 ^0 ^0 ^0 ^1 ^0 ^0^0
55-
54| |// ```text
56-
55| |//
57-
56| |// `PartialEq`, `PartialOrd`, and `Ord` (and possibly `Eq`, if the trait name was longer than 2
58-
57| |// characters) have counts at their first and last characters.
59-
58| |//
60-
59| |// Why is this? Why does `PartialOrd` have two values (1 and 0)? This must mean we are checking
61-
60| |// distinct coverages, so maybe we don't want to eliminate one of them. Should we merge them?
62-
61| |// If merged, do we lose some information?
6348

src/test/run-make-fulldeps/coverage/partial_eq.rs

+2-17
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@
44
#[derive(Clone, Debug, PartialEq, Eq, PartialOrd, Ord)]
55
pub struct Version {
66
major: usize,
7-
minor: usize, // Count: 1 - `PartialOrd` compared `minor` values in 3.2.1 vs. 3.3.0
8-
patch: usize, // Count: 0 - `PartialOrd` was determined by `minor` (2 < 3)
7+
minor: usize,
8+
patch: usize,
99
}
1010

1111
impl Version {
@@ -44,18 +44,3 @@ one expression, which is allowed, but the `function_source_hash` was only passed
4444
`function_source_hash` without a code region, if necessary.
4545
4646
*/
47-
48-
// FIXME(#79626): The derived traits get coverage, which is great, but some of the traits appear
49-
// to get two coverage execution counts at different positions:
50-
//
51-
// ```text
52-
// 4| 2|#[derive(Clone, Debug, PartialEq, Eq, PartialOrd, Ord)]
53-
// ^0 ^0 ^0 ^0 ^1 ^0 ^0^0
54-
// ```text
55-
//
56-
// `PartialEq`, `PartialOrd`, and `Ord` (and possibly `Eq`, if the trait name was longer than 2
57-
// characters) have counts at their first and last characters.
58-
//
59-
// Why is this? Why does `PartialOrd` have two values (1 and 0)? This must mean we are checking
60-
// distinct coverages, so maybe we don't want to eliminate one of them. Should we merge them?
61-
// If merged, do we lose some information?

0 commit comments

Comments
 (0)