From 52c021ee0b0c6ad2128ed550c694aad0d11d4c3f Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sun, 21 Apr 2024 16:53:22 +0200 Subject: Adding upstream version 2.5.7. Signed-off-by: Daniel Baumann --- src/lib/util/bigints.h | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 src/lib/util/bigints.h (limited to 'src/lib/util/bigints.h') diff --git a/src/lib/util/bigints.h b/src/lib/util/bigints.h new file mode 100644 index 0000000..065a2bc --- /dev/null +++ b/src/lib/util/bigints.h @@ -0,0 +1,26 @@ +// Copyright (C) 2023 Internet Systems Consortium, Inc. ("ISC") +// +// This Source Code Form is subject to the terms of the Mozilla Public +// License, v. 2.0. If a copy of the MPL was not distributed with this +// file, You can obtain one at http://mozilla.org/MPL/2.0/. + +// This file provides an interface towards bigint implementations. +// Currently, it uses the ones from boost::multiprecision, but if we ever want +// to swap it out, or implement our own, we can seamlessly do it in this header. + +#ifndef UTIL_BIGINTS_H +#define UTIL_BIGINTS_H + +#include + +namespace isc { +namespace util { + +using int128_t = boost::multiprecision::checked_int128_t; + +using uint128_t = boost::multiprecision::checked_uint128_t; + +} // namespace util +} // namespace isc + +#endif // UTIL_BIGINTS_H \ No newline at end of file -- cgit v1.2.3