摘要: 第4章代码块blocks 基础知识 作用域:用代码块携带variables through scopes 通过传递block给instance_eval方法来控制作用域。 把block转换为Proc,lambda这样的可反复调用的对象。4.5 4.12基础 def a_method(a,b) a + 阅读全文
posted @ 2018-03-11 11:46 Mr-chen 阅读(191) 评论(0) 推荐(0) 编辑