diff options
| author | Gloria Mundi <gloria@gloria-mundi.eu> | 2025-11-19 02:20:56 +0100 |
|---|---|---|
| committer | Gloria Mundi <gloria@gloria-mundi.eu> | 2025-11-19 02:20:56 +0100 |
| commit | 17232918b51d27500af905dc3d3d82cd43d6ddf5 (patch) | |
| tree | 1c5d52f03eead415cc53317008032fe84238c187 /test/util.h | |
| parent | bf4eda36d4c13be468236bf33baa2574e8692ca7 (diff) | |
| parent | cdeded176c18240579168ee8461c5101abb47e78 (diff) | |
merge mzuenni
Diffstat (limited to 'test/util.h')
| -rw-r--r-- | test/util.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/test/util.h b/test/util.h index e0d9b57..880ff04 100644 --- a/test/util.h +++ b/test/util.h @@ -1,6 +1,12 @@ #include <bits/stdc++.h> using namespace std; +#ifdef SANITIZE + constexpr bool sanitize = true; +#else + constexpr bool sanitize = false; +#endif + using ll = long long; using lll = __int128; using ld = long double; @@ -10,6 +16,7 @@ namespace INT {constexpr int INF = 0x3FFF'FFFF;} namespace LL {constexpr ll INF = 0x3FFF'FFFF'FFFF'FFFFll;} namespace LD {constexpr ld INF = numeric_limits<ld>::infinity();} +#ifdef SANITIZE template<typename T> T _lg_check(T n) { assert(n > 0); @@ -17,6 +24,7 @@ T _lg_check(T n) { } #define __lg _lg_check +#endif namespace details { template<typename T = ll> |
