mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-22 07:30:19 +00:00
AK: Convert a couple String-related declarations to east-const
Caught by clang-format-17. Note that clang-format-16 is fine with this as well (it leaves the const placement alone), it just doesn't perform the formatting to east-const itself.
This commit is contained in:
parent
b8cbc282f3
commit
9cab4958e6
Notes:
sideshowbarker
2024-07-16 20:12:13 +09:00
Author: https://github.com/trflynn89 Commit: https://github.com/SerenityOS/serenity/commit/9cab4958e6 Pull-request: https://github.com/SerenityOS/serenity/pull/22562 Reviewed-by: https://github.com/nico ✅
3 changed files with 4 additions and 4 deletions
|
@ -189,7 +189,7 @@ public:
|
|||
return bit_cast<u8>((*m_impl)[i]);
|
||||
}
|
||||
|
||||
using ConstIterator = SimpleIterator<const ByteString, char const>;
|
||||
using ConstIterator = SimpleIterator<ByteString const, char const>;
|
||||
|
||||
[[nodiscard]] constexpr ConstIterator begin() const { return ConstIterator::begin(*this); }
|
||||
[[nodiscard]] constexpr ConstIterator end() const { return ConstIterator::end(*this); }
|
||||
|
|
|
@ -174,7 +174,7 @@ Optional<T> convert_to_uint_from_hex(StringView str, TrimWhitespace trim_whitesp
|
|||
|
||||
T value = 0;
|
||||
auto const count = string.length();
|
||||
const T upper_bound = NumericLimits<T>::max();
|
||||
T const upper_bound = NumericLimits<T>::max();
|
||||
|
||||
for (size_t i = 0; i < count; i++) {
|
||||
char digit = string[i];
|
||||
|
@ -213,7 +213,7 @@ Optional<T> convert_to_uint_from_octal(StringView str, TrimWhitespace trim_white
|
|||
|
||||
T value = 0;
|
||||
auto const count = string.length();
|
||||
const T upper_bound = NumericLimits<T>::max();
|
||||
T const upper_bound = NumericLimits<T>::max();
|
||||
|
||||
for (size_t i = 0; i < count; i++) {
|
||||
char digit = string[i];
|
||||
|
|
|
@ -83,7 +83,7 @@ public:
|
|||
return m_characters[index];
|
||||
}
|
||||
|
||||
using ConstIterator = SimpleIterator<const StringView, char const>;
|
||||
using ConstIterator = SimpleIterator<StringView const, char const>;
|
||||
|
||||
[[nodiscard]] constexpr ConstIterator begin() const { return ConstIterator::begin(*this); }
|
||||
[[nodiscard]] constexpr ConstIterator end() const { return ConstIterator::end(*this); }
|
||||
|
|
Loading…
Reference in a new issue