diff options
author | Fumiaki MATSUSHIMA <mtsmfm@gmail.com> | 2017-01-26 18:15:37 +0900 |
---|---|---|
committer | Fumiaki MATSUSHIMA <mtsmfm@gmail.com> | 2017-01-28 16:57:36 +0900 |
commit | bdcfdef21444b03413213c69035f0fac8feedffb (patch) | |
tree | c3ac443862c6e0c7858b0be3eed5802296613b79 /activesupport/bin | |
parent | 05112b21310c3ea04026176a5f7ca11040454ac1 (diff) | |
download | rails-bdcfdef21444b03413213c69035f0fac8feedffb.tar.gz rails-bdcfdef21444b03413213c69035f0fac8feedffb.tar.bz2 rails-bdcfdef21444b03413213c69035f0fac8feedffb.zip |
Update Unicode Version to 9.0.0
9.0.0 was released on June 21, 2016
http://blog.unicode.org/2016/06/announcing-unicode-standard-version-90.html
http://www.unicode.org/versions/Unicode9.0.0/
There are some changes about grapheme cluster in Unicode 9.0.0:
http://unicode.org/reports/tr29/#Grapheme_Cluster_Boundary_Rules
------------
I noticed that `unpack_graphemes` returns [Other] when the argument is Other รท Prepend
(it must be [Other, Prepend]).
But in [Unicode 8.0.0's Prepend has no characters](http://www.unicode.org/reports/tr29/tr29-27.html#Prepend)
so we don't have to backport following patch:
```diff
should_break =
+ if pos == eoc
+ true
```
Diffstat (limited to 'activesupport/bin')
-rwxr-xr-x | activesupport/bin/generate_tables | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/activesupport/bin/generate_tables b/activesupport/bin/generate_tables index 5d912f375c..aa36a01b5b 100755 --- a/activesupport/bin/generate_tables +++ b/activesupport/bin/generate_tables @@ -8,6 +8,7 @@ end require "open-uri" require "tmpdir" +require "fileutils" module ActiveSupport module Multibyte @@ -101,9 +102,10 @@ module ActiveSupport def parse SOURCES.each do |type, url| - filename = File.join(Dir.tmpdir, "#{url.split('/').last}") + filename = File.join(Dir.tmpdir, UNICODE_VERSION, "#{url.split('/').last}") unless File.exist?(filename) $stderr.puts "Downloading #{url.split('/').last}" + FileUtils.mkdir_p(File.dirname(filename)) File.open(filename, "wb") do |target| open(url) do |source| source.each_line { |line| target.write line } |