diff --git a/bin_efo/src/commands/chr.rs b/bin_efo/src/commands/chr.rs index c408224..505af4b 100644 --- a/bin_efo/src/commands/chr.rs +++ b/bin_efo/src/commands/chr.rs @@ -229,13 +229,13 @@ fn handle_create_entity( /// `EpochError::EntityNotFound` if no entity matches. /// /// # Arguments -/// * `entity_args` – The arguments that identify the entity. -/// * `e_type` – The type of entity to look for. -/// * `epoch_info` – The epoch that contains all entities. +/// * `entity_args` - The arguments that identify the entity. +/// * `e_type` - The type of entity to look for. +/// * `epoch_info` - The epoch that contains all entities. /// /// # Returns -/// * `Ok(&Entity)` – The entity that matches the arguments. -/// * `Err(EpochError::EntityNotFound)` – No matching entity was found. +/// * `Ok(&Entity)` - The entity that matches the arguments. +/// * `Err(EpochError::EntityNotFound)` - No matching entity was found. fn find_entity<'a>( entity_args: &'a EntityArgs, e_type: &'a EntityType, @@ -258,8 +258,8 @@ fn find_entity<'a>( /// because of the `todo!()` placeholder. /// /// # Arguments -/// * `e_type` – The type of entities to retrieve. -/// * `epoch_info` – The epoch information containing the collections. +/// * `e_type` - The type of entities to retrieve. +/// * `epoch_info` - The epoch information containing the collections. /// /// # Returns /// A reference to the vector containing the requested entities. @@ -287,8 +287,8 @@ fn vec_entities<'a>( /// based on `e_type`. Unimplemented variants will panic due to the `todo!()`. /// /// # Arguments -/// * `e_type` – The type of entities to retrieve. -/// * `epoch_info` – The epoch information containing the collections. +/// * `e_type` - The type of entities to retrieve. +/// * `epoch_info` - The epoch information containing the collections. /// /// # Returns /// A mutable reference to the vector containing the requested entities. diff --git a/bin_efo/src/commands/generate.rs b/bin_efo/src/commands/generate.rs index 4d2819f..dc37aee 100644 --- a/bin_efo/src/commands/generate.rs +++ b/bin_efo/src/commands/generate.rs @@ -1,18 +1,18 @@ -//! # Generation Sub‑command +//! # Generation Sub-command //! -//! This module implements the `gen` sub‑command used to quickly produce +//! This module implements the `gen` sub-command used to quickly produce //! sample data for the various generators in *lib_efo*. The command has no -//! side‑effects beyond printing the generated data; it is intended for +//! side-effects beyond printing the generated data; it is intended for //! interactive use or for embedding in scripts. //! -//! ## Available sub‑commands +//! ## Available sub-commands //! -//! * `character` – Generate character names (long or short). -//! * `event` – Generate event ideas. -//! * `town` – Generate town names. -//! * `exotic` – Generate exotic character names. +//! * `character` - Generate character names (long or short). +//! * `event` - Generate event ideas. +//! * `town` - Generate town names. +//! * `exotic` - Generate exotic character names. //! -//! Each sub‑command accepts a set of common options (see [`Qty`]) that +//! Each sub-command accepts a set of common options (see [`Qty`]) that //! control how many items are produced and how they are displayed. //! @@ -22,7 +22,7 @@ use lib_efo::{Displayable, error::EpochError, naming::NAMING}; use crate::error::AppError; /// The types of examples to generate. /// -/// Each variant maps directly to a public sub‑command of the `gen` tool. +/// Each variant maps directly to a public sub-command of the `gen` tool. #[derive(Subcommand, Debug)] pub enum GenCmd { /// Generate a character @@ -38,8 +38,8 @@ pub enum GenCmd { #[derive(Args, Debug)] /// Common arguments for the generation subcommands. /// -/// The fields are deliberately named to match the command‑line flags -/// produced by `clap`. The struct is used by all sub‑commands to +/// The fields are deliberately named to match the command-line flags +/// produced by `clap`. The struct is used by all sub-commands to /// keep the CLI surface area minimal. pub struct Qty { /// Amount of entities to generate. diff --git a/lib_efo/src/epoch/epoch_config.rs b/lib_efo/src/epoch/epoch_config.rs index 7bf8ff9..206c2e0 100644 --- a/lib_efo/src/epoch/epoch_config.rs +++ b/lib_efo/src/epoch/epoch_config.rs @@ -88,9 +88,9 @@ impl EpochConfig { /// Initialize the epoch structure in depth. /// - /// Scans the default configuration folder for sub‑directories that are + /// Scans the default configuration folder for sub-directories that are /// interpreted as epoch identifiers, logs each discovered epoch and - /// registers it in the in‑memory cache. + /// registers it in the in-memory cache. /// /// This function may return an error if the configuration folder cannot /// be read or if any directory name cannot be parsed as an `EpochId`. @@ -147,11 +147,11 @@ impl EpochConfig { /// Load the currently active epoch. /// - /// This helper first ensures that the current epoch’s metadata is cached + /// This helper first ensures that the current epoch's metadata is cached /// by delegating to `try_load`, then returns a reference to it. /// /// # Returns - /// * `Ok(&EpochInfo)` – Reference to the cached epoch. + /// * `Ok(&EpochInfo)` - Reference to the cached epoch. /// * Propagates any error from `try_load`. pub fn try_load_current(&mut self) -> Result<&EpochInfo, EpochError> { self.try_load(&self.epoch_id.clone())?; @@ -170,13 +170,13 @@ impl EpochConfig { /// loaded results in undefined behaviour. /// /// # Arguments - /// * `epoch_id` – Identifier of the epoch to load. + /// * `epoch_id` - Identifier of the epoch to load. /// /// # Returns - /// * `Ok(&EpochInfo)` – Reference to the cached epoch. - /// * `Err(EpochError::EpochHashingImpossible(..))` – The identifier is + /// * `Ok(&EpochInfo)` - Reference to the cached epoch. + /// * `Err(EpochError::EpochHashingImpossible(..))` - The identifier is /// unknown. - /// * `Err(EpochError::LoadingEpochId(..))` – The epoch data is not yet + /// * `Err(EpochError::LoadingEpochId(..))` - The epoch data is not yet /// present in the cache. pub unsafe fn try_load_id(&self, epoch_id: EpochId) -> Result<&EpochInfo, EpochError> { let current = self @@ -194,26 +194,26 @@ impl EpochConfig { /// for the current epoch. /// /// # Returns - /// * `Ok(&mut EpochInfo)` – Mutable reference to the cached epoch. + /// * `Ok(&mut EpochInfo)` - Mutable reference to the cached epoch. /// * Propagates any error from the underlying load routine. pub fn try_load_current_as_mut(&mut self) -> Result<&mut EpochInfo, EpochError> { self.try_load_id_as_mut(self.epoch_id) } - /// Load an epoch’s metadata mutably. + /// Load an epoch's metadata mutably. /// /// The function guarantees that the epoch data is present in the cache /// by first invoking `try_load` on the current epoch ID. It then /// retrieves a mutable reference to the requested epoch. /// /// # Arguments - /// * `epoch_id` – Identifier of the epoch to load. + /// * `epoch_id` - Identifier of the epoch to load. /// /// # Returns - /// * `Ok(&mut EpochInfo)` – Mutable reference to the cached epoch. - /// * `Err(EpochError::EpochHashingImpossible(..))` – The identifier is + /// * `Ok(&mut EpochInfo)` - Mutable reference to the cached epoch. + /// * `Err(EpochError::EpochHashingImpossible(..))` - The identifier is /// unknown. - /// * `Err(EpochError::LoadingEpochId(..))` – The epoch data is not yet + /// * `Err(EpochError::LoadingEpochId(..))` - The epoch data is not yet /// present in the cache. /// /// # Notes diff --git a/lib_efo/src/error.rs b/lib_efo/src/error.rs index ba16da4..5fff20f 100644 --- a/lib_efo/src/error.rs +++ b/lib_efo/src/error.rs @@ -234,7 +234,7 @@ pub enum EpochError { help: Option, }, - /// A non‑recoverable error while hashing an epoch identifier. + /// A non-recoverable error while hashing an epoch identifier. /// /// This error should never happen in normal operation. It is surfaced only /// when the hashing routine fails to produce a unique identifier for a diff --git a/lib_efo/src/naming.rs b/lib_efo/src/naming.rs index 17b1249..b9089ef 100644 --- a/lib_efo/src/naming.rs +++ b/lib_efo/src/naming.rs @@ -204,7 +204,7 @@ impl NamingData { .cloned() .collect(); - // Combine with a space – you could also use a hyphen or nothing + // Combine with a space - you could also use a hyphen or nothing format!("{pref}{} {pref2}{}", &first, &last) } }