-
Notifications
You must be signed in to change notification settings - Fork 34
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adds support for basic message formatting. (#57)
ICU compatible MessageFormat for rust is here. Implemented functions are from the header `umsg.h`: - Constructor/destructor: `umsg_open`, `umsg_close` through standard Rust mechanisms. - Formatting: `umsg_format` and `umsg_vformat` through `message_format!` macro, since the distinction does not matter in rust. - Documentation and tests. Slated for v0.1.1 as this is a backward-compatible API. Fixes: 56
- Loading branch information
Showing
16 changed files
with
552 additions
and
37 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,5 +9,6 @@ members = [ | |
"rust_icu_uloc", | ||
"rust_icu_ustring", | ||
"rust_icu_utext", | ||
"rust_icu_umsg", | ||
] | ||
|
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
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
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
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 |
---|---|---|
@@ -0,0 +1,39 @@ | ||
[package] | ||
authors = ["Google Inc."] | ||
edition = "2018" | ||
license = "Apache-2.0" | ||
name = "rust_icu_umsg" | ||
readme = "README.md" | ||
repository = "https://github.com/google/rust_icu" | ||
version = "0.1.0" | ||
|
||
description = """ | ||
Native bindings to the ICU4C library from Unicode. | ||
umsg.h | ||
""" | ||
|
||
keywords = ["icu", "unicode", "i18n", "l10n"] | ||
|
||
[dependencies] | ||
anyhow = "1.0.25" | ||
log = "0.4.6" | ||
paste = "0.1.5" | ||
rust_icu_common = { path = "../rust_icu_common", version = "0.1.0", default-features = false } | ||
rust_icu_sys = { path = "../rust_icu_sys", version = "0.1.0", default-features = false } | ||
rust_icu_uloc = { path = "../rust_icu_uloc", version = "0.1.0", default-features = false } | ||
rust_icu_ustring = { path = "../rust_icu_ustring", version = "0.1.0", default-features = false } | ||
thiserror = "1.0.9" | ||
|
||
[dev-dependencies] | ||
rust_icu_ucal = { path = "../rust_icu_ucal", version = "0.1.0", default-features = false } | ||
|
||
# See the feature description in ../rust_icu_sys/Cargo.toml for details. | ||
[features] | ||
default = ["bindgen", "renaming", "icu_config"] | ||
|
||
bindgen = ["rust_icu_sys/bindgen", "rust_icu_common/bindgen"] | ||
renaming = ["rust_icu_sys/renaming", "rust_icu_common/renaming"] | ||
icu_config = ["rust_icu_sys/icu_config", "rust_icu_common/icu_config"] | ||
icu_version_in_env = ["rust_icu_sys/icu_version_in_env", "rust_icu_common/icu_version_in_env"] | ||
|
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 |
---|---|---|
@@ -0,0 +1 @@ | ||
../README.md |
Oops, something went wrong.