-
Notifications
You must be signed in to change notification settings - Fork 1
AnyPattern
kareman edited this page Aug 23, 2020
·
5 revisions
A type erased wrapper around a pattern. Can be used to store patterns in arrays and non-generic variables.
public struct AnyPattern<Input: BidirectionalCollection>: Pattern where Input.Element: Hashable
ExpressibleByExtendedGraphemeClusterLiteral
, ExpressibleByStringInterpolation
, ExpressibleByStringLiteral
, ExpressibleByUnicodeScalarLiteral
, Pattern
public init<P: Pattern>(_ p: P) where Input == P.Input
@inlinable public init(_ p: AnyPattern)
public init(_ p: Literal<Input>)
let _instructions: (inout ContiguousArray<Instruction<Input>>) throws -> Void
let _description: () -> String
var description: String
The wrapped pattern. If you know the exact type you can unwrap it again.
let wrapped: Any
@inlinable public func createInstructions(_ instructions: inout ContiguousArray<Instruction<Input>>) throws
public static func ==(lhs: AnyPattern, rhs: AnyPattern) -> Bool
Generated at 2020-08-23T12:56:49+0000 using swift-doc 1.0.0-beta.3.