1 # Check that the coverage statistics for template functions are calculated as expected.
6 RUN: cp %p/Inputs/tmpl* .
8 RUN: llvm-cov gcov tmpl.cpp -f | FileCheck %s --check-prefix=F
9 RUN: llvm-cov gcov tmpl.cpp -t | FileCheck %s --check-prefix=T
11 F: Function '_Z4testILi1EEiv'
12 F-NEXT: Lines executed:100.00% of 1
13 F: Function '_Z4testILi2EEiv'
14 F-NEXT: Lines executed:100.00% of 1
16 T: -: 1:template <int N>
17 T-NEXT: 2: 2:int test() { return N; }
19 T-NEXT: 1: 4:int main() { return test<1>() + test<2>(); }