From bcfbf77eb545c9e9ca82498f447769f9ef15f9c7 Mon Sep 17 00:00:00 2001 From: Elias Rad <146735585+nnsW3@users.noreply.github.com> Date: Mon, 11 Dec 2023 11:30:27 +0200 Subject: [PATCH] Fix typos (#228) --- .github/labels.yml | 2 +- docs/CODE_OF_CONDUCT.md | 4 ++-- src/data_structures/src/bit_array.cairo | 6 +++--- src/math/src/gcd_of_n_numbers.cairo | 2 +- src/numeric/README.md | 6 +++--- src/storage/README.md | 2 +- 6 files changed, 11 insertions(+), 11 deletions(-) diff --git a/.github/labels.yml b/.github/labels.yml index 6fc63e10..29ebb1ab 100644 --- a/.github/labels.yml +++ b/.github/labels.yml @@ -16,7 +16,7 @@ description: "Updating the code with simpler, easier to understand or more efficient syntax or methods, but not introducing new features." - name: "performance" color: 1d76db - description: "Improving performance of the project, not introducing new features." + description: "Improving the performance of the project, not introducing new features." - name: "new-feature" color: 0e8a16 description: "New features or options." diff --git a/docs/CODE_OF_CONDUCT.md b/docs/CODE_OF_CONDUCT.md index 5a1136af..7f43eb97 100644 --- a/docs/CODE_OF_CONDUCT.md +++ b/docs/CODE_OF_CONDUCT.md @@ -20,13 +20,13 @@ Examples of unacceptable behavior by participants include: * Trolling, insulting/derogatory comments, and personal or political attacks * Public or private harassment * Publishing others' private information, such as a physical or electronic address, without explicit permission -* Other conduct which could reasonably be considered inappropriate in a professional setting +* Other conduct that could reasonably be considered inappropriate in a professional setting ## Our Responsibilities Project maintainers are responsible for clarifying the standards of acceptable behavior and are expected to take appropriate and fair corrective action in response to any instances of unacceptable behavior. -Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct, or to ban temporarily or permanently any contributor for other behaviors that they deem inappropriate, threatening, offensive, or harmful. +Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned with this Code of Conduct, or to ban temporarily or permanently any contributor for other behaviors that they deem inappropriate, threatening, offensive, or harmful. ## Scope diff --git a/src/data_structures/src/bit_array.cairo b/src/data_structures/src/bit_array.cairo index fe23eb17..6c89bc99 100644 --- a/src/data_structures/src/bit_array.cairo +++ b/src/data_structures/src/bit_array.cairo @@ -48,14 +48,14 @@ trait BitArrayTrait { /// # Returns /// `Option` - If there are `length` bits remaining, the word is returned as felt252 fn read_word_be(ref self: BitArray, length: usize) -> Option; - /// Reads a single word of the specified length upto 256 bits in big endian representation. + /// Reads a single word of the specified length up to 256 bits in big endian representation. /// For words shorter than (or equal to) 248 bits use `read_word_be(...)` instead. /// # Arguments /// `length` - The bit length of the word to read, max 256 /// # Returns /// `Option` - If there are `length` bits remaining, the word is returned as u256 fn read_word_be_u256(ref self: BitArray, length: usize) -> Option; - /// Reads a single word of the specified length upto 512 bits in big endian representation. + /// Reads a single word of the specified length up to 512 bits in big endian representation. /// For words shorter than (or equal to) 256 bits consider the other read calls instead. /// # Arguments /// `length` - The bit length of the word to read, max 512 @@ -86,7 +86,7 @@ trait BitArrayTrait { /// # Returns /// `Option` - If there are `length` bits remaining, the word is returned as felt252 fn read_word_le(ref self: BitArray, length: usize) -> Option; - /// Reads a single word of the specified length upto 256 bits in little endian representation. + /// Reads a single word of the specified length up to 256 bits in little endian representation. /// For words shorter than (or equal to) 248 bits use `read_word_be(...)` instead. /// # Arguments /// `length` - The bit length of the word to read, max 256 diff --git a/src/math/src/gcd_of_n_numbers.cairo b/src/math/src/gcd_of_n_numbers.cairo index d1ef7fe5..4e474e05 100644 --- a/src/math/src/gcd_of_n_numbers.cairo +++ b/src/math/src/gcd_of_n_numbers.cairo @@ -1,6 +1,6 @@ //! # GCD for N numbers -// Calculate the greatest common dividor for n numbers +// Calculate the greatest common divisor for n numbers // # Arguments // * `n` - The array of numbers to calculate the gcd for // # Returns diff --git a/src/numeric/README.md b/src/numeric/README.md index f928dd4b..31d9eb8c 100644 --- a/src/numeric/README.md +++ b/src/numeric/README.md @@ -10,8 +10,8 @@ Returns the one-dimensional piecewise linear interpolant to a function with give Several interpolation methods are supported as follow: - Linear interpolation: y is linearly interpolated between the two nearest neighbors at x - Nearest-neighbor interpolation: y is set to the value of the nearest neighbor at x -- Constant left interpolation: ys behaves as a integer part function where each y data point extends to the left up to the next index -- Constant right interpolation: ys behaves as a integer part function where each y data point extends to the right up to the next index +- Constant left interpolation: ys behaves as an integer part function where each y data point extends to the left up to the next index +- Constant right interpolation: ys behaves as an integer part function where each y data point extends to the right up to the next index ## [Cumsum](./src/cumsum.cairo) @@ -19,4 +19,4 @@ Return the cumulative sum of the elements ([see also](https://numpy.org/doc/stab ## [Diff](./src/diff.cairo) -Return the discrete difference of the elements ([see also](https://numpy.org/doc/stable/reference/generated/numpy.diff.html#numpy.diff)). \ No newline at end of file +Return the discrete difference of the elements ([see also](https://numpy.org/doc/stable/reference/generated/numpy.diff.html#numpy.diff)). diff --git a/src/storage/README.md b/src/storage/README.md index f8c32015..41700700 100644 --- a/src/storage/README.md +++ b/src/storage/README.md @@ -39,7 +39,7 @@ Note that unlike `get`, using this bracket notation panics when accessing an out ### Caveats -There are two idiosyncacies you should be aware of when using `List` +There are two idiosyncrasies you should be aware of when using `List` 1. The `append` operation costs 2 storage writes - one for the value itself and another one for updating the List's length 2. Due to a compiler limitation, it is not possible to use mutating operations with a single inline statement. For example, `self.amounts.read().append(42);` will not work. You have to do it in 2 steps: