Skip to content

Commit

Permalink
Add noexcept to str_view(const CharT*, size_type) ctor
Browse files Browse the repository at this point in the history
  • Loading branch information
rmisev committed Nov 5, 2023
1 parent 9cf4415 commit 4c5c326
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion include/upa/str_view.h
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ class str_view {
// constructors
constexpr str_view() noexcept = default;
constexpr str_view(const str_view&) noexcept = default;
constexpr str_view(const CharT* ptr, size_type len) : ptr_(ptr), len_(len) {}
constexpr str_view(const CharT* ptr, size_type len) noexcept : ptr_(ptr), len_(len) {}
str_view(const CharT* ptr) : ptr_(ptr), len_(Traits::length(ptr)) {}

// assignment
Expand Down

0 comments on commit 4c5c326

Please sign in to comment.