Proc-closures capture any block passed to their enclosing scope: the script

def yielder_proc
	proc { yield "hi" }
end

(yielder_proc { |s| puts s }).call

outputs "hi".


However if the captured block calls break:

(yielder_proc { break }).call

then Ruby stops with an 'unexpected break' error, which doesn't look right.


This is true on 1.6.7 and 1.8.0 preview 2; I haven't been able to check the
latest CVS.

-- George