summaryrefslogtreecommitdiff
path: root/lib/irb/ruby-lex.rb
diff options
context:
space:
mode:
authoraycabta <[email protected]>2019-12-03 13:02:01 +0900
committeraycabta <[email protected]>2019-12-03 13:02:50 +0900
commit027e847cd2540553c9ddcf1b39028c43258a3fb4 (patch)
treee36b320e8f28ff155ade4735e01ce6ada2b8d611 /lib/irb/ruby-lex.rb
parent14a17063a11a01d518b4bbaf0eb967330aec3984 (diff)
Fix auto-indent behavior correctly
Diffstat (limited to 'lib/irb/ruby-lex.rb')
-rw-r--r--lib/irb/ruby-lex.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/irb/ruby-lex.rb b/lib/irb/ruby-lex.rb
index 1761afe895..24074f323d 100644
--- a/lib/irb/ruby-lex.rb
+++ b/lib/irb/ruby-lex.rb
@@ -366,9 +366,9 @@ class RubyLex
spaces_of_nest = []
spaces_at_line_head = 0
@tokens.each_with_index do |t, index|
- corresponding_token_depth = nil
case t[1]
when :on_ignored_nl, :on_nl, :on_comment
+ corresponding_token_depth = nil
spaces_at_line_head = 0
is_first_spaces_of_line = true
is_first_printable_of_line = true