Trait StrExt

Source
pub trait StrExt {
    type Owned: Borrow<Self>;

    // Required methods
    fn is_valid_ident(&self) -> bool;
    fn to_valid_ident(&self) -> Self::Owned;
}

Required Associated Types§

Source

type Owned: Borrow<Self>

Required Methods§

Source

fn is_valid_ident(&self) -> bool

Source

fn to_valid_ident(&self) -> Self::Owned

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl StrExt for str

Source§

impl StrExt for CStr

Source§

impl StrExt for OsStr

Implementors§