LCOV - code coverage report
Current view: top level - src/AH/Math - MinMaxFix.hpp (source / functions) Coverage Total Hit
Test: 73449d9b107c772cf65493691543348214e5d5eb Lines: 100.0 % 4 4
Test Date: 2026-06-06 17:44:35 Functions: 100.0 % 2 2
Legend: Lines:     hit not hit

            Line data    Source code
       1              : #pragma once
       2              : 
       3              : #include <AH/Math/FixArduinoMacros.hpp>
       4              : 
       5              : #include <AH/Settings/NamespaceSettings.hpp>
       6              : 
       7              : BEGIN_AH_NAMESPACE
       8              : 
       9              : /// Return the smaller of two numbers/objects.
      10              : /// @ingroup    AH_Math
      11              : template <class T, class U>
      12      1000003 : constexpr auto min(const T &a, const U &b) -> decltype(b < a ? b : a) {
      13      1000003 :     return b < a ? b : a;
      14              : }
      15              : 
      16              : /// Return the larger of two numbers/objects.
      17              : /// @ingroup    AH_Math
      18              : template <class T, class U>
      19         5240 : constexpr auto max(const T &a, const U &b) -> decltype(a < b ? b : a) {
      20         5240 :     return a < b ? b : a;
      21              : }
      22              : 
      23              : END_AH_NAMESPACE
        

Generated by: LCOV version 2.4-beta