mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-22 07:30:19 +00:00
AK: Fix 'constexpr' attribute on non-constexpr function
is_url_code_point invokes StringView::contains, which never was and cannot become constexpr.
This commit is contained in:
parent
ff8f3814cc
commit
dc71e1e264
Notes:
sideshowbarker
2024-07-17 09:39:38 +09:00
Author: https://github.com/BenWiederhake Commit: https://github.com/SerenityOS/serenity/commit/dc71e1e264 Pull-request: https://github.com/SerenityOS/serenity/pull/15211 Reviewed-by: https://github.com/ADKaster Reviewed-by: https://github.com/IdanHo Reviewed-by: https://github.com/bgianfo Reviewed-by: https://github.com/trflynn89
1 changed files with 1 additions and 1 deletions
|
@ -19,7 +19,7 @@ namespace AK {
|
|||
// NOTE: This is similar to the LibC macro EOF = -1.
|
||||
constexpr u32 end_of_file = 0xFFFFFFFF;
|
||||
|
||||
constexpr bool is_url_code_point(u32 code_point)
|
||||
static bool is_url_code_point(u32 code_point)
|
||||
{
|
||||
// FIXME: [...] and code points in the range U+00A0 to U+10FFFD, inclusive, excluding surrogates and noncharacters.
|
||||
return is_ascii_alphanumeric(code_point) || code_point >= 0xA0 || "!$&'()*+,-./:;=?@_~"sv.contains(code_point);
|
||||
|
|
Loading…
Reference in a new issue