You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@sffc Did we want pub type UnsignedDecimal = WithDecimal<UnsignedInteger>? Decimal is an Integer with an extra field that specifies the location of the decimal point.
@sffc If we keep fixed_decimal as a separate non-stable crate, this is fine, because the only thing we format is Decimal
@sffc Do we want the type wrap to be private? pub struct Decimal(Signed<UnsignedDecimal>)
@robertbastian That requires duplicating all the functions or derefing, and removing a deref step seems more semver breaking than the alternative
Proposal:
Definitely in 2.0:
pub type Decimal = Signed<UnsignedDecimal>
pub struct UnsignedDecimal
Additional integer renames (see point 3):
pub type Integer = Signed<UnsignedInteger>
pub struct UnsignedInteger
If fixed_decimal remains a util crate, we can do the integer changes post-2.0, which may involve a range dependency from icu_decimal to fixed_decimal. If we merge it into icu_decimal, we put the integer types behing an experimental feature.
If we can make pub type UnsignedDecimal in 2.x, great, if not, fine, maybe in 3.0
# Description:
Renames the UnsignedFixedDecimal type to UnsignedDecimal across multiple
files in the fixed_decimal module. This includes updates to:
- Rust source files
- Documentation
- Test files
- Dart bindings
- Diplomat coverage allowlist
The rename maintains the existing functionality while providing a more
concise type name.
Related Issues: #5065,
#6144
<!--
Thank you for your pull request to ICU4X!
Reminder: try to use [Conventional
Comments](https://conventionalcomments.org/) to make comments clearer.
Please see
https://github.com/unicode-org/icu4x/blob/main/CONTRIBUTING.md for
general
information on contributing to ICU4X.
-->
Discussion: core decimal types
pub type UnsignedDecimal = WithDecimal<UnsignedInteger>
? Decimal is an Integer with an extra field that specifies the location of the decimal point.pub struct UnsignedDecimal
topub type UnsignedDecimal
?fixed_decimal
as a separate non-stable crate, this is fine, because the only thing we format isDecimal
pub struct Decimal(Signed<UnsignedDecimal>)
Proposal:
pub type Decimal = Signed<UnsignedDecimal>
pub struct UnsignedDecimal
pub type Integer = Signed<UnsignedInteger>
pub struct UnsignedInteger
fixed_decimal
remains a util crate, we can do the integer changes post-2.0, which may involve a range dependency fromicu_decimal
tofixed_decimal
. If we merge it intoicu_decimal
, we put the integer types behing an experimental feature.pub type UnsignedDecimal
in 2.x, great, if not, fine, maybe in 3.0LGTM: @sffc @younies @robertbastian @echeran
The text was updated successfully, but these errors were encountered: