Skip to content

Commit 8ff477f

Browse files
authored
chore: fix some typos in comments (#1547)
Signed-off-by: tinyfoolish <[email protected]>
1 parent 0e1d04b commit 8ff477f

File tree

4 files changed

+7
-7
lines changed

4 files changed

+7
-7
lines changed

examples/type_conversion.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ fn main()
1111
{
1212
// Converting an array from one datatype to another is implemented with the
1313
// `ArrayBase::mapv()` function. We pass a closure that is applied to each
14-
// element independently. This allows for more control and flexiblity in
14+
// element independently. This allows for more control and flexibility in
1515
// converting types.
1616
//
1717
// Below, we illustrate four different approaches for the actual conversion

src/impl_owned_array.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -176,7 +176,7 @@ impl<A> Array<A, Ix2>
176176
/// along the "growing axis". However, if the memory layout needs adjusting, the array must
177177
/// reallocate and move memory.
178178
///
179-
/// The operation leaves the existing data in place and is most efficent if one of these is
179+
/// The operation leaves the existing data in place and is most efficient if one of these is
180180
/// true:
181181
///
182182
/// - The axis being appended to is the longest stride axis, i.e the array is in row major
@@ -221,7 +221,7 @@ impl<A> Array<A, Ix2>
221221
/// along the "growing axis". However, if the memory layout needs adjusting, the array must
222222
/// reallocate and move memory.
223223
///
224-
/// The operation leaves the existing data in place and is most efficent if one of these is
224+
/// The operation leaves the existing data in place and is most efficient if one of these is
225225
/// true:
226226
///
227227
/// - The axis being appended to is the longest stride axis, i.e the array is in column major
@@ -510,7 +510,7 @@ where D: Dimension
510510
/// along the "growing axis". However, if the memory layout needs adjusting, the array must
511511
/// reallocate and move memory.
512512
///
513-
/// The operation leaves the existing data in place and is most efficent if `axis` is a
513+
/// The operation leaves the existing data in place and is most efficient if `axis` is a
514514
/// "growing axis" for the array, i.e. one of these is true:
515515
///
516516
/// - The axis is the longest stride axis, for example the 0th axis in a C-layout or the
@@ -566,7 +566,7 @@ where D: Dimension
566566
/// along the "growing axis". However, if the memory layout needs adjusting, the array must
567567
/// reallocate and move memory.
568568
///
569-
/// The operation leaves the existing data in place and is most efficent if `axis` is a
569+
/// The operation leaves the existing data in place and is most efficient if `axis` is a
570570
/// "growing axis" for the array, i.e. one of these is true:
571571
///
572572
/// - The axis is the longest stride axis, for example the 0th axis in a C-layout or the

src/impl_ref_types.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
//! Because raw views do not meet `S: Data`, they cannot dereference to `ArrayRef`; furthermore,
1717
//! technical limitations of Rust's compiler means that `ArrayBase` cannot have multiple `Deref` implementations.
1818
//! In addition, shared-data arrays do not want to go down the `Deref` path to get to methods on `RawRef`
19-
//! or `LayoutRef`, since that would unecessarily ensure their uniqueness.
19+
//! or `LayoutRef`, since that would unnecessarily ensure their uniqueness.
2020
//!
2121
//! To mitigate these problems, `ndarray` also provides `AsRef` and `AsMut` implementations as follows:
2222
//! 1. `ArrayBase` implements `AsRef` to `RawRef` and `LayoutRef` when `S: RawData`

src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1585,7 +1585,7 @@ pub type ArcArray<A, D> = ArrayBase<OwnedArcRepr<A>, D>;
15851585
///
15861586
/// + [Constructor Methods for Owned Arrays](ArrayBase#constructor-methods-for-owned-arrays)
15871587
/// + [Methods For All Array Types](ArrayBase#methods-for-all-array-types)
1588-
/// + Dimensionality-specific type alises
1588+
/// + Dimensionality-specific type aliases
15891589
/// [`Array1`],
15901590
/// [`Array2`],
15911591
/// [`Array3`], ...,

0 commit comments

Comments
 (0)