pub trait With<T> {
type Output;
// Required method
fn with(&self, other: &T) -> Self::Output;
}Expand description
With trait provides the ability to concatenate several crate::TuringMachine
into one another Turing machine. This trait must be implemented individual
for machine types if it needs.
Required Associated Types§
Required Methods§
Implementations on Foreign Types§
Source§impl<S: Symbol> With<Classic<S>> for Result<Classic<S>, String>
impl<S: Symbol> With<Classic<S>> for Result<Classic<S>, String>
Source§fn with(&self, other: &Classic<S>) -> Self::Output
fn with(&self, other: &Classic<S>) -> Self::Output
Makes superposition with two or more Classic machines by chain.
This method accept only Classic struct and can be used only for
Result<Classic, String>.
Returns a new [Ok(Classic)] when self is Result::Ok and machines
can be concatenated and [Err(String)] when self is Result::Ok
but machines have different alphabets or default symbols.
And Returns a copy of [Err(String)] when self is Result::Err.