From 8b180dd74ef7604bc896275ce2a13a1d8c2c2565 Mon Sep 17 00:00:00 2001 From: nobu Date: Sat, 2 Dec 2017 03:12:50 +0000 Subject: [PATCH] enc-unicode.rb: for gperf 3.1 * tool/enc-unicode.rb: support for gperf 3.1, which defines length arguments as `size_t` but a local variable as `unsigned int`. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60976 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- tool/enc-unicode.rb | 1 + 1 file changed, 1 insertion(+) diff --git a/tool/enc-unicode.rb b/tool/enc-unicode.rb index d82f1dbdd1..222573b3a8 100755 --- a/tool/enc-unicode.rb +++ b/tool/enc-unicode.rb @@ -539,6 +539,7 @@ if header f.each {|line| line.gsub!(/\(int\)\((?:long|size_t)\)&\(\(struct uniname2ctype_pool_t \*\)0\)->uniname2ctype_pool_(str\d+),\s+/, 'uniname2ctype_offset(\1), ') + line.sub!(/^(uniname2ctype_(hash|p) *\(.* )size_t /, '\1unsigned int ') puts line } }