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

Introduce ConstUint to make dependent types in DefaultConfig more adaptable #6425

Merged
merged 4 commits into from
Nov 12, 2024

Conversation

conr2d
Copy link
Contributor

@conr2d conr2d commented Nov 10, 2024

Description

Resolves #6193

This PR introduces ConstUint as a replacement for existing constant getter types like ConstU8, ConstU16, etc., providing a more flexible and unified approach.

Integration

This update is backward compatible, so developers can choose to adopt ConstUint in new implementations or continue using the existing types as needed.

Review Notes

ConstUint is a convenient alternative to ConstU8, ConstU16, and similar types, particularly useful for configuring DefaultConfig in pallets. It enables configuring the underlying integer for a specific type without the need to update all dependent types, offering enhanced flexibility in type management.

Checklist

  • My PR includes a detailed description as outlined in the "Description" and its two subsections above.
  • My PR follows the labeling requirements of this project (at minimum one label for T required)
    • External contributors: ask maintainers to put the right label on your PR.
  • I have made corresponding changes to the documentation (if applicable)
  • I have added tests that prove my fix is effective or that my feature works (if applicable)

@conr2d conr2d changed the title Const int Introduce ConstUint to make dependent types in DefaultConfig more adaptable Nov 10, 2024
@conr2d conr2d marked this pull request as ready for review November 10, 2024 08:46
@conr2d conr2d requested a review from a team as a code owner November 10, 2024 08:46
@bkchr bkchr added the T17-primitives Changes to primitives that are not covered by any other label. label Nov 10, 2024
@gui1117 gui1117 added this pull request to the merge queue Nov 12, 2024
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Nov 12, 2024
@bkchr bkchr added this pull request to the merge queue Nov 12, 2024
Merged via the queue into paritytech:master with commit 872d949 Nov 12, 2024
280 of 352 checks passed
@conr2d conr2d deleted the const-int branch November 12, 2024 14:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
T17-primitives Changes to primitives that are not covered by any other label.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Introduce ConstUint to replace ConstU* for convenient runtime configuration
4 participants