Chinaunix's Archiver
论坛
›
Ruby
› 代码块
shijiang1130
发表于 2013-04-16 17:12
代码块
pr=Proc.new { p "Proc object" }
pr.call
def test_proc(&sample)
sample.call
end
test_proc { p "another sample" }
pitonas
发表于 2013-04-18 17:19
代码块确实是好
页:
[1]
查看完整版本:
代码块