Why is Enumerable#each_with_object deprecated?

后端 未结 3 505
甜味超标
甜味超标 2020-12-09 04:59

According to APIdock, the Ruby method Enumerable#each_with_object is deprecated.

Unless it\'s mistaken (saying \"deprecated on the latest stable versio

3条回答
  •  孤城傲影
    2020-12-09 05:13

    Well, that seems a bit weird.

    Even Agile Rails writes somewhere:

    "The Ruby 1.9 each_with_object method was found to be so handy that the Rails crew backported it to Ruby 1.8 for you".

    This seems like an error in APIdock ? I don't see any reason why it would be.

提交回复
热议问题