mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 10:48:11 +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
1615 changed files with 10257 additions and 10257 deletions
|
@ -44,9 +44,9 @@ ErrorOr<void> SectionNode::reify_if_needed() const
|
|||
m_reified = true;
|
||||
|
||||
auto own_path = TRY(path());
|
||||
Core::DirIterator dir_iterator { own_path.to_deprecated_string(), Core::DirIterator::Flags::SkipDots };
|
||||
Vector<DeprecatedString> directories;
|
||||
HashTable<DeprecatedString> files;
|
||||
Core::DirIterator dir_iterator { own_path.to_byte_string(), Core::DirIterator::Flags::SkipDots };
|
||||
Vector<ByteString> directories;
|
||||
HashTable<ByteString> files;
|
||||
while (dir_iterator.has_next()) {
|
||||
auto entry = dir_iterator.next();
|
||||
if (entry->type == Core::DirectoryEntry::Type::Directory)
|
||||
|
@ -64,7 +64,7 @@ ErrorOr<void> SectionNode::reify_if_needed() const
|
|||
for (auto const& directory : directories) {
|
||||
LexicalPath lexical_path(directory);
|
||||
RefPtr<PageNode> associated_page;
|
||||
auto matching_page_name = DeprecatedString::formatted("{}.md", directory);
|
||||
auto matching_page_name = ByteString::formatted("{}.md", directory);
|
||||
if (files.remove(matching_page_name))
|
||||
associated_page = TRY(try_make_ref_counted<PageNode>(*this, TRY(String::from_utf8(lexical_path.title()))));
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue