Re: string_exec()

new topic     » goto parent     » topic index » view thread      » older message » newer message
dcuny said...
jimcbrown said...

What I had envisioned includes the ability to modify true top-level code and then re-execute it.

My concern is that you'll effectively be in the middle of the top-level code:

-- this 
string_exec(...) 
-- that 

If I understand your scheme, it would effectively become:

-- this 
string_exec(...) 
-- code generated by string_exec()  <-- code begins re-executing here 
-- that 

Is that correct?

That's effectively what happens in the example I posted, though I don't call it string_exec() anymore. However, I envisioned a greater level of control over this however, in that you could control exactly where the code generated is inserted, and also you could separately control where re-execution begins. They don't have to be the current position or even the same place at all.

dcuny said...
jimcbrown said...
dcuny said...

If the request is allowing self-modifying code, what exactly does that mean? Can a routine be redefined?

Yes.

It seems you can get the same result via routine_id, at a much cheaper cost.

- David

How does one redefine a routine with routine_id() ?

I had envisioned the ability to rewrite the code of a pre-existing routine on the fly, to make it behave completely different.

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu