class Rsec::Maybe
the content appears 1 or 0 time
Public Instance Methods
_parse(ctx)
click to toggle source
# File lib/rsec/parsers/repeat.rb, line 5 def _parse ctx save = ctx.pos res = some._parse ctx if INVALID[res] ctx.pos = save [] else [res] end end