From 3a5a93595f92d9df7fcb7e70ae26eadafb148f1f Mon Sep 17 00:00:00 2001 From: Frank Steffahn Date: Sun, 22 Aug 2021 14:31:37 +0200 Subject: [PATCH] =?UTF-8?q?Fix=20typos=20=E2=80=9Ca=E2=80=9D=E2=86=92?= =?UTF-8?q?=E2=80=9Can=E2=80=9D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- crates/hir/src/semantics.rs | 4 ++-- crates/hir_ty/src/diagnostics/expr.rs | 2 +- crates/ide_completion/src/completions/trait_impl.rs | 2 +- crates/paths/src/lib.rs | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/crates/hir/src/semantics.rs b/crates/hir/src/semantics.rs index e79021799358..000daf76c25e 100644 --- a/crates/hir/src/semantics.rs +++ b/crates/hir/src/semantics.rs @@ -203,7 +203,7 @@ impl<'db, DB: HirDatabase> Semantics<'db, DB> { self.imp.ancestors_at_offset_with_macros(node, offset) } - /// Find a AstNode by offset inside SyntaxNode, if it is inside *Macrofile*, + /// Find an AstNode by offset inside SyntaxNode, if it is inside *Macrofile*, /// search up until it is of the target AstNode type pub fn find_node_at_offset_with_macros( &self, @@ -213,7 +213,7 @@ impl<'db, DB: HirDatabase> Semantics<'db, DB> { self.imp.ancestors_at_offset_with_macros(node, offset).find_map(N::cast) } - /// Find a AstNode by offset inside SyntaxNode, if it is inside *MacroCall*, + /// Find an AstNode by offset inside SyntaxNode, if it is inside *MacroCall*, /// descend it and find again pub fn find_node_at_offset_with_descend( &self, diff --git a/crates/hir_ty/src/diagnostics/expr.rs b/crates/hir_ty/src/diagnostics/expr.rs index 17de5dfe2a5f..899a8b793db5 100644 --- a/crates/hir_ty/src/diagnostics/expr.rs +++ b/crates/hir_ty/src/diagnostics/expr.rs @@ -280,7 +280,7 @@ impl ExprValidator { for arm in arms { if let Some(pat_ty) = infer.type_of_pat.get(arm.pat) { // We only include patterns whose type matches the type - // of the match expression. If we had a InvalidMatchArmPattern + // of the match expression. If we had an InvalidMatchArmPattern // diagnostic or similar we could raise that in an else // block here. // diff --git a/crates/ide_completion/src/completions/trait_impl.rs b/crates/ide_completion/src/completions/trait_impl.rs index 6ff751418739..9e22dae072ce 100644 --- a/crates/ide_completion/src/completions/trait_impl.rs +++ b/crates/ide_completion/src/completions/trait_impl.rs @@ -1,7 +1,7 @@ //! Completion for associated items in a trait implementation. //! //! This module adds the completion items related to implementing associated -//! items within a `impl Trait for Struct` block. The current context node +//! items within an `impl Trait for Struct` block. The current context node //! must be within either a `FN`, `TYPE_ALIAS`, or `CONST` node //! and an direct child of an `IMPL`. //! diff --git a/crates/paths/src/lib.rs b/crates/paths/src/lib.rs index 14e43bb36137..14747cc72f9e 100644 --- a/crates/paths/src/lib.rs +++ b/crates/paths/src/lib.rs @@ -98,7 +98,7 @@ impl AbsPathBuf { .unwrap_or_else(|path| panic!("expected absolute path, got {}", path.display())) } - /// Coerces to a `AbsPath` slice. + /// Coerces to an `AbsPath` slice. /// /// Equivalent of [`PathBuf::as_path`] for `AbsPathBuf`. pub fn as_path(&self) -> &AbsPath {