llvm-for-llvmta/test/tools/llvm-cov/Inputs/multithreaded_report/pow.h

12 lines
111 B
C
Raw Permalink Normal View History

2022-04-25 10:02:23 +02:00
template<typename T>
T pow(T b, T p) {
if (!p)
return 1;
while (--p) {
b *= b;
}
return b;
}