responds_to?
It is a pseudo-method because it only accepts a symbol literal as its argument, and is also treated specially by the compiler, as explained in if var.responds_to?(…).
It is a pseudo-method because it only accepts a symbol literal as its argument, and is also treated specially by the compiler, as explained in if var.responds_to?(…).
本文档使用 全库网 构建