Skip to content

Commit

Permalink
[ruby/irb] Use Reline::Key for trap_key in dialog callback
Browse files Browse the repository at this point in the history
  • Loading branch information
aycabta authored and matzbot committed Sep 2, 2021
1 parent 5458f23 commit 3d6a475
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/irb/input-method.rb
Expand Up @@ -315,7 +315,7 @@ def auto_indent(&block)

SHOW_DOC_DIALOG = ->() {
dialog.trap_key = nil
alt_d = 0xE4
alt_d = Reline::Key.new(nil, 0xE4, true)
begin
require 'rdoc'
rescue LoadError
Expand All @@ -332,7 +332,7 @@ def auto_indent(&block)

driver = RDoc::RI::Driver.new

if key.combined_char == alt_d
if key.match?(alt_d)
begin
driver.display_names([name])
rescue RDoc::RI::Driver::NotFoundError
Expand Down

0 comments on commit 3d6a475

Please sign in to comment.