From af7fd32f4c1b0b753e49b22bb04150ef086b77a2 Mon Sep 17 00:00:00 2001 From: Kevin Heavey <24635973+kevinheavey@users.noreply.github.com> Date: Wed, 25 Oct 2023 15:21:53 +0100 Subject: [PATCH] chore: fix some typos (#33833) * fix spelling of "retrieved" * fix spelling of "should" * fix spelling of "comparisons" --- accounts-db/src/accounts_db.rs | 2 +- accounts-db/src/accounts_hash.rs | 8 ++++---- ci/semver_bash/semver_test.sh | 12 ++++++------ cost-model/src/cost_tracker.rs | 2 +- docs/static/katex/katex.js | 2 +- docs/static/katex/katex.mjs | 2 +- sdk/program/src/system_instruction.rs | 2 +- 7 files changed, 15 insertions(+), 15 deletions(-) diff --git a/accounts-db/src/accounts_db.rs b/accounts-db/src/accounts_db.rs index 469de17c5b..f080abcb85 100644 --- a/accounts-db/src/accounts_db.rs +++ b/accounts-db/src/accounts_db.rs @@ -5882,7 +5882,7 @@ impl AccountsDb { self.purge_slot_cache(*remove_slot, slot_cache); remove_cache_elapsed.stop(); remove_cache_elapsed_across_slots += remove_cache_elapsed.as_us(); - // Nobody else shoud have removed the slot cache entry yet + // Nobody else should have removed the slot cache entry yet assert!(self.accounts_cache.remove_slot(*remove_slot).is_some()); } else { self.purge_slot_storage(*remove_slot, purge_stats); diff --git a/accounts-db/src/accounts_hash.rs b/accounts-db/src/accounts_hash.rs index 7aac99f5a6..6b853895d7 100644 --- a/accounts-db/src/accounts_hash.rs +++ b/accounts-db/src/accounts_hash.rs @@ -1517,18 +1517,18 @@ mod tests { let len = combined.len(); assert_eq!(cumulative.total_count(), len); (0..combined.len()).for_each(|start| { - let mut retreived = Vec::default(); + let mut retrieved = Vec::default(); let mut cumulative_start = start; // read all data - while retreived.len() < (len - start) { + while retrieved.len() < (len - start) { let this_one = cumulative.get_slice(cumulative_start); - retreived.extend(this_one.iter()); + retrieved.extend(this_one.iter()); cumulative_start += this_one.len(); assert_ne!(0, this_one.len()); } assert_eq!( &combined[start..], - &retreived[..], + &retrieved[..], "permutation: {permutation}" ); }); diff --git a/ci/semver_bash/semver_test.sh b/ci/semver_bash/semver_test.sh index a0ff99461e..a4cca97484 100755 --- a/ci/semver_bash/semver_test.sh +++ b/ci/semver_bash/semver_test.sh @@ -21,7 +21,7 @@ echo "$A -> M:$MAJOR m:$MINOR p:$PATCH s:$SPECIAL. Expect M:1 m:3 p:2 s:" semverParseInto $E MAJOR MINOR PATCH SPECIAL echo "$E -> M:$MAJOR m:$MINOR p:$PATCH s:$SPECIAL. Expect M:1 m:3 p:2 s:a" -echo "Equality comparisions" +echo "Equality comparisons" semverEQ $A $A echo "$A == $A -> $?. Expect 0." @@ -32,7 +32,7 @@ semverGT $A $A echo "$A > $A -> $?. Expect 1." -echo "Major number comparisions" +echo "Major number comparisons" semverEQ $A $B echo "$A == $B -> $?. Expect 1." @@ -52,7 +52,7 @@ semverGT $B $A echo "$B > $A -> $?. Expect 0." -echo "Minor number comparisions" +echo "Minor number comparisons" semverEQ $A $C echo "$A == $C -> $?. Expect 1." @@ -71,7 +71,7 @@ echo "$C < $A -> $?. Expect 1." semverGT $C $A echo "$C > $A -> $?. Expect 0." -echo "patch number comparisions" +echo "patch number comparisons" semverEQ $A $D echo "$A == $D -> $?. Expect 1." @@ -90,7 +90,7 @@ echo "$D < $A -> $?. Expect 1." semverGT $D $A echo "$D > $A -> $?. Expect 0." -echo "special section vs no special comparisions" +echo "special section vs no special comparisons" semverEQ $A $E echo "$A == $E -> $?. Expect 1." @@ -109,7 +109,7 @@ echo "$E < $A -> $?. Expect 0." semverGT $E $A echo "$E > $A -> $?. Expect 1." -echo "special section vs special comparisions" +echo "special section vs special comparisons" semverEQ $E $F echo "$E == $F -> $?. Expect 1." diff --git a/cost-model/src/cost_tracker.rs b/cost-model/src/cost_tracker.rs index e4f1b917d7..efdd86512d 100644 --- a/cost-model/src/cost_tracker.rs +++ b/cost-model/src/cost_tracker.rs @@ -713,7 +713,7 @@ mod tests { } // case 3: add tx writes to [acct1, acct2], acct2 exceeds limit, should failed atomically, - // we shoudl still have: + // we should still have: // | acct1 | $cost | // | acct2 | $cost * 2 | // | acct3 | $cost | diff --git a/docs/static/katex/katex.js b/docs/static/katex/katex.js index 37fb0fa896..e5d3166918 100644 --- a/docs/static/katex/katex.js +++ b/docs/static/katex/katex.js @@ -3674,7 +3674,7 @@ function assertSpan(group) { // '\expandafter\show\the\scriptscriptfont2' \ // '\stop' // -// The metrics themselves were retreived using the following commands: +// The metrics themselves were retrieved using the following commands: // // tftopl cmsy10 // tftopl cmsy7 diff --git a/docs/static/katex/katex.mjs b/docs/static/katex/katex.mjs index 76938229ff..488d2101c2 100644 --- a/docs/static/katex/katex.mjs +++ b/docs/static/katex/katex.mjs @@ -3698,7 +3698,7 @@ var metricMap = { // '\expandafter\show\the\scriptscriptfont2' \ // '\stop' // -// The metrics themselves were retreived using the following commands: +// The metrics themselves were retrieved using the following commands: // // tftopl cmsy10 // tftopl cmsy7 diff --git a/sdk/program/src/system_instruction.rs b/sdk/program/src/system_instruction.rs index 0c8ba59e6e..74646f7fb7 100644 --- a/sdk/program/src/system_instruction.rs +++ b/sdk/program/src/system_instruction.rs @@ -1461,7 +1461,7 @@ pub fn create_nonce_account( /// /// When constructing a transaction that includes an `AdvanceNonceInstruction` /// the [`recent_blockhash`] must be treated differently — instead of -/// setting it to a recent blockhash, the value of the nonce must be retreived +/// setting it to a recent blockhash, the value of the nonce must be retrieved /// and deserialized from the nonce account, and that value specified as the /// "recent blockhash". A nonce account can be deserialized with the /// [`solana_rpc_client_nonce_utils::data_from_account`][dfa] function.