TermBox

private protocol TermBox : Sendable

A box wrapping a term.

  • Hashes the salient parts of the wrapped value into hasher.

    Declaration

    Swift

    func hash(into hasher: inout Hasher)
  • Returns whether the value wrapped inside self is equal to that wrapped inside other.

    Declaration

    Swift

    func equals<Other>(_ other: Other) -> Bool where Other : TermBox
  • Returns the value wrapped inside self with its type erased.

    Declaration

    Swift

    func unwrap() -> any TermProtocol
  • Returns the value wrapped inside self as an instance of T or nil if that value has a different type.

    Declaration

    Swift

    func unwrap<T>(as: T.Type) -> T? where T : TermProtocol