Is eValid able to call script by themselves

Discussion of the technology underlying the eValid solution.

Is eValid able to call script by themselves

Postby JCopage » Thu Jul 16, 2020 10:55 am

Greetings.

Can eValid scripts call themselves?

Just wondering if you ever implemented that kind of thing?

Thanks
JCopage
 
Posts: 1
Joined: Thu Jul 16, 2020 10:49 am

Re: Is eValid able to call script by themselves

Postby eValid » Fri Jul 17, 2020 3:23 pm

JCopage wrote:Greetings.

Can eValid scripts call themselves?

Just wondering if you ever implemented that kind of thing?

Thanks


Thanks for posting JCopage.

You're referring to "first level recursion" and the eValid solution does NOT permit recursion.

If you have a script "A" the usual technique for implementing recursive invocation of a method is to have this command within "A":

CallScript "A"

To prevent this (for reasons described below), a specific reference by "A" to a script also called "A" is tagged as illegal.

The reason is that the actual script interpretation process in eValid is in two stages:

There is a script pre-scan that converts it into an internal format and only when that is completed does the second level interpretive engine take over an run the actual script.

This approach has the advantage that only completely correct scripts are ever run -- if there is a syntax error found in the pre-scan then the user is told that and the actual execution is prevented.

The bottom line is: sorry, no recursion.

(However, if "A" calls "B" and "B" calls "A" then no problem, because each script execution is independent of the other.)


-- eValid Support
eValid
 
Posts: 2043
Joined: Tue Jan 01, 2008 12:48 pm
Location: USA


Return to Technology

Design Downloaded from free phpBB templates | free website templates | Free Web Buttons