mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-21 23:20:20 +00:00
AK: Don't use east-constexpr in Span methods
This commit is contained in:
parent
0994aa91dc
commit
faf4ba63c2
Notes:
sideshowbarker
2024-07-17 23:00:03 +09:00
Author: https://github.com/trflynn89 Commit: https://github.com/SerenityOS/serenity/commit/faf4ba63c2 Pull-request: https://github.com/SerenityOS/serenity/pull/23595
1 changed files with 3 additions and 3 deletions
|
@ -210,7 +210,7 @@ public:
|
|||
return size();
|
||||
}
|
||||
|
||||
[[nodiscard]] bool constexpr contains_slow(T const& value) const
|
||||
[[nodiscard]] constexpr bool contains_slow(T const& value) const
|
||||
{
|
||||
for (size_t i = 0; i < size(); ++i) {
|
||||
if (at(i) == value)
|
||||
|
@ -219,7 +219,7 @@ public:
|
|||
return false;
|
||||
}
|
||||
|
||||
[[nodiscard]] bool constexpr starts_with(ReadonlySpan<T> other) const
|
||||
[[nodiscard]] constexpr bool starts_with(ReadonlySpan<T> other) const
|
||||
{
|
||||
if (size() < other.size())
|
||||
return false;
|
||||
|
@ -227,7 +227,7 @@ public:
|
|||
return TypedTransfer<T>::compare(data(), other.data(), other.size());
|
||||
}
|
||||
|
||||
[[nodiscard]] size_t constexpr matching_prefix_length(ReadonlySpan<T> other) const
|
||||
[[nodiscard]] constexpr size_t matching_prefix_length(ReadonlySpan<T> other) const
|
||||
{
|
||||
auto maximum_length = min(size(), other.size());
|
||||
|
||||
|
|
Loading…
Reference in a new issue