diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 369ad48..782fecc 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -7,6 +7,9 @@ on: jobs: release: runs-on: ubuntu-latest + permissions: + contents: write + actions: read steps: - uses: actions/checkout@v4 diff --git a/README.md b/README.md index 78a79ad..d3665c2 100644 --- a/README.md +++ b/README.md @@ -66,6 +66,13 @@ std::cout << "a= " << a << ", b= " << b << '\n'; numbers::i64 ret = a.saturating_mul(b); std::cout << ret << '\n'; ``` + +### wrapping add +```c++ +numbers::u128 max = numbers::u128::MAX; +numbers::u128 ret = max.wrapping_add(1); // wrapping around +std::cout << ret << '\n'; +``` ## Contribute