diff --git a/include/str_intrusion.h b/include/str_intrusion.h index d4f895e..7fd008f 100644 --- a/include/str_intrusion.h +++ b/include/str_intrusion.h @@ -4,6 +4,6 @@ struct StrFromSV_Wrapper { std::string str; - StrFromSV_Wrapper(std::string_view sv); - ~StrFromSV_Wrapper(); + StrFromSV_Wrapper(std::string_view sv) noexcept; + ~StrFromSV_Wrapper() noexcept; }; \ No newline at end of file diff --git a/src/str_intrusion.cpp b/src/str_intrusion.cpp index 21c0df8..62fbbd6 100644 --- a/src/str_intrusion.cpp +++ b/src/str_intrusion.cpp @@ -32,12 +32,12 @@ struct string_data }; template class rob; -StrFromSV_Wrapper::StrFromSV_Wrapper(std::string_view sv) +StrFromSV_Wrapper::StrFromSV_Wrapper(std::string_view sv) noexcept { (str.*result::ptr)((char *)sv.data()); (str.*result::ptr)(sv.size()); } -StrFromSV_Wrapper::~StrFromSV_Wrapper() +StrFromSV_Wrapper::~StrFromSV_Wrapper() noexcept { (str.*result::ptr)(nullptr); (str.*result::ptr)(0);