Skip to content

Commit

Permalink
[ruby/reline] Suppress warning(Ruby 3.4) requiring fiddle from
Browse files Browse the repository at this point in the history
  • Loading branch information
tompng authored and matzbot committed Jun 10, 2024
1 parent 21e06e5 commit e8bd745
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions lib/reline/terminfo.rb
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
begin
# Ignore warning `Add fiddle to your Gemfile or gemspec` in Ruby 3.4.
# terminfo.rb and ansi.rb supports fiddle unavailable environment.
verbose, $VERBOSE = $VERBOSE, nil
require 'fiddle'
require 'fiddle/import'
rescue LoadError
Expand All @@ -7,6 +10,8 @@ def self.curses_dl
false
end
end
ensure
$VERBOSE = verbose
end

module Reline::Terminfo
Expand Down

0 comments on commit e8bd745

Please sign in to comment.