mirror of
				https://github.com/rust-lang/rust.git
				synced 2025-10-31 04:57:19 +00:00 
			
		
		
		
	 87c2f9a5be
			
		
	
	
		87c2f9a5be
		
	
	
	
	
		
			
			This reverts commit 1d35638dc38dbfbf1cc2a9823135dfcf3c650169, reversing changes made to f23a80a4c2fbca593b64e70f5970368824b4c5e9.
		
			
				
	
	
		
			42 lines
		
	
	
		
			1.2 KiB
		
	
	
	
		
			Plaintext
		
	
	
	
	
	
			
		
		
	
	
			42 lines
		
	
	
		
			1.2 KiB
		
	
	
	
		
			Plaintext
		
	
	
	
	
	
|    LL|       |#![feature(coverage_attribute)]
 | |
|    LL|       |//@ edition: 2021
 | |
|    LL|       |//@ min-llvm-version: 19
 | |
|    LL|       |//@ compile-flags: -Zcoverage-options=mcdc -Copt-level=z -Cllvm-args=--inline-threshold=0
 | |
|    LL|       |//@ llvm-cov-flags: --show-branches=count --show-mcdc
 | |
|    LL|       |
 | |
|    LL|       |#[inline(always)]
 | |
|    LL|      3|fn inlined_instance(a: bool, b: bool) -> bool {
 | |
|    LL|      3|    a && b
 | |
|                        ^2
 | |
|   ------------------
 | |
|   |  Branch (LL:5): [True: 2, False: 1]
 | |
|   |  Branch (LL:10): [True: 1, False: 1]
 | |
|   ------------------
 | |
|   |---> MC/DC Decision Region (LL:5) to (LL:11)
 | |
|   |
 | |
|   |  Number of Conditions: 2
 | |
|   |     Condition C1 --> (LL:5)
 | |
|   |     Condition C2 --> (LL:10)
 | |
|   |
 | |
|   |  Executed MC/DC Test Vectors:
 | |
|   |
 | |
|   |     C1, C2    Result
 | |
|   |  1 { F,  -  = F      }
 | |
|   |  2 { T,  F  = F      }
 | |
|   |  3 { T,  T  = T      }
 | |
|   |
 | |
|   |  C1-Pair: covered: (1,3)
 | |
|   |  C2-Pair: covered: (2,3)
 | |
|   |  MC/DC Coverage for Decision: 100.00%
 | |
|   |
 | |
|   ------------------
 | |
|    LL|      3|}
 | |
|    LL|       |
 | |
|    LL|       |#[coverage(off)]
 | |
|    LL|       |fn main() {
 | |
|    LL|       |    let _ = inlined_instance(true, false);
 | |
|    LL|       |    let _ = inlined_instance(false, true);
 | |
|    LL|       |    let _ = inlined_instance(true, true);
 | |
|    LL|       |}
 | |
| 
 |