Coder Social home page Coder Social logo

ruby-japanize's People

Contributors

y10k avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

ruby-japanize's Issues

物の土台(BasicObject)でシステムのスタックが超過(SystemStackError)する

問題を再現するコード:

(日本語化) {
  (:試験) {
    (:物の土台の操作の試験, 原型: 試験単位::試験事例) {
      資料('物'       => ,
           '物の土台' => 物の土台)
      試験('不明な操作の呼び出しが発生することを確認') {|資料|
        物の組 = 資料
        ある物 = 物の組.新規
        # 例外が発生することを確認(操作が無いため失敗) {
          ある物.出鱈目
        # }
      }
    }
  }
}

発生した事象:

  • 本来は操作が無いため失敗(NoMethodError)するべき
  • 実際はシステムのスタックが超過したため失敗(SystemStackError)してしまう
-*- mode: compilation; default-directory: "~/git_work/ruby-japanize/test/" -*-
Compilation started at Wed Oct 23 15:17:37

bundle exec ruby /home/toki/git_work/ruby-japanize/test/test_base.rb --no-use-color -v --location\=416
Loaded suite /home/toki/git_work/ruby-japanize/test/test_base
Started
Test::Unit::JA試験事例: 
  JA::JA試験::JA物の土台の操作の試験: 
    test: 不明な操作の呼び出しが発生することを確認[物]:															E
==========================================================================================================================================================================
/home/toki/git_work/ruby-japanize/test/test_base.rb:414:in `block (4 levels) in <main>'
Error: test: 不明な操作の呼び出しが発生することを確認[物](JA::JA試験::JA物の土台の操作の試験): NoMethodError: undefined method `出鱈目' for #<Object:0x00007fffe765d530>
==========================================================================================================================================================================
: (0.006622)
    test: 不明な操作の呼び出しが発生することを確認[物の土台]:															E
==========================================================================================================================================================================
/home/toki/git_work/ruby-japanize/test/test_base.rb:414:in `block (4 levels) in <main>'
/home/toki/git_work/ruby-japanize/lib/japanize/base.rb:186:in `block (2 levels) in <top (required)>'
/home/toki/git_work/ruby-japanize/lib/japanize/base.rb:496:in `block (3 levels) in <top (required)>'
/home/toki/git_work/ruby-japanize/lib/japanize/base.rb:498:in `rescue in block (3 levels) in <top (required)>'
/home/toki/git_work/ruby-japanize/lib/japanize/base.rb:186:in `block (2 levels) in <top (required)>'
/home/toki/git_work/ruby-japanize/lib/japanize/base.rb:496:in `block (3 levels) in <top (required)>'
/home/toki/git_work/ruby-japanize/lib/japanize/base.rb:498:in `rescue in block (3 levels) in <top (required)>'
/home/toki/git_work/ruby-japanize/lib/japanize/base.rb:186:in `block (2 levels) in <top (required)>'
/home/toki/git_work/ruby-japanize/lib/japanize/base.rb:496:in `block (3 levels) in <top (required)>'
/home/toki/git_work/ruby-japanize/lib/japanize/base.rb:498:in `rescue in block (3 levels) in <top (required)>'
/home/toki/git_work/ruby-japanize/lib/japanize/base.rb:186:in `block (2 levels) in <top (required)>'
/home/toki/git_work/ruby-japanize/lib/japanize/base.rb:496:in `block (3 levels) in <top (required)>'
...
/home/toki/git_work/ruby-japanize/lib/japanize/base.rb:186:in `block (2 levels) in <top (required)>'
Error: test: 不明な操作の呼び出しが発生することを確認[物の土台](JA::JA試験::JA物の土台の操作の試験): SystemStackError: stack level too deep
==========================================================================================================================================================================
: (17.567496)

Finished in 17.5752272 seconds.
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------
2 tests, 0 assertions, 0 failures, 2 errors, 0 pendings, 0 omissions, 0 notifications
0% passed
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------
0.11 tests/s, 0.00 assertions/s

Compilation exited abnormally with code 1 at Wed Oct 23 15:17:57

Ruby 2.6の引数の移譲で連想配列(Hash)が名前付き引数と混同される問題

問題の再現コード:

      試験('引数の移譲で名前付き引数と混同せずに連想配列を渡せることを確認') {
        空の連想配列 = {}
        ある物 = .新規() {|ある組|
          (ある組) {
            定義(:初期化) {||
              @甲 = 
            }
            読み取り属性 :甲
          }
        }.新規(空の連想配列)

        等しいことを確認(空の連想配列, ある物.)
      }

問題の再現結果:

$ git --no-pager log --oneline v0.1.0..origin/master
a5b8d21 (rb270_preview2/master, origin/master) 日本語化のための最小限の仕組み: 部/組の定義の簡略な表現のリファクタリング
897e4f4 (gut/rb270_preview2, rb270_preview2) スレッドの操作: 名前付き引数を明示的に移譲する (#3)
90ee636 時刻の操作: 名前付き引数を明示的に移譲する (#3)
8fd9d1f 基本的な部/組の操作: 名前付き引数を明示的に移譲する (#3)
1b00186 日本語化のための最小限の仕組み: 名前付き引数を明示的に移譲する (#3)
91b138a 日本語化のための最小限の仕組み: Rubyのバージョンを確認する (#3)
2998ad5 日本語化のための最小限の仕組み: 組の定義の警告が出ないようにする (#3)
4fc61b9 数値の操作を日本語化: Ruby 2.7からFloat::ROUNDSが非推奨になった対応 (#3)
2f00c74 spec: 開発用にwarning gemを追加する (#3)
1fd4046 日本語化のための最小限の仕組み: 日本語の定数のリファクタリング
f798184 基本的な部/組の操作: 物の土台でシステムのスタックが超過する問題を修正する (#2)
7873e3e 基本的な部/組の操作: 試験のリファクタリング
a4cca2a 基本的な部/組の操作: initializeの日本語の別名を物の土台に移す (#1)
2e24e79 基本的な部/組の操作: 物の操作の日本語の別名を核に移す (#1)
9367432 start to version 0.2.0
$ git bisect start origin/master v0.1.0
Bisecting: 7 revisions left to test after this (roughly 3 steps)
[2f00c74edede5fb7aaf4845a6f3921cdcbf0ee2c] spec: 開発用にwarning gemを追加する (#3)
$ git bisect run bundle exec ruby tmp/test_base.rb -v --name='/引数の移譲で名前付き引数と混同せずに連想配列を渡せることを確認/'
running bundle exec ruby tmp/test_base.rb -v --name=/引数の移譲で名前付き引数と混同せずに連想配列を渡せることを確認/
Loaded suite tmp/test_base
Started
Test::Unit::JA試験事例:
  JA::JA試験::JA物の操作の試験:
    test: 引数の移譲で名前付き引数と混同せずに連想配列を渡せることを確認:                                                                            .: (0.000615)

Finished in 0.0016079 seconds.
------------------------------------------------------------------------------------------------------------------------------------------------------
1 tests, 1 assertions, 0 failures, 0 errors, 0 pendings, 0 omissions, 0 notifications
100% passed
------------------------------------------------------------------------------------------------------------------------------------------------------
621.93 tests/s, 621.93 assertions/s
Bisecting: 3 revisions left to test after this (roughly 2 steps)
[1b001863016024a1992c97da46dddc7e6c5fbaca] 日本語化のための最小限の仕組み: 名前付き引数を明示的に移譲する (#3)
running bundle exec ruby tmp/test_base.rb -v --name=/引数の移譲で名前付き引数と混同せずに連想配列を渡せることを確認/
Loaded suite tmp/test_base
Started
Test::Unit::JA試験事例:
  JA::JA試験::JA物の操作の試験:
    test: 引数の移譲で名前付き引数と混同せずに連想配列を渡せることを確認:                                                                            .: (0.000730)

Finished in 0.0021764 seconds.
------------------------------------------------------------------------------------------------------------------------------------------------------
1 tests, 1 assertions, 0 failures, 0 errors, 0 pendings, 0 omissions, 0 notifications
100% passed
------------------------------------------------------------------------------------------------------------------------------------------------------
459.47 tests/s, 459.47 assertions/s
Bisecting: 1 revision left to test after this (roughly 1 step)
[90ee636a70aa9c5fb1c7e91874fc02c60366da5c] 時刻の操作: 名前付き引数を明示的に移譲する (#3)
running bundle exec ruby tmp/test_base.rb -v --name=/引数の移譲で名前付き引数と混同せずに連想配列を渡せることを確認/
Loaded suite tmp/test_base
Started
Test::Unit::JA試験事例:
  JA::JA試験::JA物の操作の試験:
    test: 引数の移譲で名前付き引数と混同せずに連想配列を渡せることを確認:                                                                            E
======================================================================================================================================================
tmp/test_base.rb:546:in `block (4 levels) in <main>'
/home/toki/git_work/ruby-japanize/lib/japanize/base.rb:168:in `block (2 levels) in <top (required)>'
/home/toki/git_work/ruby-japanize/lib/japanize/core.rb:203:in `block in <module:Japanize>'
/home/toki/git_work/ruby-japanize/lib/japanize/core.rb:203:in `new'
/home/toki/git_work/ruby-japanize/lib/japanize/base.rb:271:in `block (3 levels) in <top (required)>'
/home/toki/git_work/ruby-japanize/lib/japanize/core.rb:203:in `block in <module:Japanize>'
tmp/test_base.rb:541:in `block (7 levels) in <main>'
Error: test: 引数の移譲で名前付き引数と混同せずに連想配列を渡せることを確認(JA::JA試験::JA物の操作の試験): ArgumentError: wrong number of arguments (given 0, expected 1)
======================================================================================================================================================
: (0.002027)

Finished in 0.0030577 seconds.
------------------------------------------------------------------------------------------------------------------------------------------------------
1 tests, 0 assertions, 0 failures, 1 errors, 0 pendings, 0 omissions, 0 notifications
0% passed
------------------------------------------------------------------------------------------------------------------------------------------------------
327.04 tests/s, 0.00 assertions/s
Bisecting: 0 revisions left to test after this (roughly 0 steps)
[8fd9d1f7dcfd616cd94b21743e8ba6582ca011d0] 基本的な部/組の操作: 名前付き引数を明示的に移譲する (#3)
running bundle exec ruby tmp/test_base.rb -v --name=/引数の移譲で名前付き引数と混同せずに連想配列を渡せることを確認/
Loaded suite tmp/test_base
Started
Test::Unit::JA試験事例:
  JA::JA試験::JA物の操作の試験:
    test: 引数の移譲で名前付き引数と混同せずに連想配列を渡せることを確認:                                                                            E
======================================================================================================================================================
tmp/test_base.rb:546:in `block (4 levels) in <main>'
/home/toki/git_work/ruby-japanize/lib/japanize/base.rb:168:in `block (2 levels) in <top (required)>'
/home/toki/git_work/ruby-japanize/lib/japanize/core.rb:203:in `block in <module:Japanize>'
/home/toki/git_work/ruby-japanize/lib/japanize/core.rb:203:in `new'
/home/toki/git_work/ruby-japanize/lib/japanize/base.rb:271:in `block (3 levels) in <top (required)>'
/home/toki/git_work/ruby-japanize/lib/japanize/core.rb:203:in `block in <module:Japanize>'
tmp/test_base.rb:541:in `block (7 levels) in <main>'
Error: test: 引数の移譲で名前付き引数と混同せずに連想配列を渡せることを確認(JA::JA試験::JA物の操作の試験): ArgumentError: wrong number of arguments (given 0, expected 1)
======================================================================================================================================================
: (0.002748)

Finished in 0.0043208 seconds.
------------------------------------------------------------------------------------------------------------------------------------------------------
1 tests, 0 assertions, 0 failures, 1 errors, 0 pendings, 0 omissions, 0 notifications
0% passed
------------------------------------------------------------------------------------------------------------------------------------------------------
231.44 tests/s, 0.00 assertions/s
8fd9d1f7dcfd616cd94b21743e8ba6582ca011d0 is the first bad commit
commit 8fd9d1f7dcfd616cd94b21743e8ba6582ca011d0
Author: TOKI Yoshinori <[email protected]>
Date:   Fri Oct 25 08:51:32 2019 +0000

    基本的な部/組の操作: 名前付き引数を明示的に移譲する (#3)

    Github Issue: #3

    Ruby 2.7で名前付き引数を明示的に移譲するようにした。

:040000 040000 f952effe3541da2976ceb2ddb8c28ac49bb5376c d579cfe03dc6355ec11a3c976e7f95c4c837cd7a M      lib
:040000 040000 55350251ef7c080f1d8ca983994268158bdbc2b1 22cf6f456f61d990cfea65cad9b1c3ddd76c8368 M      test
bisect run success

物(オブジェクト)の操作(メソッド)の日本語の別名を核(Kernel)に移す

物(オブジェクト)の操作(メソッド)は実際は核(Kernel)で定義されているので、日本語の別名も核(Kernel)で定義する。

irb(main):014:0> Object.public_instance_methods(false)
=> []
irb(main):015:0> pp Kernel.public_instance_methods(false) - Kernel.public_methods(false)
[:instance_variable_defined?,
 :remove_instance_variable,
 :instance_of?,
 :kind_of?,
 :is_a?,
 :tap,
 :instance_variable_get,
 :instance_variable_set,
 :instance_variables,
 :protected_methods,
 :private_methods,
 :pretty_inspect,
 :public_send,
 :method,
 :public_method,
 :singleton_method,
 :define_singleton_method,
 :extend,
 :to_enum,
 :enum_for,
 :=~,
 :!~,
 :eql?,
 :respond_to?,
 :object_id,
 :send,
 :display,
 :class,
 :nil?,
 :hash,
 :dup,
 :singleton_class,
 :clone,
 :then,
 :itself,
 :yield_self,
 :untaint,
 :taint,
 :tainted?,
 :trust,
 :untrust,
 :untrusted?,
 :singleton_methods,
 :frozen?,
 :methods,
 :public_methods]
=> [:instance_variable_defined?, :remove_instance_variable, :instance_of?, :kind_of?, :is_a?, :tap, :instance_variable_get, :instance_variable_set, :instance_variables, :protected_methods, :private_methods, :pretty_inspect, :public_send, :method, :public_method, :singleton_method, :define_singleton_method, :extend, :to_enum, :enum_for, :=~, :!~, :eql?, :respond_to?, :object_id, :send, :display, :class, :nil?, :hash, :dup, :singleton_class, :clone, :then, :itself, :yield_self, :untaint, :taint, :tainted?, :trust, :untrust, :untrusted?, :singleton_methods, :frozen?, :methods, :public_methods]
irb(main):016:0> 

Ruby 2.7.0-preview2の警告を解消する

admin@ad5e08f392fe:~/ruby-japanize$ ruby --version
ruby 2.7.0preview2 (2019-10-22 master 02aadf1032) [x86_64-linux]
admin@ad5e08f392fe:~/ruby-japanize$ rake test
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/num.rb:165: warning: constant Float::ROUNDS is deprecated
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/test/test_num.rb:185: warning: constant Float::ROUNDS is deprecated
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
Loaded suite /usr/local/lib/ruby/gems/2.7.0/gems/rake-13.0.0/lib/rake/rake_test_loader
Started
......................................................................................................................................................
......................................................................................................................................................
......................................................................................................................................................
......................................................................................................................................................
......................................................................................................................................................
......................................................................................................................................................
......................................................................................................................................................
......................................................................................................................................................
............................................................................/home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
../home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
../home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
../home/admin/ruby-japanize/lib/japanize/core.rb:124: warning: The last argument is used as the keyword parameter
/home/admin/ruby-japanize/lib/japanize/core.rb:158: warning: for method defined here
....................................................................
......................................................................................................................................................
......................................................................................................................................................
......................................................................................................................................................
..........................................................................................................
Finished in 0.562821874 seconds.
------------------------------------------------------------------------------------------------------------------------------------------------------
1906 tests, 5451 assertions, 0 failures, 0 errors, 0 pendings, 0 omissions, 0 notifications
100% passed
------------------------------------------------------------------------------------------------------------------------------------------------------
3386.51 tests/s, 9685.12 assertions/s

source_locationの日本語訳を見直す

source_locationの日本語訳を直訳の元の場所としているが、意味が不明瞭なので見直す。
より具体的に定義された場所にした方が分かりやすいと思われる。

日本語の操作を定義するバッククォート(`)記法を追加する

  • バッククォート記法(Kernel#`)を再定義して日本語の操作を定義する命令を追加する。
  • 引数を転送する記法を定義して、引数の転送を簡略化し、Ruby 2.7とRuby 2.6の差異を吸収する。

例:

# 操作の定義
`定義 甲
   何か
`

# 引数の転送
`定義 乙(...)
   @別の物.乙(...)
`

# 末尾の引数の転送
`定義 不明な操作(名前, [...])
   @別の物.__送信__(名前, [...])
`

Ruby 2.7で追加された組(クラス)や操作(メソッド)を添付文書に追加する

Ruby 2.7で次の組(クラス)が追加されたので、添付文書の組(クラス)の一覧に追加する。

  • Enumerator::Producer
  • NoMatchingPatternError

Ruby 2.7で次の類型適合(パターンマッチング)用に物(オブジェクト)を分解(deconstruct)する操作の英名を自動定義するようにしたので、添付文書の自動定義の一覧に追加する。

  • 分解deconstruct
  • キーで分解deconstruct_keys

数学関数を修正する

Math.ldexp(x, exp)

修正内容

日本語の別名を二の冪乗から二の冪乗の乗算に修正する。

修正理由

関数の戻り値が二の冪乗(2**exp)ではなくx*(2**exp)なので、名前が適切でなかったため見直す。

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.