From f82ce500a9c72a4153850f15e17b60388e95b2af Mon Sep 17 00:00:00 2001 From: Lukas Wirth Date: Wed, 3 Feb 2021 13:40:24 +0100 Subject: Fix spelling mistakes in docs/dev --- docs/dev/style.md | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'docs/dev/style.md') diff --git a/docs/dev/style.md b/docs/dev/style.md index e2f1b6996..0482bc190 100644 --- a/docs/dev/style.md +++ b/docs/dev/style.md @@ -159,7 +159,7 @@ Express function preconditions in types and force the caller to provide them (ra ```rust // GOOD -fn frbonicate(walrus: Walrus) { +fn frobnicate(walrus: Walrus) { ... } @@ -374,7 +374,7 @@ Avoid making a lot of code type parametric, *especially* on the boundaries betwe ```rust // GOOD -fn frbonicate(f: impl FnMut()) { +fn frobnicate(f: impl FnMut()) { frobnicate_impl(&mut f) } fn frobnicate_impl(f: &mut dyn FnMut()) { @@ -382,7 +382,7 @@ fn frobnicate_impl(f: &mut dyn FnMut()) { } // BAD -fn frbonicate(f: impl FnMut()) { +fn frobnicate(f: impl FnMut()) { // lots of code } ``` @@ -391,11 +391,11 @@ Avoid `AsRef` polymorphism, it pays back only for widely used libraries: ```rust // GOOD -fn frbonicate(f: &Path) { +fn frobnicate(f: &Path) { } // BAD -fn frbonicate(f: impl AsRef) { +fn frobnicate(f: impl AsRef) { } ``` @@ -705,7 +705,7 @@ fn foo() -> Option { } ``` -**Rationale:** reduce congnitive stack usage. +**Rationale:** reduce cognitive stack usage. ## Comparisons -- cgit v1.2.3