diff options
author | Dominick Allen <djallen@librehumanitas.org> | 2025-03-31 08:33:08 -0500 |
---|---|---|
committer | Dominick Allen <djallen@librehumanitas.org> | 2025-03-31 08:33:08 -0500 |
commit | 8b0bc70db73b48d833a3b5791e55921768cf6932 (patch) | |
tree | 862ae34933a7fc9f480038d974f59d7683a82605 /include/fud_format.hpp | |
parent | c426110f24516f92ecb8a5374e2a281f2c79787a (diff) |
Remove reinterpret_cast usage in favor of std::bit_cast.
Diffstat (limited to 'include/fud_format.hpp')
-rw-r--r-- | include/fud_format.hpp | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/include/fud_format.hpp b/include/fud_format.hpp index 0dff3c1..4536d69 100644 --- a/include/fud_format.hpp +++ b/include/fud_format.hpp @@ -1396,8 +1396,7 @@ FormatResult format(Sink& sink, FormatCharMode formatMode, const FormatSpec& for template <typename Sink> FormatResult format(Sink& sink, FormatCharMode formatMode, const FormatSpec& formatSpec, const utf8* arg) { - // NOLINTNEXTLINE(cppcoreguidelines-pro-type-reinterpret-cast) - return format(sink, formatMode, formatSpec, reinterpret_cast<const char*>(arg)); + return format(sink, formatMode, formatSpec, std::bit_cast<const char*>(arg)); } template <typename Sink> @@ -1493,8 +1492,7 @@ FormatResult format(Sink& sink, FormatCharMode formatMode, const FormatSpec& for return DrainResult{0, FudStatus::FormatInvalid}; } pointerFormatSpec.alternateForm = true; - // NOLINTNEXTLINE(cppcoreguidelines-pro-type-reinterpret-cast) - return impl::formatIntegral(sink, formatMode, pointerFormatSpec, reinterpret_cast<uintptr_t>(arg)); + return impl::formatIntegral(sink, formatMode, pointerFormatSpec, std::bit_cast<uintptr_t>(arg)); } template <typename Sink> |