mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
Fix encoding compatibility checking of completion correctly
This commit is contained in:
parent
3cdb37d9db
commit
a14c01441b
1 changed files with 1 additions and 1 deletions
|
@ -549,7 +549,7 @@ class Reline::LineEditor
|
|||
private def complete_internal_proc(list, is_menu)
|
||||
preposing, target, postposing = retrieve_completion_block
|
||||
list = list.select { |i|
|
||||
if i and i.encoding != Encoding::US_ASCII and i.encoding != @encoding
|
||||
if i and not Encoding.compatible?(target.encoding, i.encoding)
|
||||
raise Encoding::CompatibilityError
|
||||
end
|
||||
i&.start_with?(target)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue