From ed697bbe65bc4824af85bad22d6885aec051b6e1 Mon Sep 17 00:00:00 2001 From: joao <22820692+joaolago1113@users.noreply.github.com> Date: Wed, 7 Feb 2024 18:46:56 +0000 Subject: [PATCH] chore: Fix Incorrect `wrapping_add` Usage in Integers Tutorial (#4295) This pull request addresses an issue identified in the [integers tutorial](https://noir-lang.org/docs/noir/syntax/data_types/integers/), where the `wrapping_add` function was incorrectly called with a single argument `(x + y)` instead of the correct form with two separate arguments `(x, y)`. ### Changes Made The documentation has been updated to reflect the correct usage: ```diff - std::wrapping_add(x + y) + std::wrapping_add(x, y) ``` ### Acknowledgements Special thanks to @Complexlity for identifying this issue and bringing it to attention through issue #4272. --- docs/docs/noir/concepts/data_types/integers.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/docs/noir/concepts/data_types/integers.md b/docs/docs/noir/concepts/data_types/integers.md index b95cd8dc837..30135d76e4a 100644 --- a/docs/docs/noir/concepts/data_types/integers.md +++ b/docs/docs/noir/concepts/data_types/integers.md @@ -157,6 +157,6 @@ Example of how it is used: use dep::std; fn main(x: u8, y: u8) -> pub u8 { - std::wrapping_add(x + y) + std::wrapping_add(x, y) } ```