🎨 Unifica conversiones a String con to_string()
Como `String::from()` y `.to_string()` son equivalentes, se sustituyen todas las ocurrencias de `String::from()` por `to_string()` para mayor coherencia y legibilidad.
This commit is contained in:
parent
b16c9378d0
commit
7179cf0831
12 changed files with 29 additions and 29 deletions
|
|
@ -17,13 +17,13 @@ use crate::{builder_fn, AutoDefault};
|
|||
/// // Español disponible.
|
||||
/// assert_eq!(
|
||||
/// hello.lookup(&LangMatch::resolve("es-ES")),
|
||||
/// Some(String::from("¡Hola mundo!"))
|
||||
/// Some("¡Hola mundo!".to_string())
|
||||
/// );
|
||||
///
|
||||
/// // Japonés no disponible, traduce al idioma de respaldo ("en-US").
|
||||
/// assert_eq!(
|
||||
/// hello.lookup(&LangMatch::resolve("ja-JP")),
|
||||
/// Some(String::from("Hello world!"))
|
||||
/// Some("Hello world!".to_string())
|
||||
/// );
|
||||
///
|
||||
/// // Uso típico en un atributo:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue