Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improving icu_harfbuzz compiled data #4574

Merged
merged 10 commits into from
Feb 27, 2024
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion components/normalizer/src/properties.rs
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ impl CanonicalComposition {
///
/// [📚 Help choosing a constructor](icu_provider::constructors)
#[cfg(feature = "compiled_data")]
pub fn new() -> Self {
pub const fn new() -> Self {
robertbastian marked this conversation as resolved.
Show resolved Hide resolved
Self {
canonical_compositions: DataPayload::from_static_ref(
crate::provider::Baked::SINGLETON_NORMALIZER_COMP_V1,
Expand Down
6 changes: 3 additions & 3 deletions components/properties/src/props.rs
Original file line number Diff line number Diff line change
Expand Up @@ -585,7 +585,7 @@ macro_rules! impl_value_getter {
impl $ty {
$(#[$attr_n2e])*
#[cfg(feature = "compiled_data")]
$vis_n2e fn $cname_n2e() -> PropertyValueNameToEnumMapperBorrowed<'static, $ty> {
$vis_n2e const fn $cname_n2e() -> PropertyValueNameToEnumMapperBorrowed<'static, $ty> {
PropertyValueNameToEnumMapperBorrowed {
map: crate::provider::Baked::$singleton_n2e,
markers: PhantomData,
Expand All @@ -604,7 +604,7 @@ macro_rules! impl_value_getter {
$(
$(#[$attr_e2sn])*
#[cfg(feature = "compiled_data")]
$vis_e2sn fn $cname_e2sn() -> $mapper_e2snb<'static, $ty> {
$vis_e2sn const fn $cname_e2sn() -> $mapper_e2snb<'static, $ty> {
$mapper_e2snb {
map: crate::provider::Baked::$singleton_e2sn,
markers: PhantomData,
Expand All @@ -622,7 +622,7 @@ macro_rules! impl_value_getter {

$(#[$attr_e2ln])*
#[cfg(feature = "compiled_data")]
$vis_e2ln fn $cname_e2ln() -> $mapper_e2lnb<'static, $ty> {
$vis_e2ln const fn $cname_e2ln() -> $mapper_e2lnb<'static, $ty> {
$mapper_e2lnb {
map: crate::provider::Baked::$singleton_e2ln,
markers: PhantomData,
Expand Down
1 change: 1 addition & 0 deletions experimental/harfbuzz/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -44,5 +44,6 @@ harfbuzz = { version = "0.4.0" }
[features]
default = []
compiled_data = ["icu_normalizer/compiled_data", "icu_properties/compiled_data"]
alloc = []
std = []
serde = ["icu_properties/serde", "icu_normalizer/serde", "icu_provider/serde"]
Loading
Loading