std.tuple.Tuple1
type pub inline Tuple1[A]A 1-ary tuple.
Fields
0
let pub @0: AInstance methods
!=
Show source codeHide source code
fn pub !=(other: ref Self) -> Bool {
(self == other).false?
}fn pub !=(other: ref Self) -> Bool
if
A: EqualReturns true if self and the given object are not equal to each other.
==
Show source codeHide source code
fn pub ==(other: ref Tuple1[A]) -> Bool {
@0 == other.0
}fn pub ==(other: ref (A)) -> Bool
if
A: EqualReturns true if self and the given object are equal to each other.
This operator is used to perform structural equality. This means two objects residing in different memory locations may be considered equal, provided their structure is equal. For example, two different arrays may be considered to have structural equality if they contain the exact same values.
clone
Show source codeHide source code
fn pub clone -> Tuple1[move A] {
(@0.clone,)
}fn pub clone -> (move A)
if
A: CloneCreates a clone of self.
The returned value is an owned value that is the same type as the receiver
of this method. For example, cloning a ref Array[Int] results in a
Array[Int], not another ref Array[Int].
fmt
Show source codeHide source code
fn pub fmt(formatter: mut Formatter) {
formatter.tuple('').field(@0).finish
}fn pub fmt(formatter: mut Formatter)
if
A: FormatFormats self in a human-readable format for debugging purposes.
hash
Show source codeHide source code
fn pub hash[H: mut + Hasher](hasher: mut H) {
@0.hash(hasher)
}fn pub hash[H: mut + Hasher](hasher: mut H: mut)
if
A: HashWrites the hash for self into the given Hasher.
Implemented traits
Clone
impl Clone for Tuple1
if
A: CloneEqual
impl Equal for Tuple1
if
A: EqualFormat
impl Format for Tuple1
if
A: FormatHash
impl Hash for Tuple1
if
A: Hash