class

Pegmatite::Pattern::Literal

Inherits Pegmatite::Pattern < Pegmatite::DSL::Methods < Reference < Object

Pattern::Literal is used to consume a specific string.

Parsing will fail if the bytes in the stream don't exactly match the string. Otherwise, the pattern succeeds, consuming the matched bytes.

Constructors

new(string : String)
Source

Instance methods

_match(source, offset, state) : MatchResult
Source
description
Source
dsl_name
Source
inspect(io)
Source