summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorYukihiro "Matz" Matsumoto <[email protected]>2020-06-05 10:10:36 +0900
committerYukihiro "Matz" Matsumoto <[email protected]>2020-10-12 16:21:04 +0900
commit26da07db15c3628c6bb473ce4ae4bc98fa3f431b (patch)
tree6050023c42600c11f9be1abec75447a7bc85f4c0
parent7ab7cadbbb012d9431928d9cfae09451eab86613 (diff)
downloadmruby-26da07db15c3628c6bb473ce4ae4bc98fa3f431b.tar.gz
mruby-26da07db15c3628c6bb473ce4ae4bc98fa3f431b.zip
Avoid using `chomp:true` option to `File.readlines`.
The option is not available in the old version of Ruby.
-rw-r--r--Rakefile3
1 files changed, 2 insertions, 1 deletions
diff --git a/Rakefile b/Rakefile
index 1452d7903..e07ca16a8 100644
--- a/Rakefile
+++ b/Rakefile
@@ -164,7 +164,8 @@ file presym_file => cfiles+rbfiles+[__FILE__] do
src.scan(/\bdef +(\w+)/)]
end
symbols = (csymbols+rbsymbols+op_table.keys).flatten.compact.uniq.sort
- presyms = File.readlines(presym_file, chomp: true) rescue []
+ presyms = File.readlines(presym_file) rescue []
+ presyms.each{|x| x.chomp!}
if presyms != symbols
File.write(presym_file, symbols.join("\n"))
end