MCPcopy Create free account
hub / github.com/apache/trafficserver / marginComparison

Function marginComparison

lib/catch2/catch.hpp:7869–7871  ·  view source on GitHub ↗

Performs equivalent check of std::fabs(lhs - rhs) <= margin But without the subtraction to allow for INFINITY in comparison

Source from the content-addressed store, hash-verified

7867// Performs equivalent check of std::fabs(lhs - rhs) <= margin
7868// But without the subtraction to allow for INFINITY in comparison
7869bool marginComparison(double lhs, double rhs, double margin) {
7870 return (lhs + margin >= rhs) && (rhs + margin >= lhs);
7871}
7872
7873}
7874

Callers 2

matchMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected