skip to main
|
skip to sidebar
0
Posted on
Tuesday, August 29, 2017
by
醉·醉·鱼
and labeled under
ruby
- def...end, class...end, module...end都是作用域门,进入他们就会出现新的scope
- block是特殊的scope,block中initialize的局部变量在外部没法访问
- 扁平作用域可以用,define_method, Class.new, Module.new来实现。
Post a Comment