From 9535aa3f0049942fa29b3d57dfb0fbc7b36223b1 Mon Sep 17 00:00:00 2001 From: c0pp3rdru1d Date: Sun, 1 Mar 2026 10:33:12 -0800 Subject: [PATCH] Fixed multiple typo's throughout the code structure, mostly in comments --- .github/workflows/ci.yml | 2 +- core/codegen/src/lib.rs | 4 ++-- core/http/src/parse/uri/parser.rs | 2 +- core/http/src/uri/fmt/formatter.rs | 2 +- core/lib/src/catcher/catcher.rs | 4 ++-- core/lib/src/outcome.rs | 2 +- core/lib/src/route/route.rs | 2 +- examples/tls/src/redirector.rs | 2 +- 8 files changed, 10 insertions(+), 10 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 293cf447a2..55247a5436 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -115,7 +115,7 @@ jobs: with: key: ${{ matrix.test.name }}-${{ steps.toolchain.outputs.cachekey }} - # Don't run out of disk space on Windows. C: has much much space than D:. + # Don't run out of disk space on Windows. C: has much more space than D:. - name: Switch Disk (Windows) if: matrix.platform.name == 'Windows' run: | diff --git a/core/codegen/src/lib.rs b/core/codegen/src/lib.rs index 3b41af8b38..67ef966b56 100644 --- a/core/codegen/src/lib.rs +++ b/core/codegen/src/lib.rs @@ -571,7 +571,7 @@ pub fn launch(args: TokenStream, input: TokenStream) -> TokenStream { /// /// The attribute accepts a single string parameter of name `value` /// corresponding to the string to use to match against for the decorated -/// variant. In the example above, the the strings `"fourth"`, `"FOUrth"`, +/// variant. In the example above, the strings `"fourth"`, `"FOUrth"`, /// `"fiFTH"` and so on would parse as `MyValue::Third`. /// /// [`FromFormField`]: ../rocket/form/trait.FromFormField.html @@ -1403,7 +1403,7 @@ pub fn catchers(input: TokenStream) -> TokenStream { /// /// ## Prefixes and Suffixes /// -/// A route URI can be be optionally prefixed and/or suffixed by a URI generated +/// A route URI can be optionally prefixed and/or suffixed by a URI generated /// from a string literal or an arbitrary expression. This takes the form /// `uri!(prefix, foo(v1, v2, v3), suffix)`, where both `prefix` and `suffix` /// are optional, and either `prefix` or `suffix` may be `_` to specify the diff --git a/core/http/src/parse/uri/parser.rs b/core/http/src/parse/uri/parser.rs index d7bac58b93..cb0c158b2f 100644 --- a/core/http/src/parse/uri/parser.rs +++ b/core/http/src/parse/uri/parser.rs @@ -25,7 +25,7 @@ pub fn complete(input: &mut Pear, p: P) -> input::Result (p()?, eof()?).0 } -/// TODO: Have a way to ask for for preference in ambiguity resolution. +/// TODO: Have a way to ask for preference in ambiguity resolution. /// * An ordered [Preference] is probably best. /// * Need to filter/uniqueify. See `uri-pref`. /// Once we have this, we should probably set the default so that `authority` is diff --git a/core/http/src/uri/fmt/formatter.rs b/core/http/src/uri/fmt/formatter.rs index eca86b7222..71a0d56579 100644 --- a/core/http/src/uri/fmt/formatter.rs +++ b/core/http/src/uri/fmt/formatter.rs @@ -329,7 +329,7 @@ impl Formatter<'_, Query> { // by recursive (nested) calls to `write_raw`. The string is // pushed in `PrefixGuard` here and then popped in `Drop`. // `prefixes` is modified nowhere else, and no concrete-lifetime - // strings leak from the the vector. As a result, it is + // strings leak from the vector. As a result, it is // impossible for a `prefix` to be accessed incorrectly as: // // * Rust _guarantees_ `prefix` is valid for this method diff --git a/core/lib/src/catcher/catcher.rs b/core/lib/src/catcher/catcher.rs index 2aa1402ada..6cae0da590 100644 --- a/core/lib/src/catcher/catcher.rs +++ b/core/lib/src/catcher/catcher.rs @@ -12,7 +12,7 @@ use crate::catcher::{Handler, BoxFuture}; /// /// Catchers are routes that run when errors are produced by the application. /// They consist of a [`Handler`] and an optional status code to match against -/// arising errors. Errors arise from the the following sources: +/// arising errors. Errors arise from the following sources: /// /// * A failing guard. /// * A failing responder. @@ -220,7 +220,7 @@ impl Catcher { /// Prefix `base` to the current `base` in `self.` /// - /// If the the current base is `/`, then the base is replaced by `base`. + /// If the current base is `/`, then the base is replaced by `base`. /// Otherwise, `base` is prefixed to the existing `base`. /// /// ```rust diff --git a/core/lib/src/outcome.rs b/core/lib/src/outcome.rs index 35521aa36a..39d6175875 100644 --- a/core/lib/src/outcome.rs +++ b/core/lib/src/outcome.rs @@ -101,7 +101,7 @@ use self::Outcome::*; pub enum Outcome { /// Contains the success value. Success(S), - /// Contains the error error value. + /// Contains the error value. Error(E), /// Contains the value to forward on. Forward(F), diff --git a/core/lib/src/route/route.rs b/core/lib/src/route/route.rs index 8c28395b00..1b4a34109b 100644 --- a/core/lib/src/route/route.rs +++ b/core/lib/src/route/route.rs @@ -263,7 +263,7 @@ impl Route { /// Prefix `base` to any existing mount point base in `self`. /// - /// If the the current mount point base is `/`, then the base is replaced by + /// If the current mount point base is `/`, then the base is replaced by /// `base`. Otherwise, `base` is prefixed to the existing `base`. /// /// ```rust diff --git a/examples/tls/src/redirector.rs b/examples/tls/src/redirector.rs index c773e59e81..461d23d666 100644 --- a/examples/tls/src/redirector.rs +++ b/examples/tls/src/redirector.rs @@ -36,7 +36,7 @@ impl Redirector { Redirector(port) } - // Launch an instance of Rocket than handles redirection on `self.port`. + // Launch an instance of Rocket that handles redirection on `self.port`. pub async fn try_launch(self, config: Config) -> Result, Error> { rocket::span_info!("HTTP -> HTTPS Redirector" => { info!(from = self.0, to = config.tls_addr.port(), "redirecting");