From 29a5f34fe06e42de335a64ab02830635da8253ce Mon Sep 17 00:00:00 2001 From: Anders Dalvander Date: Fri, 9 Feb 2024 10:08:46 +0100 Subject: [PATCH] C++23 compatibility: basic_string_view cannot be constructed from nullptr --- include/fmt/base.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/include/fmt/base.h b/include/fmt/base.h index f21aeb78942a..56d5c9090d94 100644 --- a/include/fmt/base.h +++ b/include/fmt/base.h @@ -487,6 +487,8 @@ template class basic_string_view { constexpr basic_string_view(const Char* s, size_t count) noexcept : data_(s), size_(count) {} + constexpr basic_string_view(std::nullptr_t) = delete; + /** Constructs a string reference object from a C string. */