1// @generated 2/// Implement `DataProvider<WordBreakNameToValueV2>` on the given struct using the data 3/// hardcoded in this file. This allows the struct to be used with 4/// `icu`'s `_unstable` constructors. 5/// 6/// Using this implementation will embed the following data in the binary's data segment: 7/// * 332B[^1] for the singleton data struct 8/// 9/// [^1]: these numbers can be smaller in practice due to linker deduplication 10#[doc(hidden)] 11#[macro_export] 12macro_rules! __impl_word_break_name_to_value_v2 { 13 ($ provider : ty) => { 14 #[clippy::msrv = "1.81"] 15 const _: () = <$provider>::MUST_USE_MAKE_PROVIDER_MACRO; 16 #[clippy::msrv = "1.81"] 17 impl $provider { 18 #[doc(hidden)] 19 pub const SINGLETON_WORD_BREAK_NAME_TO_VALUE_V2: &'static <icu::properties::provider::WordBreakNameToValueV2 as icu_provider::DynamicDataMarker>::DataStruct = &icu::properties::provider::names::PropertyValueNameToEnumMap { map: zerotrie::ZeroTrieSimpleAscii { store: unsafe { zerovec::ZeroVec::from_bytes_unchecked(b"\xE1qACDEFGHKLMNORSWXZ\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x07\t\x1BQ[p\x81\x8D\x93\xB0\xC6\xCB\xE1\xF1\xFB\xFDLetter\x81R\x88\xC2Qo\x02\x90\0uble_Quote\x90\0\xC5BMX_x\x05\x07\x08 \x90\x01G\x90\x02\x90\x03\x87\xC2BM\x0Base\x90\x01_GAZ\x90\x02odifier\x90\x03tend\x89NumLet\x87\xC2Oo\x01\x82rmat\x82\xC2Al\x03Z\x90\x04ue_After_Zwj\x90\x04\xC2Le\x01\x8Ebrew_Letter\x8E\xC2Aa\x01\x83takana\x83\xC2EF\x01\x81\x8A\xC4BLNi\x01\x02\x03\x8B\x84\x85d\xC2LN\x06etter\x84um\x85Let\x8B\xC4LUeu\x01\x02\x08\x8C\x86wline\x8Cmeric\x86ther\x80\xC2Ie\x01\x8Dgional_Indicator\x8D\xC2Qi\x01\x8Fngle_Quote\x8FSegSpace\x90\x06X\x80WJ\x90\x05") } } }; 20 } 21 #[clippy::msrv = "1.81"] 22 impl icu_provider::DataProvider<icu::properties::provider::WordBreakNameToValueV2> for $provider { 23 fn load(&self, req: icu_provider::DataRequest) -> Result<icu_provider::DataResponse<icu::properties::provider::WordBreakNameToValueV2>, icu_provider::DataError> { 24 if req.id.locale.is_default() { 25 Ok(icu_provider::DataResponse { payload: icu_provider::DataPayload::from_static_ref(Self::SINGLETON_WORD_BREAK_NAME_TO_VALUE_V2), metadata: icu_provider::DataResponseMetadata::default() }) 26 } else { 27 Err(icu_provider::DataErrorKind::InvalidRequest.with_req(<icu::properties::provider::WordBreakNameToValueV2 as icu_provider::DataMarker>::INFO, req)) 28 } 29 } 30 } 31 }; 32 ($ provider : ty , ITER) => { 33 __impl_word_break_name_to_value_v2!($provider); 34 #[clippy::msrv = "1.81"] 35 impl icu_provider::IterableDataProvider<icu::properties::provider::WordBreakNameToValueV2> for $provider { 36 fn iter_ids(&self) -> Result<std::collections::BtreeSet<icu_provider::DataIdentifierCow<'static>>, icu_provider::DataError> { 37 Ok([Default::default()].into_iter().collect()) 38 } 39 } 40 }; 41 ($ provider : ty , DRY) => { 42 __impl_word_break_name_to_value_v2!($provider); 43 #[clippy::msrv = "1.81"] 44 impl icu_provider::DryDataProvider<icu::properties::provider::WordBreakNameToValueV2> for $provider { 45 fn dry_load(&self, req: icu_provider::DataRequest) -> Result<icu_provider::DataResponseMetadata, icu_provider::DataError> { 46 if req.id.locale.is_default() { 47 Ok(icu_provider::DataResponseMetadata::default()) 48 } else { 49 Err(icu_provider::DataErrorKind::InvalidRequest.with_req(<icu::properties::provider::WordBreakNameToValueV2 as icu_provider::DataMarker>::INFO, req)) 50 } 51 } 52 } 53 }; 54 ($ provider : ty , DRY , ITER) => { 55 __impl_word_break_name_to_value_v2!($provider); 56 #[clippy::msrv = "1.81"] 57 impl icu_provider::DryDataProvider<icu::properties::provider::WordBreakNameToValueV2> for $provider { 58 fn dry_load(&self, req: icu_provider::DataRequest) -> Result<icu_provider::DataResponseMetadata, icu_provider::DataError> { 59 if req.id.locale.is_default() { 60 Ok(icu_provider::DataResponseMetadata::default()) 61 } else { 62 Err(icu_provider::DataErrorKind::InvalidRequest.with_req(<icu::properties::provider::WordBreakNameToValueV2 as icu_provider::DataMarker>::INFO, req)) 63 } 64 } 65 } 66 #[clippy::msrv = "1.81"] 67 impl icu_provider::IterableDataProvider<icu::properties::provider::WordBreakNameToValueV2> for $provider { 68 fn iter_ids(&self) -> Result<std::collections::BtreeSet<icu_provider::DataIdentifierCow<'static>>, icu_provider::DataError> { 69 Ok([Default::default()].into_iter().collect()) 70 } 71 } 72 }; 73} 74#[doc(inline)] 75pub use __impl_word_break_name_to_value_v2 as impl_word_break_name_to_value_v2; 76