Struct yksom::vm::objects::String_[][src]

pub struct String_ { /* fields omitted */ }

Implementations

impl String_[src]

pub fn new_str(vm: &mut VM, s: SmartString) -> Val[src]

pub fn new_sym(vm: &mut VM, s: SmartString) -> Val[src]

pub fn symbol_to_string_(
    vm: &mut VM,
    v: Val
) -> Result<Gc<String_>, Box<VMError>>
[src]

If the value v represents a String_ which is an instance of the SOM Symbol class (and not the SOM String class!), return a reference to the underlying String_ or an InstanceTypeError otherwise.

pub fn as_str(&self) -> &str[src]

pub fn concatenate(
    self: Gc<Self>,
    vm: &mut VM,
    other: Val
) -> Result<Val, Box<VMError>>
[src]

Concatenate this string with another string and return the result.

pub fn substring(
    &self,
    vm: &mut VM,
    start: usize,
    end: usize
) -> Result<Val, Box<VMError>>
[src]

pub fn to_string_(&self, vm: &mut VM) -> Result<Val, Box<VMError>>[src]

pub fn to_symbol(&self, vm: &mut VM) -> Result<Val, Box<VMError>>[src]

pub fn set_cls(&self, cls: Val)[src]

Trait Implementations

impl Debug for String_[src]

impl NotUnboxable for String_[src]

impl Obj for String_[src]

impl StaticObjType for String_[src]

Auto Trait Implementations

impl !NoTrace for String_

impl !RefUnwindSafe for String_

impl Send for String_

impl !Sync for String_

impl Unpin for String_

impl UnwindSafe for String_

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 

type Err = <U as TryFrom<T>>::Err