Update parser files of RDoc generated by the latest KPeg

This commit is contained in:
aycabta 2021-08-10 02:35:33 +09:00
Родитель 6b439e9c4e
Коммит 44635ebe9a
2 изменённых файлов: 46 добавлений и 48 удалений

Просмотреть файл

@ -344,9 +344,8 @@ class RDoc::Markdown
end
def scan(reg)
if m = reg.match(@string[@pos..-1])
width = m.end(0)
@pos += width
if m = reg.match(@string, @pos)
@pos = m.end(0)
return true
end
@ -1060,7 +1059,7 @@ class RDoc::Markdown
self.pos = _save3
break
end
_tmp = scan(/\A(?-mix:#*)/)
_tmp = scan(/\G(?-mix:#*)/)
unless _tmp
self.pos = _save3
break
@ -1100,7 +1099,7 @@ class RDoc::Markdown
_save = self.pos
while true # sequence
_text_start = self.pos
_tmp = scan(/\A(?-mix:\#{1,6})/)
_tmp = scan(/\G(?-mix:\#{1,6})/)
if _tmp
text = get_text(_text_start)
end
@ -1165,7 +1164,7 @@ class RDoc::Markdown
self.pos = _save3
break
end
_tmp = scan(/\A(?-mix:#*)/)
_tmp = scan(/\G(?-mix:#*)/)
unless _tmp
self.pos = _save3
break
@ -1225,7 +1224,7 @@ class RDoc::Markdown
_save = self.pos
while true # sequence
_tmp = scan(/\A(?-mix:={1,})/)
_tmp = scan(/\G(?-mix:={1,})/)
unless _tmp
self.pos = _save
break
@ -1246,7 +1245,7 @@ class RDoc::Markdown
_save = self.pos
while true # sequence
_tmp = scan(/\A(?-mix:-{1,})/)
_tmp = scan(/\G(?-mix:-{1,})/)
unless _tmp
self.pos = _save
break
@ -2130,7 +2129,7 @@ class RDoc::Markdown
self.pos = _save
break
end
_tmp = scan(/\A(?-mix:[+*-])/)
_tmp = scan(/\G(?-mix:[+*-])/)
unless _tmp
self.pos = _save
break
@ -9385,7 +9384,7 @@ class RDoc::Markdown
self.pos = _save7
break
end
_tmp = scan(/\A(?-mix:[^`\n]*$)/)
_tmp = scan(/\G(?-mix:[^`\n]*$)/)
unless _tmp
self.pos = _save7
end
@ -9476,7 +9475,7 @@ class RDoc::Markdown
self.pos = _save15
break
end
_tmp = scan(/\A(?-mix:[^`\n]*$)/)
_tmp = scan(/\G(?-mix:[^`\n]*$)/)
unless _tmp
self.pos = _save15
end
@ -9725,7 +9724,7 @@ class RDoc::Markdown
_save3 = self.pos
while true # sequence
_tmp = scan(/\A(?-mix:_+)/)
_tmp = scan(/\G(?-mix:_+)/)
unless _tmp
self.pos = _save3
break
@ -9755,7 +9754,7 @@ class RDoc::Markdown
_save6 = self.pos
while true # sequence
_tmp = scan(/\A(?-mix:_+)/)
_tmp = scan(/\G(?-mix:_+)/)
unless _tmp
self.pos = _save6
break
@ -9818,7 +9817,7 @@ class RDoc::Markdown
break
end
_text_start = self.pos
_tmp = scan(/\A(?-mix:[:\\`|*_{}\[\]()#+.!><-])/)
_tmp = scan(/\G(?-mix:[:\\`|*_{}\[\]()#+.!><-])/)
if _tmp
text = get_text(_text_start)
end
@ -9944,7 +9943,7 @@ class RDoc::Markdown
self.pos = _save5
break
end
_tmp = scan(/\A(?-mix:={1,}|-{1,})/)
_tmp = scan(/\G(?-mix:={1,}|-{1,})/)
unless _tmp
self.pos = _save5
break
@ -10096,7 +10095,7 @@ class RDoc::Markdown
_save1 = self.pos
while true # sequence
_text_start = self.pos
_tmp = scan(/\A(?-mix:\*{4,})/)
_tmp = scan(/\G(?-mix:\*{4,})/)
if _tmp
text = get_text(_text_start)
end
@ -10126,7 +10125,7 @@ class RDoc::Markdown
self.pos = _save3
break
end
_tmp = scan(/\A(?-mix:\*+)/)
_tmp = scan(/\G(?-mix:\*+)/)
unless _tmp
self.pos = _save3
break
@ -10173,7 +10172,7 @@ class RDoc::Markdown
_save1 = self.pos
while true # sequence
_text_start = self.pos
_tmp = scan(/\A(?-mix:_{4,})/)
_tmp = scan(/\G(?-mix:_{4,})/)
if _tmp
text = get_text(_text_start)
end
@ -10203,7 +10202,7 @@ class RDoc::Markdown
self.pos = _save3
break
end
_tmp = scan(/\A(?-mix:_+)/)
_tmp = scan(/\G(?-mix:_+)/)
unless _tmp
self.pos = _save3
break
@ -11564,7 +11563,7 @@ class RDoc::Markdown
_save1 = self.pos
while true # sequence
_tmp = scan(/\A(?-mix:[A-Za-z]+)/)
_tmp = scan(/\G(?-mix:[A-Za-z]+)/)
unless _tmp
self.pos = _save1
break
@ -11689,7 +11688,7 @@ class RDoc::Markdown
_save2 = self.pos
while true # sequence
_tmp = scan(/\A(?i-mx:[\w+.\/!%~$-]+)/)
_tmp = scan(/\G(?i-mx:[\w+.\/!%~$-]+)/)
unless _tmp
self.pos = _save2
break
@ -12553,7 +12552,7 @@ class RDoc::Markdown
self.pos = _save10
break
end
_tmp = scan(/\A(?-mix:`+)/)
_tmp = scan(/\G(?-mix:`+)/)
unless _tmp
self.pos = _save10
end
@ -12690,7 +12689,7 @@ class RDoc::Markdown
self.pos = _save24
break
end
_tmp = scan(/\A(?-mix:`+)/)
_tmp = scan(/\G(?-mix:`+)/)
unless _tmp
self.pos = _save24
end
@ -12867,7 +12866,7 @@ class RDoc::Markdown
self.pos = _save40
break
end
_tmp = scan(/\A(?-mix:`+)/)
_tmp = scan(/\G(?-mix:`+)/)
unless _tmp
self.pos = _save40
end
@ -13004,7 +13003,7 @@ class RDoc::Markdown
self.pos = _save54
break
end
_tmp = scan(/\A(?-mix:`+)/)
_tmp = scan(/\G(?-mix:`+)/)
unless _tmp
self.pos = _save54
end
@ -13181,7 +13180,7 @@ class RDoc::Markdown
self.pos = _save70
break
end
_tmp = scan(/\A(?-mix:`+)/)
_tmp = scan(/\G(?-mix:`+)/)
unless _tmp
self.pos = _save70
end
@ -13318,7 +13317,7 @@ class RDoc::Markdown
self.pos = _save84
break
end
_tmp = scan(/\A(?-mix:`+)/)
_tmp = scan(/\G(?-mix:`+)/)
unless _tmp
self.pos = _save84
end
@ -13495,7 +13494,7 @@ class RDoc::Markdown
self.pos = _save100
break
end
_tmp = scan(/\A(?-mix:`+)/)
_tmp = scan(/\G(?-mix:`+)/)
unless _tmp
self.pos = _save100
end
@ -13632,7 +13631,7 @@ class RDoc::Markdown
self.pos = _save114
break
end
_tmp = scan(/\A(?-mix:`+)/)
_tmp = scan(/\G(?-mix:`+)/)
unless _tmp
self.pos = _save114
end
@ -13809,7 +13808,7 @@ class RDoc::Markdown
self.pos = _save130
break
end
_tmp = scan(/\A(?-mix:`+)/)
_tmp = scan(/\G(?-mix:`+)/)
unless _tmp
self.pos = _save130
end
@ -13946,7 +13945,7 @@ class RDoc::Markdown
self.pos = _save144
break
end
_tmp = scan(/\A(?-mix:`+)/)
_tmp = scan(/\G(?-mix:`+)/)
unless _tmp
self.pos = _save144
end
@ -14598,7 +14597,7 @@ class RDoc::Markdown
_save = self.pos
while true # choice
_tmp = scan(/\A(?-mix:[~*_`&\[\]()<!#\\'"])/)
_tmp = scan(/\G(?-mix:[~*_`&\[\]()<!#\\'"])/)
break if _tmp
self.pos = _save
_tmp = _ExtendedSpecialChar()
@ -14703,13 +14702,13 @@ class RDoc::Markdown
_save = self.pos
while true # sequence
_tmp = scan(/\A(?i-mx:&#x)/)
_tmp = scan(/\G(?i-mx:&#x)/)
unless _tmp
self.pos = _save
break
end
_text_start = self.pos
_tmp = scan(/\A(?-mix:[0-9a-fA-F]+)/)
_tmp = scan(/\G(?-mix:[0-9a-fA-F]+)/)
if _tmp
text = get_text(_text_start)
end
@ -14745,7 +14744,7 @@ class RDoc::Markdown
break
end
_text_start = self.pos
_tmp = scan(/\A(?-mix:[0-9]+)/)
_tmp = scan(/\G(?-mix:[0-9]+)/)
if _tmp
text = get_text(_text_start)
end
@ -14781,7 +14780,7 @@ class RDoc::Markdown
break
end
_text_start = self.pos
_tmp = scan(/\A(?-mix:[A-Za-z0-9]+)/)
_tmp = scan(/\G(?-mix:[A-Za-z0-9]+)/)
if _tmp
text = get_text(_text_start)
end
@ -14813,14 +14812,14 @@ class RDoc::Markdown
# NonindentSpace = / {0,3}/
def _NonindentSpace
_tmp = scan(/\A(?-mix: {0,3})/)
_tmp = scan(/\G(?-mix: {0,3})/)
set_failed_rule :_NonindentSpace unless _tmp
return _tmp
end
# Indent = /\t| /
def _Indent
_tmp = scan(/\A(?-mix:\t| )/)
_tmp = scan(/\G(?-mix:\t| )/)
set_failed_rule :_Indent unless _tmp
return _tmp
end
@ -15762,7 +15761,7 @@ class RDoc::Markdown
self.pos = _save11
break
end
_tmp = scan(/\A(?-mix:`+)/)
_tmp = scan(/\G(?-mix:`+)/)
unless _tmp
self.pos = _save11
end
@ -15843,7 +15842,7 @@ class RDoc::Markdown
self.pos = _save19
break
end
_tmp = scan(/\A(?-mix:`+)/)
_tmp = scan(/\G(?-mix:`+)/)
unless _tmp
self.pos = _save19
end

Просмотреть файл

@ -174,9 +174,8 @@ class RDoc::Markdown::Literals
end
def scan(reg)
if m = reg.match(@string[@pos..-1])
width = m.end(0)
@pos += width
if m = reg.match(@string, @pos)
@pos = m.end(0)
return true
end
@ -366,14 +365,14 @@ class RDoc::Markdown::Literals
# Alphanumeric = /\p{Word}/
def _Alphanumeric
_tmp = scan(/\A(?-mix:\p{Word})/)
_tmp = scan(/\G(?-mix:\p{Word})/)
set_failed_rule :_Alphanumeric unless _tmp
return _tmp
end
# AlphanumericAscii = /[A-Za-z0-9]/
def _AlphanumericAscii
_tmp = scan(/\A(?-mix:[A-Za-z0-9])/)
_tmp = scan(/\G(?-mix:[A-Za-z0-9])/)
set_failed_rule :_AlphanumericAscii unless _tmp
return _tmp
end
@ -387,21 +386,21 @@ class RDoc::Markdown::Literals
# Newline = /\n|\r\n?|\p{Zl}|\p{Zp}/
def _Newline
_tmp = scan(/\A(?-mix:\n|\r\n?|\p{Zl}|\p{Zp})/)
_tmp = scan(/\G(?-mix:\n|\r\n?|\p{Zl}|\p{Zp})/)
set_failed_rule :_Newline unless _tmp
return _tmp
end
# NonAlphanumeric = /\p{^Word}/
def _NonAlphanumeric
_tmp = scan(/\A(?-mix:\p{^Word})/)
_tmp = scan(/\G(?-mix:\p{^Word})/)
set_failed_rule :_NonAlphanumeric unless _tmp
return _tmp
end
# Spacechar = /\t|\p{Zs}/
def _Spacechar
_tmp = scan(/\A(?-mix:\t|\p{Zs})/)
_tmp = scan(/\G(?-mix:\t|\p{Zs})/)
set_failed_rule :_Spacechar unless _tmp
return _tmp
end