diff --git a/include/gsl/string_span b/include/gsl/string_span index b210d75..4064c5e 100644 --- a/include/gsl/string_span +++ b/include/gsl/string_span @@ -57,36 +57,36 @@ namespace gsl // template -using basic_zstring [[deprecated]] = CharT*; +using basic_zstring [[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]] = CharT*; template -using czstring [[deprecated]] = basic_zstring; +using czstring [[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]] = basic_zstring; template -using cwzstring [[deprecated]] = basic_zstring; +using cwzstring [[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]] = basic_zstring; template -using cu16zstring [[deprecated]] = basic_zstring; +using cu16zstring [[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]] = basic_zstring; template -using cu32zstring [[deprecated]] = basic_zstring; +using cu32zstring [[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]] = basic_zstring; template -using zstring [[deprecated]] = basic_zstring; +using zstring [[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]] = basic_zstring; template -using wzstring [[deprecated]] = basic_zstring; +using wzstring [[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]] = basic_zstring; template -using u16zstring [[deprecated]] = basic_zstring; +using u16zstring [[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]] = basic_zstring; template -using u32zstring [[deprecated]] = basic_zstring; +using u32zstring [[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]] = basic_zstring; namespace details { template - [[deprecated]] constexpr std::size_t string_length(const CharT* str, std::size_t n) + [[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]] constexpr std::size_t string_length(const CharT* str, std::size_t n) { if (str == nullptr || n == dynamic_extent) return 0; @@ -108,7 +108,7 @@ namespace details // Will fail-fast if sentinel cannot be found before max elements are examined. // template -[[deprecated]]constexpr span ensure_sentinel(T* seq, +[[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]]constexpr span ensure_sentinel(T* seq, std::size_t max = static_cast(-1)) { Ensures(seq != nullptr); @@ -129,7 +129,7 @@ template // Will fail fast if a null-terminator cannot be found before the limit of size_type. // template -[[deprecated]] constexpr span ensure_z(CharT* const& sz, +[[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]] constexpr span ensure_z(CharT* const& sz, std::size_t max = static_cast(-1)) { return ensure_sentinel(sz, max); @@ -142,28 +142,28 @@ constexpr span ensure_z(CharT (&sz)[N]) } template -[[deprecated]] constexpr span::type, dynamic_extent> ensure_z(Cont& cont) +[[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]] constexpr span::type, dynamic_extent> ensure_z(Cont& cont) { return ensure_z(cont.data(), cont.size()); } template -class [[deprecated]] basic_string_span; +class [[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]] basic_string_span; namespace details { template - struct [[deprecated]] is_basic_string_span_oracle : std::false_type + struct [[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]] is_basic_string_span_oracle : std::false_type { }; template - struct [[deprecated]] is_basic_string_span_oracle> : std::true_type + struct [[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]] is_basic_string_span_oracle> : std::true_type { }; template - struct [[deprecated]] is_basic_string_span : is_basic_string_span_oracle> + struct [[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]] is_basic_string_span : is_basic_string_span_oracle> { }; } // namespace details @@ -172,7 +172,7 @@ namespace details // string_span and relatives // template -class [[deprecated]] basic_string_span +class [[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]] basic_string_span { public: using element_type = CharT; @@ -319,28 +319,28 @@ private: }; template -using string_span [[deprecated]] = basic_string_span; +using string_span [[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]] = basic_string_span; template -using cstring_span [[deprecated]] = basic_string_span; +using cstring_span [[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]] = basic_string_span; template -using wstring_span [[deprecated]] = basic_string_span; +using wstring_span [[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]] = basic_string_span; template -using cwstring_span [[deprecated]] = basic_string_span; +using cwstring_span [[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]] = basic_string_span; template -using u16string_span [[deprecated]] = basic_string_span; +using u16string_span [[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]] = basic_string_span; template -using cu16string_span [[deprecated]] = basic_string_span; +using cu16string_span [[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]] = basic_string_span; template -using u32string_span [[deprecated]] = basic_string_span; +using u32string_span [[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]] = basic_string_span; template -using cu32string_span [[deprecated]] = basic_string_span; +using cu32string_span [[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]] = basic_string_span; // // to_string() allow (explicit) conversions from string_span to string @@ -381,7 +381,7 @@ as_writable_bytes(basic_string_span s) noexcept // zero-terminated string span, used to convert // zero-terminated spans to legacy strings template -class [[deprecated]] basic_zstring_span +class [[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]] basic_zstring_span { public: using value_type = CharT; @@ -430,28 +430,28 @@ private: }; template -using zstring_span [[deprecated]] = basic_zstring_span; +using zstring_span [[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]] = basic_zstring_span; template -using wzstring_span [[deprecated]] = basic_zstring_span; +using wzstring_span [[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]] = basic_zstring_span; template -using u16zstring_span [[deprecated]] = basic_zstring_span; +using u16zstring_span [[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]] = basic_zstring_span; template -using u32zstring_span [[deprecated]] = basic_zstring_span; +using u32zstring_span [[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]] = basic_zstring_span; template -using czstring_span [[deprecated]] = basic_zstring_span; +using czstring_span [[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]] = basic_zstring_span; template -using cwzstring_span [[deprecated]] = basic_zstring_span; +using cwzstring_span [[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]] = basic_zstring_span; template -using cu16zstring_span [[deprecated]] = basic_zstring_span; +using cu16zstring_span [[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]] = basic_zstring_span; template -using cu32zstring_span [[deprecated]] = basic_zstring_span; +using cu32zstring_span [[deprecated("string_span was removed from the C++ Core Guidelines. For more information, see isocpp/CppCoreGuidelines PR#1680")]] = basic_zstring_span; // operator == template