mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-05-19 09:32:52 +00:00
Everywhere: Use ReadonlySpan<T> instead of Span<T const>
This commit is contained in:
parent
1c92e6ee9d
commit
63b11030f0
Notes:
sideshowbarker
2024-07-17 04:57:23 +09:00
Author: https://github.com/MacDue
Commit: 63b11030f0
Pull-request: https://github.com/SerenityOS/serenity/pull/17328
Reviewed-by: https://github.com/trflynn89
102 changed files with 206 additions and 206 deletions
|
@ -228,9 +228,9 @@ struct EmojiData {
|
|||
return emoji;
|
||||
}
|
||||
|
||||
constexpr Span<u32 const> code_points() const
|
||||
constexpr ReadonlySpan<u32> code_points() const
|
||||
{
|
||||
return Span<u32 const>(s_emoji_code_points.data() + code_point_start, code_point_count);
|
||||
return ReadonlySpan<u32>(s_emoji_code_points.data() + code_point_start, code_point_count);
|
||||
}
|
||||
|
||||
@string_index_type@ name { 0 };
|
||||
|
@ -259,7 +259,7 @@ static constexpr Array<EmojiData, @emojis_size@> s_emojis { {)~~~");
|
|||
generator.append(R"~~~(
|
||||
} };
|
||||
|
||||
Optional<Emoji> find_emoji_for_code_points(Span<u32 const> code_points)
|
||||
Optional<Emoji> find_emoji_for_code_points(ReadonlySpan<u32> code_points)
|
||||
{
|
||||
for (auto& emoji : s_emojis) {
|
||||
if (emoji.code_points() == code_points)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue