1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

Support multibyte input

This commit is contained in:
Nobuyoshi Nakada 2019-12-22 11:46:09 +09:00 committed by aycabta
parent cf59e1476d
commit efd4a11ada

View file

@ -30,7 +30,8 @@ class Reline::ANSI
unless @@buf.empty?
return @@buf.shift
end
@@input.getbyte
c = @@input.getbyte
(c == 0x16 && @@input.raw(min: 0, tim: 0, &:getbyte)) || c
end
def self.ungetc(c)