-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Zibi Braniecki
committed
Oct 26, 2018
1 parent
3784e20
commit f0145d5
Showing
5 changed files
with
5 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
2 changes: 1 addition & 1 deletion
2
make_pluralrules/tests/fixtures/cldr_pluralrules_within_test.rs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
# ! [ allow ( unused_variables , unused_parens ) ] # ! [ cfg_attr ( feature = "cargo-clippy" , allow ( clippy :: float_cmp ) ) ] # ! [ cfg_attr ( feature = "cargo-clippy" , allow ( clippy :: unreadable_literal ) ) ] # ! [ cfg_attr ( feature = "cargo-clippy" , allow ( clippy :: nonminimal_bool ) ) ] extern crate matches ; use phf ; use super :: operands :: PluralOperands ; use super :: { PluralCategory , PluralRuleType } ; pub type PluralRule = fn ( & PluralOperands ) -> PluralCategory ; pub static CLDR_VERSION : usize = 0 ; # [ cfg_attr ( tarpaulin , skip ) ] pub fn get_locales ( pr_type : PluralRuleType ) -> & 'static [ & 'static str ] { match pr_type { PluralRuleType :: CARDINAL => & [ "test" ] } } # [ cfg_attr ( tarpaulin , skip ) ] pub fn get_pr ( lang_code : & str , pr_type : & PluralRuleType ) -> Result < PluralRule , ( ) > { match pr_type { PluralRuleType :: CARDINAL => { static LANGUAGES : phf :: Map < & 'static str , PluralRule > = :: phf :: Map { key : 6246114685207409605 , disps : :: phf :: Slice :: Static ( & [ ( 0 , 0 ) , ] ) , entries : :: phf :: Slice :: Static ( & [ ( "test" , { fn rule_test ( po : & PluralOperands ) -> PluralCategory { if ( 2 . 0 <= po . n && po . n <= 10 . 0 && 8 > po . i && po . i > 9 ) { PluralCategory :: FEW } else if ( po . n == 1 . 0 ) { PluralCategory :: ONE } else if ( 1 <= po . i % 10 && po . i % 10 <= 2 ) { PluralCategory :: TWO } else { PluralCategory :: OTHER } } ; rule_test } ) , ] ) , } ; LANGUAGES . get ( lang_code ) . cloned ( ) . ok_or ( ( ) ) } } } | ||
# ! [ allow ( unused_variables , unused_parens ) ] # ! [ cfg_attr ( feature = "cargo-clippy" , allow ( clippy :: float_cmp ) ) ] # ! [ cfg_attr ( feature = "cargo-clippy" , allow ( clippy :: unreadable_literal ) ) ] # ! [ cfg_attr ( feature = "cargo-clippy" , allow ( clippy :: nonminimal_bool ) ) ] extern crate matches ; use phf ; use super :: operands :: PluralOperands ; use super :: { PluralCategory , PluralRuleType } ; pub type PluralRule = fn ( & PluralOperands ) -> PluralCategory ; pub static CLDR_VERSION : usize = 0 ; # [ cfg_attr ( tarpaulin , skip ) ] pub fn get_locales ( pr_type : PluralRuleType ) -> & 'static [ & 'static str ] { match pr_type { PluralRuleType :: CARDINAL => & [ "test" ] } } # [ cfg_attr ( tarpaulin , skip ) ] pub fn get_pr ( lang_code : & str , pr_type : PluralRuleType ) -> Result < PluralRule , ( ) > { match pr_type { PluralRuleType :: CARDINAL => { static LANGUAGES : phf :: Map < & 'static str , PluralRule > = :: phf :: Map { key : 6246114685207409605 , disps : :: phf :: Slice :: Static ( & [ ( 0 , 0 ) , ] ) , entries : :: phf :: Slice :: Static ( & [ ( "test" , { fn rule_test ( po : & PluralOperands ) -> PluralCategory { if ( 2 . 0 <= po . n && po . n <= 10 . 0 && 8 > po . i && po . i > 9 ) { PluralCategory :: FEW } else if ( po . n == 1 . 0 ) { PluralCategory :: ONE } else if ( 1 <= po . i % 10 && po . i % 10 <= 2 ) { PluralCategory :: TWO } else { PluralCategory :: OTHER } } ; rule_test } ) , ] ) , } ; LANGUAGES . get ( lang_code ) . cloned ( ) . ok_or ( ( ) ) } } } |