LibUnicode+Everywhere: Merge LibLocale back into LibUnicode

LibLocale was split off from LibUnicode a couple years ago to reduce the
number of applications on SerenityOS that depend on CLDR data. Now that
we use ICU, both LibUnicode and LibLocale are actually linking in this
data. And since vcpkg gives us static libraries, both libraries are over
30MB in size.

This patch reverts the separation and merges LibLocale into LibUnicode
again. We now have just one library that includes the ICU data.

Further, this will let LibUnicode share the locale cache that previously
would only exist in LibLocale.
This commit is contained in:
Timothy Flynn 2024-06-23 09:14:27 -04:00 committed by Andreas Kling
commit ebdb92eef6
Notes: sideshowbarker 2024-07-16 16:23:32 +09:00
102 changed files with 675 additions and 711 deletions

View file

@ -7,7 +7,7 @@
#pragma once
#include <AK/String.h>
#include <LibLocale/Forward.h>
#include <LibUnicode/Forward.h>
#include <LibWeb/DOM/ChildNode.h>
#include <LibWeb/DOM/Node.h>
#include <LibWeb/DOM/NonDocumentTypeChildNode.h>
@ -41,7 +41,7 @@ public:
WebIDL::ExceptionOr<void> delete_data(size_t offset_in_utf16_code_units, size_t count_in_utf16_code_units);
WebIDL::ExceptionOr<void> replace_data(size_t offset_in_utf16_code_units, size_t count_in_utf16_code_units, String const&);
Locale::Segmenter& segmenter();
Unicode::Segmenter& segmenter();
protected:
CharacterData(Document&, NodeType, String const&);
@ -51,7 +51,7 @@ protected:
private:
String m_data;
OwnPtr<Locale::Segmenter> m_segmenter;
OwnPtr<Unicode::Segmenter> m_segmenter;
};
}