It sounds like you need to re-write your >application my friend 🙂
I wish I were at that level 🙂 Unfortunately
handling of pieces of quite independent, generic code, written by others, stored in a database and executed at will possibly more
than once is the task in the question.
I'm not sure what you're asking though. Any
Something like this to work:
while (x) { / begin of scope /
/ Senseless but for example: /
function MySubFunction () {
do_something();
}
/* The feature above applied: */
eval ($some_arbitrary_code_that_
also_contains_a_function_
declaration);
} / end of scope /
function_exists (MySubFunction) == 0
Scoping variables works fine, I wish there was a block construct that can be used as a scope for both variables and functions.
regards,
yason