Skip to content

Inconsistency in Uint128 api for overflow/underflow behaviour #850

@yihuang

Description

@yihuang

Add use default + operator under the hood, while Sub use checked_sub.
I think it would be better to keep is consistent with rust std's behaviour:

  • default operator +/-, panic when wrapping.
  • add methods for explicit checked_*/wrapping_*/saturating_* operations.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions