@@ -179,7 +179,7 @@ def initialize(top_level, file_name, content, options, stats)
179
179
@size = 0
180
180
@token_listeners = nil
181
181
content = RDoc ::Encoding . remove_magic_comment content
182
- @scanner = RDoc ::RipperStateLex . parse ( content )
182
+ @scanner = RDoc ::Parser :: RipperStateLex . parse ( content )
183
183
@content = content
184
184
@scanner_point = 0
185
185
@prev_seek = nil
@@ -741,9 +741,9 @@ def parse_call_parameters(tk)
741
741
when end_token
742
742
if end_token == :on_rparen
743
743
nest -= 1
744
- break if RDoc ::RipperStateLex . end? ( tk ) and nest <= 0
744
+ break if RDoc ::Parser :: RipperStateLex . end? ( tk ) and nest <= 0
745
745
else
746
- break if RDoc ::RipperStateLex . end? ( tk )
746
+ break if RDoc ::Parser :: RipperStateLex . end? ( tk )
747
747
end
748
748
when :on_comment , :on_embdoc
749
749
unget_tk ( tk )
@@ -961,15 +961,15 @@ def parse_constant_body container, constant, is_array_or_hash # :nodoc:
961
961
elsif ( :on_kw == tk [ :kind ] && 'def' == tk [ :text ] ) then
962
962
nest += 1
963
963
elsif ( :on_kw == tk [ :kind ] && %w{ do if unless case begin } . include? ( tk [ :text ] ) ) then
964
- if ( tk [ :state ] & RDoc ::RipperStateLex ::EXPR_LABEL ) == 0
964
+ if ( tk [ :state ] & RDoc ::Parser :: RipperStateLex ::EXPR_LABEL ) == 0
965
965
nest += 1
966
966
end
967
967
elsif [ :on_rparen , :on_rbrace , :on_rbracket ] . include? ( tk [ :kind ] ) ||
968
968
( :on_kw == tk [ :kind ] && 'end' == tk [ :text ] ) then
969
969
nest -= 1
970
970
elsif ( :on_comment == tk [ :kind ] or :on_embdoc == tk [ :kind ] ) then
971
971
unget_tk tk
972
- if nest <= 0 and RDoc ::RipperStateLex . end? ( tk ) then
972
+ if nest <= 0 and RDoc ::Parser :: RipperStateLex . end? ( tk ) then
973
973
body = get_tkread_clean ( /^[ \t ]+/ , '' )
974
974
read_documentation_modifiers constant , RDoc ::CONSTANT_MODIFIERS
975
975
break
@@ -985,7 +985,7 @@ def parse_constant_body container, constant, is_array_or_hash # :nodoc:
985
985
break
986
986
end
987
987
elsif :on_nl == tk [ :kind ] then
988
- if nest <= 0 and RDoc ::RipperStateLex . end? ( tk ) then
988
+ if nest <= 0 and RDoc ::Parser :: RipperStateLex . end? ( tk ) then
989
989
unget_tk tk
990
990
break
991
991
end
@@ -1555,7 +1555,7 @@ def parse_method_or_yield_parameters(method = nil,
1555
1555
when :on_comment , :on_embdoc then
1556
1556
@read . pop
1557
1557
if :on_nl == end_token [ :kind ] and "\n " == tk [ :text ] [ -1 ] and
1558
- ( !continue or ( tk [ :state ] & RDoc ::RipperStateLex ::EXPR_LABEL ) != 0 ) then
1558
+ ( !continue or ( tk [ :state ] & RDoc ::Parser :: RipperStateLex ::EXPR_LABEL ) != 0 ) then
1559
1559
if method && method . block_params . nil? then
1560
1560
unget_tk tk
1561
1561
read_documentation_modifiers method , modifiers
@@ -1772,7 +1772,7 @@ def parse_statements(container, single = NORMAL, current_method = nil,
1772
1772
end
1773
1773
1774
1774
when 'until' , 'while' then
1775
- if ( tk [ :state ] & RDoc ::RipperStateLex ::EXPR_LABEL ) == 0
1775
+ if ( tk [ :state ] & RDoc ::Parser :: RipperStateLex ::EXPR_LABEL ) == 0
1776
1776
nest += 1
1777
1777
skip_optional_do_after_expression
1778
1778
end
@@ -1788,7 +1788,7 @@ def parse_statements(container, single = NORMAL, current_method = nil,
1788
1788
skip_optional_do_after_expression
1789
1789
1790
1790
when 'case' , 'do' , 'if' , 'unless' , 'begin' then
1791
- if ( tk [ :state ] & RDoc ::RipperStateLex ::EXPR_LABEL ) == 0
1791
+ if ( tk [ :state ] & RDoc ::Parser :: RipperStateLex ::EXPR_LABEL ) == 0
1792
1792
nest += 1
1793
1793
end
1794
1794
0 commit comments