From 1dc6a8b04ae1da1b438e06a27ddb988e9a166ec5 Mon Sep 17 00:00:00 2001 From: Tom French <15848336+TomAFrench@users.noreply.github.com> Date: Tue, 18 Feb 2025 18:11:56 +0000 Subject: [PATCH] chore: redo typo PR by maximevtush (#7425) --- compiler/noirc_frontend/src/hir/comptime/errors.rs | 2 +- .../compile_failure/primary_attribute_struct/src/main.nr | 2 +- .../compile_success_empty/trait_method_mut_self/src/main.nr | 2 +- .../execution_success/brillig_conditional/src/main.nr | 2 +- tooling/lsp/src/requests/completion.rs | 4 ++-- tooling/lsp/src/requests/completion/tests.rs | 2 +- 6 files changed, 7 insertions(+), 7 deletions(-) diff --git a/compiler/noirc_frontend/src/hir/comptime/errors.rs b/compiler/noirc_frontend/src/hir/comptime/errors.rs index 8f4bcbcca25..64297a24062 100644 --- a/compiler/noirc_frontend/src/hir/comptime/errors.rs +++ b/compiler/noirc_frontend/src/hir/comptime/errors.rs @@ -658,7 +658,7 @@ impl<'a> From<&'a InterpreterError> for CustomDiagnostic { } InterpreterError::GenericNameShouldBeAnIdent { name, location } => { let msg = - "Generic name needs to be a valid identifer (one word beginning with a letter)" + "Generic name needs to be a valid identifier (one word beginning with a letter)" .to_string(); let secondary = format!("`{name}` is not a valid identifier"); CustomDiagnostic::simple_error(msg, secondary, location.span) diff --git a/test_programs/compile_failure/primary_attribute_struct/src/main.nr b/test_programs/compile_failure/primary_attribute_struct/src/main.nr index 8922ef60091..be443e1c7ab 100644 --- a/test_programs/compile_failure/primary_attribute_struct/src/main.nr +++ b/test_programs/compile_failure/primary_attribute_struct/src/main.nr @@ -1,4 +1,4 @@ -// An primary attribute should not be able to be added to a struct defintion +// An primary attribute should not be able to be added to a struct definition #[oracle(some_oracle)] struct SomeStruct{ x: Field, diff --git a/test_programs/compile_success_empty/trait_method_mut_self/src/main.nr b/test_programs/compile_success_empty/trait_method_mut_self/src/main.nr index aa0baab7f89..6497eafac23 100644 --- a/test_programs/compile_success_empty/trait_method_mut_self/src/main.nr +++ b/test_programs/compile_success_empty/trait_method_mut_self/src/main.nr @@ -71,7 +71,7 @@ where { // Check that we can call a trait method instead of a trait implementation // TODO: Need to remove the need for this type annotation - // TODO: Curently, without the annotation we will get `Expression type is ambiguous` when trying to use the `hasher` + // TODO: Currently, without the annotation we will get `Expression type is ambiguous` when trying to use the `hasher` let mut hasher: H = H::default(); // Regression that the object is converted to a mutable reference type `&mut _`. // Otherwise will see `Expected type &mut _, found type H`. diff --git a/test_programs/execution_success/brillig_conditional/src/main.nr b/test_programs/execution_success/brillig_conditional/src/main.nr index c815d9966fe..5d61abe6aac 100644 --- a/test_programs/execution_success/brillig_conditional/src/main.nr +++ b/test_programs/execution_success/brillig_conditional/src/main.nr @@ -1,6 +1,6 @@ // Tests a very simple program. // -// The features being tested is basic conditonal on brillig +// The features being tested is basic conditional on brillig fn main(x: Field) { // Safety: testing context unsafe { diff --git a/tooling/lsp/src/requests/completion.rs b/tooling/lsp/src/requests/completion.rs index b464c3e7adc..46a0cbd651c 100644 --- a/tooling/lsp/src/requests/completion.rs +++ b/tooling/lsp/src/requests/completion.rs @@ -1133,7 +1133,7 @@ impl<'a> NodeFinder<'a> { /// Try to suggest the name of a module to declare based on which /// files exist in the filesystem, excluding modules that are already declared. - fn complete_module_delcaration(&mut self, module: &ModuleDeclaration) -> Option<()> { + fn complete_module_declaration(&mut self, module: &ModuleDeclaration) -> Option<()> { let filename = self.files.get_absolute_name(self.file).ok()?.into_path_buf(); let is_main_lib_or_mod = filename.ends_with("main.nr") @@ -1869,7 +1869,7 @@ impl<'a> Visitor for NodeFinder<'a> { return; } - self.complete_module_delcaration(module); + self.complete_module_declaration(module); } } diff --git a/tooling/lsp/src/requests/completion/tests.rs b/tooling/lsp/src/requests/completion/tests.rs index f670f26ffeb..eb513f37daf 100644 --- a/tooling/lsp/src/requests/completion/tests.rs +++ b/tooling/lsp/src/requests/completion/tests.rs @@ -2345,7 +2345,7 @@ fn main() { } #[test] - async fn test_auto_import_suggests_private_function_if_visibile() { + async fn test_auto_import_suggests_private_function_if_visible() { let src = r#" mod foo { fn qux() {