ruby - 在 Ruby 1.9 中使用 andand 时避免 object_id 警告?

标签 ruby andand

当我在 Ruby 1.9 中加载 andand 时收到警告

andand.rb:111: warning: undefining 'object_id' may cause serious problem

除了修改 and 和不删除 object_id 之外,有谁知道避免此警告的方法吗?

谢谢!

最佳答案

你很幸运 - 它刚刚用 a fix for this issue 打了补丁.

不幸的是,截至 2011 年 3 月,gem 还没有发布这个补丁。但是,有一个 fork 的唯一目的是获得该补丁:ryansch-andand

好消息!版本 v1.3.3 已于 2012 年 3 月 28 日推送到 RubyGems,并包含此修复。

关于ruby - 在 Ruby 1.9 中使用 andand 时避免 object_id 警告?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/1322333/

相关文章:

ruby - RoR - MD5生成

ruby-on-rails - 如何准备 Ruby on Rails 开发职位的面试?

ruby-on-rails - ruby rails : debugging rake tasks

python - 是否有像 Ruby 的 andand 这样的 Python 库(或模式)?

perl - Perl 有 andand 吗?

javascript - 是否有与 Ruby 的 andand 等效的 Javascript?

ruby - 测试退出!与 RSpec

mysql - 使用 structure.sql 而不是 schema.rb 为 MySQL 配置公寓 gem 以创建新租户