Skip to content

RepeatPattern

kareman edited this page Aug 13, 2020 · 4 revisions

RepeatPattern

Repeats the wrapped pattern min times, then repeats it optionally max-min times. Or an unlimited number of times if max is nil.

public struct RepeatPattern<Wrapped:​ Pattern>:​ Pattern

Used by operators *+¿.

Inheritance

Pattern, RegexConvertible

Nested Type Aliases

Input

public typealias Input = Wrapped.Input

Properties

wrapped

let wrapped:​ Wrapped

min

let min:​ Int

max

let max:​ Int?

description

var description:​ String

Methods

createInstructions(_:​)

@inlinable public func createInstructions(_ instructions:inout ContiguousArray<Instruction<Input>>) throws
Clone this wiki locally