MCPcopy Create free account
hub / github.com/catchorg/Catch2 / CommutativeMultCheck

Function CommutativeMultCheck

tests/SelfTest/IntrospectiveTests/Integer.tests.cpp:15–23  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

13namespace {
14 template <typename Int>
15 static void
16 CommutativeMultCheck( Int a, Int b, Int upper_result, Int lower_result ) {
17 using Catch::Detail::extendedMult;
18 using Catch::Detail::ExtendedMultResult;
19 CHECK( extendedMult( a, b ) ==
20 ExtendedMultResult<Int>{ upper_result, lower_result } );
21 CHECK( extendedMult( b, a ) ==
22 ExtendedMultResult<Int>{ upper_result, lower_result } );
23 }
24
25 // Simple (and slow) implementation of extended multiplication for tests
26 constexpr Catch::Detail::ExtendedMultResult<std::uint64_t>

Callers

nothing calls this directly

Calls 1

extendedMultFunction · 0.50

Tested by

no test coverage detected