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

AnyInt builders on Number #43

Closed
8 tasks done
LVMVRQUXL opened this issue Mar 8, 2023 · 0 comments · Fixed by #44
Closed
8 tasks done

AnyInt builders on Number #43

LVMVRQUXL opened this issue Mar 8, 2023 · 0 comments · Fixed by #44
Assignees
Labels
common Item related to all platforms. feature New feature or request.
Milestone

Comments

@LVMVRQUXL
Copy link
Contributor

LVMVRQUXL commented Mar 8, 2023

Description

Builders for converting an Int to a subtype of AnyInt should also work for converting a Number type.
Here's an example for the toNonZeroInt builder:

// before
fun Int.toNonZeroInt(): Result<NonZeroInt>

// after
fun Number.toNonZeroInt(): Result<NonZeroInt>

Checklist

  • Update the toStrictlyPositiveInt builder.
  • Update the toStrictlyNegativeInt builder.
  • Update the toPositiveInt builder.
  • Update the toNegativeInt builder.
  • Update the toNonZeroInt builder.
  • Refactor code.
  • Test on all platforms.
  • Update the Unreleased section in changelog.
@LVMVRQUXL LVMVRQUXL self-assigned this Mar 8, 2023
@LVMVRQUXL LVMVRQUXL added feature New feature or request. common Item related to all platforms. labels Mar 8, 2023
@LVMVRQUXL LVMVRQUXL added this to the 4.1.0 milestone Mar 8, 2023
@LVMVRQUXL LVMVRQUXL assigned LVMVRQUXL and unassigned LVMVRQUXL Mar 8, 2023
LVMVRQUXL added a commit that referenced this issue Mar 27, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
common Item related to all platforms. feature New feature or request.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant