By bloid
via freshvanilla.org:8080
Published: Apr 29 2008 / 11:18
While there is no doubt Closures are very powerful concept they are fairly complex to implement properly and efficiently.
However, one of the use cases, control block can be simulated using the for each loop without limiting functionality of the blocks involved.
Comments
dzonelurker replied ago:
"Limitations.
When the loop break unexpectedly, there is no guarentee when, if ever, the iterator will be closed/finalised."
Ricky Clarkson replied ago:
"While there is no doubt Closures are very powerful concept they are fairly complex to implement properly and efficiently."
A solved problem, circa 1983. Implementing closures is of known complexity. In fact, Java already has an implementation in the compiler, otherwise how would anonymous classes access things from their enclosing scope?
,
b0b0b0b replied ago:
"I would say the HotSpot JVM is not so complex"
Voters For This Link (9)
Voters Against This Link (1)