pub struct P<T: ?Sized> { /* private fields */ }
Expand description
An owned smart pointer.
See the [module level documentation][crate::ptr] for details.
Implementations§
Source§impl<T: 'static> P<T>
impl<T: 'static> P<T>
Sourcepub fn and_then<U, F>(self, f: F) -> Uwhere
F: FnOnce(T) -> U,
pub fn and_then<U, F>(self, f: F) -> Uwhere
F: FnOnce(T) -> U,
Move out of the pointer.
Intended for chaining transformations not covered by map
.
Sourcepub fn into_inner(self) -> T
pub fn into_inner(self) -> T
Equivalent to and_then(|x| x)
.
Sourcepub fn map<F>(self, f: F) -> P<T>where
F: FnOnce(T) -> T,
pub fn map<F>(self, f: F) -> P<T>where
F: FnOnce(T) -> T,
Produce a new P<T>
from self
without reallocating.
Sourcepub fn filter_map<F>(self, f: F) -> Option<P<T>>
pub fn filter_map<F>(self, f: F) -> Option<P<T>>
Optionally produce a new P<T>
from self
without reallocating.
Sourcepub fn metadata_mut(&mut self) -> &mut Metadata
pub fn metadata_mut(&mut self) -> &mut Metadata
Gets the metadata mutably
Trait Implementations§
Source§impl AstVisitable for P<ArrayAccessNode>
impl AstVisitable for P<ArrayAccessNode>
Source§impl AstVisitable for P<ArrayNode>
impl AstVisitable for P<ArrayNode>
Source§impl AstVisitable for P<AssignmentNode>
impl AstVisitable for P<AssignmentNode>
Source§impl AstVisitable for P<BinaryOperationNode>
impl AstVisitable for P<BinaryOperationNode>
Source§impl AstVisitable for P<BlockNode>
impl AstVisitable for P<BlockNode>
Source§impl AstVisitable for P<ControlFlowNode>
impl AstVisitable for P<ControlFlowNode>
Source§impl AstVisitable for P<FunctionCallNode>
impl AstVisitable for P<FunctionCallNode>
Source§impl AstVisitable for P<FunctionNode>
impl AstVisitable for P<FunctionNode>
Source§impl AstVisitable for P<IdentifierNode>
impl AstVisitable for P<IdentifierNode>
Source§impl AstVisitable for P<LiteralNode>
impl AstVisitable for P<LiteralNode>
Source§impl AstVisitable for P<MemberAccessNode>
impl AstVisitable for P<MemberAccessNode>
Source§impl AstVisitable for P<NewArrayNode>
impl AstVisitable for P<NewArrayNode>
Source§impl AstVisitable for P<NewNode>
impl AstVisitable for P<NewNode>
Source§impl AstVisitable for P<PhiArrayNode>
impl AstVisitable for P<PhiArrayNode>
Source§impl AstVisitable for P<PhiNode>
impl AstVisitable for P<PhiNode>
Source§impl AstVisitable for P<RangeNode>
impl AstVisitable for P<RangeNode>
Source§impl AstVisitable for P<ReturnNode>
impl AstVisitable for P<ReturnNode>
Source§impl AstVisitable for P<UnaryOperationNode>
impl AstVisitable for P<UnaryOperationNode>
Source§impl AstVisitable for P<VirtualBranchNode>
impl AstVisitable for P<VirtualBranchNode>
Source§impl<'de, T> Deserialize<'de> for P<T>where
T: Deserialize<'de> + ?Sized,
impl<'de, T> Deserialize<'de> for P<T>where
T: Deserialize<'de> + ?Sized,
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl From<ArrayAccessNode> for P<AstKind>
impl From<ArrayAccessNode> for P<AstKind>
Source§fn from(id: ArrayAccessNode) -> Self
fn from(id: ArrayAccessNode) -> Self
Converts to this type from the input type.
Source§impl From<ArrayAccessNode> for P<ExprKind>
impl From<ArrayAccessNode> for P<ExprKind>
Source§fn from(id: ArrayAccessNode) -> Self
fn from(id: ArrayAccessNode) -> Self
Converts to this type from the input type.
Source§impl From<AssignmentNode> for P<AstKind>
impl From<AssignmentNode> for P<AstKind>
Source§fn from(id: AssignmentNode) -> Self
fn from(id: AssignmentNode) -> Self
Converts to this type from the input type.
Source§impl From<AssignmentNode> for P<StatementKind>
impl From<AssignmentNode> for P<StatementKind>
Source§fn from(id: AssignmentNode) -> Self
fn from(id: AssignmentNode) -> Self
Converts to this type from the input type.
Source§impl From<BinaryOperationNode> for P<AstKind>
impl From<BinaryOperationNode> for P<AstKind>
Source§fn from(id: BinaryOperationNode) -> Self
fn from(id: BinaryOperationNode) -> Self
Converts to this type from the input type.
Source§impl From<BinaryOperationNode> for P<ExprKind>
impl From<BinaryOperationNode> for P<ExprKind>
Source§fn from(id: BinaryOperationNode) -> Self
fn from(id: BinaryOperationNode) -> Self
Converts to this type from the input type.
Source§impl From<ControlFlowNode> for P<AstKind>
impl From<ControlFlowNode> for P<AstKind>
Source§fn from(id: ControlFlowNode) -> Self
fn from(id: ControlFlowNode) -> Self
Converts to this type from the input type.
Source§impl From<FunctionCallNode> for P<AstKind>
impl From<FunctionCallNode> for P<AstKind>
Source§fn from(id: FunctionCallNode) -> Self
fn from(id: FunctionCallNode) -> Self
Converts to this type from the input type.
Source§impl From<FunctionCallNode> for P<ExprKind>
impl From<FunctionCallNode> for P<ExprKind>
Source§fn from(id: FunctionCallNode) -> Self
fn from(id: FunctionCallNode) -> Self
Converts to this type from the input type.
Source§impl From<FunctionNode> for P<AstKind>
impl From<FunctionNode> for P<AstKind>
Source§fn from(id: FunctionNode) -> Self
fn from(id: FunctionNode) -> Self
Converts to this type from the input type.
Source§impl From<IdentifierNode> for P<AstKind>
impl From<IdentifierNode> for P<AstKind>
Source§fn from(id: IdentifierNode) -> Self
fn from(id: IdentifierNode) -> Self
Converts to this type from the input type.
Source§impl From<IdentifierNode> for P<ExprKind>
impl From<IdentifierNode> for P<ExprKind>
Source§fn from(id: IdentifierNode) -> Self
fn from(id: IdentifierNode) -> Self
Converts to this type from the input type.
Source§impl From<MemberAccessNode> for P<AstKind>
impl From<MemberAccessNode> for P<AstKind>
Source§fn from(id: MemberAccessNode) -> Self
fn from(id: MemberAccessNode) -> Self
Converts to this type from the input type.
Source§impl From<MemberAccessNode> for P<ExprKind>
impl From<MemberAccessNode> for P<ExprKind>
Source§fn from(id: MemberAccessNode) -> Self
fn from(id: MemberAccessNode) -> Self
Converts to this type from the input type.
Source§impl From<NewArrayNode> for P<AstKind>
impl From<NewArrayNode> for P<AstKind>
Source§fn from(id: NewArrayNode) -> Self
fn from(id: NewArrayNode) -> Self
Converts to this type from the input type.
Source§impl From<NewArrayNode> for P<ExprKind>
impl From<NewArrayNode> for P<ExprKind>
Source§fn from(id: NewArrayNode) -> Self
fn from(id: NewArrayNode) -> Self
Converts to this type from the input type.
Source§impl From<P<ArrayAccessNode>> for AstKind
impl From<P<ArrayAccessNode>> for AstKind
Source§fn from(id: P<ArrayAccessNode>) -> Self
fn from(id: P<ArrayAccessNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<ArrayAccessNode>> for ExprKind
impl From<P<ArrayAccessNode>> for ExprKind
Source§fn from(id: P<ArrayAccessNode>) -> Self
fn from(id: P<ArrayAccessNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<ArrayAccessNode>> for P<AstKind>
impl From<P<ArrayAccessNode>> for P<AstKind>
Source§fn from(id: P<ArrayAccessNode>) -> Self
fn from(id: P<ArrayAccessNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<ArrayAccessNode>> for P<ExprKind>
impl From<P<ArrayAccessNode>> for P<ExprKind>
Source§fn from(id: P<ArrayAccessNode>) -> Self
fn from(id: P<ArrayAccessNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<AssignmentNode>> for AstKind
impl From<P<AssignmentNode>> for AstKind
Source§fn from(id: P<AssignmentNode>) -> Self
fn from(id: P<AssignmentNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<AssignmentNode>> for P<AstKind>
impl From<P<AssignmentNode>> for P<AstKind>
Source§fn from(id: P<AssignmentNode>) -> Self
fn from(id: P<AssignmentNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<AssignmentNode>> for P<StatementKind>
impl From<P<AssignmentNode>> for P<StatementKind>
Source§fn from(id: P<AssignmentNode>) -> Self
fn from(id: P<AssignmentNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<AssignmentNode>> for StatementKind
impl From<P<AssignmentNode>> for StatementKind
Source§fn from(id: P<AssignmentNode>) -> Self
fn from(id: P<AssignmentNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<BinaryOperationNode>> for AstKind
impl From<P<BinaryOperationNode>> for AstKind
Source§fn from(id: P<BinaryOperationNode>) -> Self
fn from(id: P<BinaryOperationNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<BinaryOperationNode>> for ExprKind
impl From<P<BinaryOperationNode>> for ExprKind
Source§fn from(id: P<BinaryOperationNode>) -> Self
fn from(id: P<BinaryOperationNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<BinaryOperationNode>> for P<AstKind>
impl From<P<BinaryOperationNode>> for P<AstKind>
Source§fn from(id: P<BinaryOperationNode>) -> Self
fn from(id: P<BinaryOperationNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<BinaryOperationNode>> for P<ExprKind>
impl From<P<BinaryOperationNode>> for P<ExprKind>
Source§fn from(id: P<BinaryOperationNode>) -> Self
fn from(id: P<BinaryOperationNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<ControlFlowNode>> for AstKind
impl From<P<ControlFlowNode>> for AstKind
Source§fn from(id: P<ControlFlowNode>) -> Self
fn from(id: P<ControlFlowNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<ControlFlowNode>> for P<AstKind>
impl From<P<ControlFlowNode>> for P<AstKind>
Source§fn from(id: P<ControlFlowNode>) -> Self
fn from(id: P<ControlFlowNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<FunctionCallNode>> for AstKind
impl From<P<FunctionCallNode>> for AstKind
Source§fn from(id: P<FunctionCallNode>) -> Self
fn from(id: P<FunctionCallNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<FunctionCallNode>> for ExprKind
impl From<P<FunctionCallNode>> for ExprKind
Source§fn from(id: P<FunctionCallNode>) -> Self
fn from(id: P<FunctionCallNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<FunctionCallNode>> for P<AstKind>
impl From<P<FunctionCallNode>> for P<AstKind>
Source§fn from(id: P<FunctionCallNode>) -> Self
fn from(id: P<FunctionCallNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<FunctionCallNode>> for P<ExprKind>
impl From<P<FunctionCallNode>> for P<ExprKind>
Source§fn from(id: P<FunctionCallNode>) -> Self
fn from(id: P<FunctionCallNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<FunctionNode>> for AstKind
impl From<P<FunctionNode>> for AstKind
Source§fn from(id: P<FunctionNode>) -> Self
fn from(id: P<FunctionNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<FunctionNode>> for P<AstKind>
impl From<P<FunctionNode>> for P<AstKind>
Source§fn from(id: P<FunctionNode>) -> Self
fn from(id: P<FunctionNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<IdentifierNode>> for AstKind
impl From<P<IdentifierNode>> for AstKind
Source§fn from(id: P<IdentifierNode>) -> Self
fn from(id: P<IdentifierNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<IdentifierNode>> for ExprKind
impl From<P<IdentifierNode>> for ExprKind
Source§fn from(id: P<IdentifierNode>) -> Self
fn from(id: P<IdentifierNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<IdentifierNode>> for P<AstKind>
impl From<P<IdentifierNode>> for P<AstKind>
Source§fn from(id: P<IdentifierNode>) -> Self
fn from(id: P<IdentifierNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<IdentifierNode>> for P<ExprKind>
impl From<P<IdentifierNode>> for P<ExprKind>
Source§fn from(id: P<IdentifierNode>) -> Self
fn from(id: P<IdentifierNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<MemberAccessNode>> for AstKind
impl From<P<MemberAccessNode>> for AstKind
Source§fn from(id: P<MemberAccessNode>) -> Self
fn from(id: P<MemberAccessNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<MemberAccessNode>> for ExprKind
impl From<P<MemberAccessNode>> for ExprKind
Source§fn from(id: P<MemberAccessNode>) -> Self
fn from(id: P<MemberAccessNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<MemberAccessNode>> for P<AstKind>
impl From<P<MemberAccessNode>> for P<AstKind>
Source§fn from(id: P<MemberAccessNode>) -> Self
fn from(id: P<MemberAccessNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<MemberAccessNode>> for P<ExprKind>
impl From<P<MemberAccessNode>> for P<ExprKind>
Source§fn from(id: P<MemberAccessNode>) -> Self
fn from(id: P<MemberAccessNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<NewArrayNode>> for AstKind
impl From<P<NewArrayNode>> for AstKind
Source§fn from(id: P<NewArrayNode>) -> Self
fn from(id: P<NewArrayNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<NewArrayNode>> for ExprKind
impl From<P<NewArrayNode>> for ExprKind
Source§fn from(id: P<NewArrayNode>) -> Self
fn from(id: P<NewArrayNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<NewArrayNode>> for P<AstKind>
impl From<P<NewArrayNode>> for P<AstKind>
Source§fn from(id: P<NewArrayNode>) -> Self
fn from(id: P<NewArrayNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<NewArrayNode>> for P<ExprKind>
impl From<P<NewArrayNode>> for P<ExprKind>
Source§fn from(id: P<NewArrayNode>) -> Self
fn from(id: P<NewArrayNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<PhiArrayNode>> for ArrayKind
impl From<P<PhiArrayNode>> for ArrayKind
Source§fn from(id: P<PhiArrayNode>) -> Self
fn from(id: P<PhiArrayNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<PhiArrayNode>> for AstKind
impl From<P<PhiArrayNode>> for AstKind
Source§fn from(id: P<PhiArrayNode>) -> Self
fn from(id: P<PhiArrayNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<PhiArrayNode>> for ExprKind
impl From<P<PhiArrayNode>> for ExprKind
Source§fn from(id: P<PhiArrayNode>) -> Self
fn from(id: P<PhiArrayNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<PhiArrayNode>> for P<ArrayKind>
impl From<P<PhiArrayNode>> for P<ArrayKind>
Source§fn from(id: P<PhiArrayNode>) -> Self
fn from(id: P<PhiArrayNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<PhiArrayNode>> for P<AstKind>
impl From<P<PhiArrayNode>> for P<AstKind>
Source§fn from(id: P<PhiArrayNode>) -> Self
fn from(id: P<PhiArrayNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<PhiArrayNode>> for P<ExprKind>
impl From<P<PhiArrayNode>> for P<ExprKind>
Source§fn from(id: P<PhiArrayNode>) -> Self
fn from(id: P<PhiArrayNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<ReturnNode>> for AstKind
impl From<P<ReturnNode>> for AstKind
Source§fn from(id: P<ReturnNode>) -> Self
fn from(id: P<ReturnNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<ReturnNode>> for P<AstKind>
impl From<P<ReturnNode>> for P<AstKind>
Source§fn from(id: P<ReturnNode>) -> Self
fn from(id: P<ReturnNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<ReturnNode>> for P<StatementKind>
impl From<P<ReturnNode>> for P<StatementKind>
Source§fn from(id: P<ReturnNode>) -> Self
fn from(id: P<ReturnNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<ReturnNode>> for StatementKind
impl From<P<ReturnNode>> for StatementKind
Source§fn from(id: P<ReturnNode>) -> Self
fn from(id: P<ReturnNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<UnaryOperationNode>> for AstKind
impl From<P<UnaryOperationNode>> for AstKind
Source§fn from(id: P<UnaryOperationNode>) -> Self
fn from(id: P<UnaryOperationNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<UnaryOperationNode>> for ExprKind
impl From<P<UnaryOperationNode>> for ExprKind
Source§fn from(id: P<UnaryOperationNode>) -> Self
fn from(id: P<UnaryOperationNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<UnaryOperationNode>> for P<AstKind>
impl From<P<UnaryOperationNode>> for P<AstKind>
Source§fn from(id: P<UnaryOperationNode>) -> Self
fn from(id: P<UnaryOperationNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<UnaryOperationNode>> for P<ExprKind>
impl From<P<UnaryOperationNode>> for P<ExprKind>
Source§fn from(id: P<UnaryOperationNode>) -> Self
fn from(id: P<UnaryOperationNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<VirtualBranchNode>> for AstKind
impl From<P<VirtualBranchNode>> for AstKind
Source§fn from(id: P<VirtualBranchNode>) -> Self
fn from(id: P<VirtualBranchNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<VirtualBranchNode>> for P<AstKind>
impl From<P<VirtualBranchNode>> for P<AstKind>
Source§fn from(id: P<VirtualBranchNode>) -> Self
fn from(id: P<VirtualBranchNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<VirtualBranchNode>> for P<StatementKind>
impl From<P<VirtualBranchNode>> for P<StatementKind>
Source§fn from(id: P<VirtualBranchNode>) -> Self
fn from(id: P<VirtualBranchNode>) -> Self
Converts to this type from the input type.
Source§impl From<P<VirtualBranchNode>> for StatementKind
impl From<P<VirtualBranchNode>> for StatementKind
Source§fn from(id: P<VirtualBranchNode>) -> Self
fn from(id: P<VirtualBranchNode>) -> Self
Converts to this type from the input type.
Source§impl From<PhiArrayNode> for P<ArrayKind>
impl From<PhiArrayNode> for P<ArrayKind>
Source§fn from(id: PhiArrayNode) -> Self
fn from(id: PhiArrayNode) -> Self
Converts to this type from the input type.
Source§impl From<PhiArrayNode> for P<AstKind>
impl From<PhiArrayNode> for P<AstKind>
Source§fn from(id: PhiArrayNode) -> Self
fn from(id: PhiArrayNode) -> Self
Converts to this type from the input type.
Source§impl From<PhiArrayNode> for P<ExprKind>
impl From<PhiArrayNode> for P<ExprKind>
Source§fn from(id: PhiArrayNode) -> Self
fn from(id: PhiArrayNode) -> Self
Converts to this type from the input type.
Source§impl From<ReturnNode> for P<AstKind>
impl From<ReturnNode> for P<AstKind>
Source§fn from(id: ReturnNode) -> Self
fn from(id: ReturnNode) -> Self
Converts to this type from the input type.
Source§impl From<ReturnNode> for P<StatementKind>
impl From<ReturnNode> for P<StatementKind>
Source§fn from(id: ReturnNode) -> Self
fn from(id: ReturnNode) -> Self
Converts to this type from the input type.
Source§impl From<UnaryOperationNode> for P<AstKind>
impl From<UnaryOperationNode> for P<AstKind>
Source§fn from(id: UnaryOperationNode) -> Self
fn from(id: UnaryOperationNode) -> Self
Converts to this type from the input type.
Source§impl From<UnaryOperationNode> for P<ExprKind>
impl From<UnaryOperationNode> for P<ExprKind>
Source§fn from(id: UnaryOperationNode) -> Self
fn from(id: UnaryOperationNode) -> Self
Converts to this type from the input type.
Source§impl From<VirtualBranchNode> for P<AstKind>
impl From<VirtualBranchNode> for P<AstKind>
Source§fn from(id: VirtualBranchNode) -> Self
fn from(id: VirtualBranchNode) -> Self
Converts to this type from the input type.
Source§impl From<VirtualBranchNode> for P<StatementKind>
impl From<VirtualBranchNode> for P<StatementKind>
Source§fn from(id: VirtualBranchNode) -> Self
fn from(id: VirtualBranchNode) -> Self
Converts to this type from the input type.
Source§impl<T> FromIterator<T> for P<[T]>
impl<T> FromIterator<T> for P<[T]>
Source§impl<'a, T> IntoIterator for &'a P<[T]>
impl<'a, T> IntoIterator for &'a P<[T]>
Source§impl<T> IntoIterator for P<[T]>
impl<T> IntoIterator for P<[T]>
impl<T: Eq> Eq for P<T>
Auto Trait Implementations§
impl<T> Freeze for P<T>where
T: ?Sized,
impl<T> RefUnwindSafe for P<T>where
T: RefUnwindSafe + ?Sized,
impl<T> Send for P<T>
impl<T> Sync for P<T>
impl<T> Unpin for P<T>where
T: ?Sized,
impl<T> UnwindSafe for P<T>where
T: UnwindSafe + ?Sized,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.