diff options
author | hut <hut@lavabit.com> | 2009-07-21 00:27:58 +0200 |
---|---|---|
committer | hut <hut@lavabit.com> | 2009-07-21 00:27:58 +0200 |
commit | 9ef9f9b0c2c4e5ebefe3b280022e496de1ac0cab (patch) | |
tree | dd565e546013e2d1a0080ae6b07137c3be0dcda1 | |
parent | da691a311d22505faf8da17ca8354551792d6384 (diff) | |
download | ranger-9ef9f9b0c2c4e5ebefe3b280022e496de1ac0cab.tar.gz |
each_char -> each_byte
-rw-r--r-- | code/draw.rb | 2 | ||||
-rw-r--r-- | code/extensions/basic.rb | 2 | ||||
-rw-r--r-- | code/keys.rb | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/code/draw.rb b/code/draw.rb index 39f815fa..6b3acc8b 100644 --- a/code/draw.rb +++ b/code/draw.rb @@ -24,7 +24,7 @@ module Fm f.lines.each do |l| if check check = false - break unless l.each_char.all? {|x| x[0] > 0 and x[0] < 128} + break unless l.each_byte.all? {|x| x.ord > 0 and x.ord < 128} end puti i+1, left, l.gsub("\t"," ")[0, wid-1].ljust(wid) i += 1 diff --git a/code/extensions/basic.rb b/code/extensions/basic.rb index 0dbd8a96..89798ba5 100644 --- a/code/extensions/basic.rb +++ b/code/extensions/basic.rb @@ -152,7 +152,7 @@ class File::Stat end s = ("%o" % mode)[-3..-1] - for m in s.each_char + for m in s.each_byte result << MODES_HASH[m] end diff --git a/code/keys.rb b/code/keys.rb index a6a68455..963b87bb 100644 --- a/code/keys.rb +++ b/code/keys.rb @@ -759,7 +759,7 @@ module Fm if token =~ /^\/(.*)\/$/ ary << $1 elsif token.size > 0 - ary << token.each_char.map {|t| + ary << token.each_byte.map {|t| if t == '?' t = '\?' end |