mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-06-17 07:41:54 +00:00
Everywhere: Rename {Deprecated => Byte}String
This commit un-deprecates DeprecatedString, and repurposes it as a byte string. As the null state has already been removed, there are no other particularly hairy blockers in repurposing this type as a byte string (what it _really_ is). This commit is auto-generated: $ xs=$(ack -l \bDeprecatedString\b\|deprecated_string AK Userland \ Meta Ports Ladybird Tests Kernel) $ perl -pie 's/\bDeprecatedString\b/ByteString/g; s/deprecated_string/byte_string/g' $xs $ clang-format --style=file -i \ $(git diff --name-only | grep \.cpp\|\.h) $ gn format $(git ls-files '*.gn' '*.gni')
This commit is contained in:
parent
38d62563b3
commit
5e1499d104
Notes:
sideshowbarker
2024-07-16 23:38:54 +09:00
Author: https://github.com/alimpfard
Commit: 5e1499d104
Pull-request: https://github.com/SerenityOS/serenity/pull/22325
1615 changed files with 10257 additions and 10257 deletions
|
@ -50,7 +50,7 @@ String HTMLHyperlinkElementUtils::origin() const
|
|||
return String {};
|
||||
|
||||
// 3. Return the serialization of this element's url's origin.
|
||||
return MUST(String::from_deprecated_string(m_url->serialize_origin()));
|
||||
return MUST(String::from_byte_string(m_url->serialize_origin()));
|
||||
}
|
||||
|
||||
// https://html.spec.whatwg.org/multipage/links.html#dom-hyperlink-protocol
|
||||
|
@ -294,7 +294,7 @@ String HTMLHyperlinkElementUtils::pathname() const
|
|||
// 4. If url's cannot-be-a-base-URL is true, then return url's path[0].
|
||||
// 5. If url's path is empty, then return the empty string.
|
||||
// 6. Return "/", followed by the strings in url's path (including empty strings), separated from each other by "/".
|
||||
return MUST(String::from_deprecated_string(m_url->serialize_path()));
|
||||
return MUST(String::from_byte_string(m_url->serialize_path()));
|
||||
}
|
||||
|
||||
// https://html.spec.whatwg.org/multipage/links.html#dom-hyperlink-pathname
|
||||
|
@ -437,7 +437,7 @@ String HTMLHyperlinkElementUtils::href() const
|
|||
return href_content_attribute.release_value();
|
||||
|
||||
// 5. Return url, serialized.
|
||||
return MUST(String::from_deprecated_string(url->serialize()));
|
||||
return MUST(String::from_byte_string(url->serialize()));
|
||||
}
|
||||
|
||||
// https://html.spec.whatwg.org/multipage/links.html#dom-hyperlink-href
|
||||
|
@ -505,7 +505,7 @@ void HTMLHyperlinkElementUtils::follow_the_hyperlink(Optional<String> hyperlink_
|
|||
return;
|
||||
|
||||
// 10. If that is successful, let URL be the resulting URL string.
|
||||
auto url_string = url.to_deprecated_string();
|
||||
auto url_string = url.to_byte_string();
|
||||
|
||||
// 12. If hyperlinkSuffix is non-null, then append it to URL.
|
||||
if (hyperlink_suffix.has_value()) {
|
||||
|
@ -513,7 +513,7 @@ void HTMLHyperlinkElementUtils::follow_the_hyperlink(Optional<String> hyperlink_
|
|||
url_builder.append(url_string);
|
||||
url_builder.append(*hyperlink_suffix);
|
||||
|
||||
url_string = url_builder.to_deprecated_string();
|
||||
url_string = url_builder.to_byte_string();
|
||||
}
|
||||
|
||||
// FIXME: 12. If subject's link types includes the noreferrer keyword, then set referrerPolicy to "no-referrer".
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue