ARudik / phc

Automatically exported from code.google.com/p/phc
0 stars 0 forks source link

Support locking behaviour of foreach #24

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
In the interpreter, foreach uses locks, for a reason im not totally sure
of. Investigate why this is, and support it.

Original issue reported on code.google.com by paul.biggar on 24 Apr 2007 at 2:30

GoogleCodeExporter commented 9 years ago

Original comment by paul.biggar on 2 Dec 2007 at 3:38

GoogleCodeExporter commented 9 years ago
This is handled by the lowering in Lower_control_flow, before the MIR. Foreach 
is
converted into MIR constructs representing each stage (reset, get_val, get_key, 
next,
end, has_key). These correspond to functions in the Zend API, and so the 
internal
iterators (and so the locking) are correctly handled.

Original comment by paul.biggar on 6 Sep 2008 at 4:13