> Not a flaw… don’t do this… you know you are not supposed to,

I did it on purpose to see what happens. I'm fanatical about checking
inputs and preconditions and wanted to see what sort of error to trap for.
In many cases, there is no error trapped - it just screws up.

This scenario is *way* to easy to produce in the wild to simply leave it up
to developers to screen their own code. I objected to EXECUTE for a very
long time because of this very reason. Unsafe at any speed. I only started
using it under tight regulation once I could check that a method exists
before running the code.

This situation would be 100% avoidable with as lightly different design for
CALL WORKER. Instead of appending code to the workers chain of execution,
pass a message. (CALL WORKER calls are not messages in any normal use of
that word in computing.) Pass a message, let the developer collect it and
decide what to do. At that point, it's on us. As it stands, it's on them as
they haven't provided 1) proper intercept tools to screen the call before
it is executed, 2) a reliable or consistent error handling mechanism to
trap the error.

> I was told it will produce a runtime error

Sometimes it produces a runtime error, sometimes it doesn't. Sometimes it
kills the process that then restarts.

On Sun, May 7, 2017 at 12:37 PM, npdennis <npden...@greatext.com> wrote:

> CALL WORKER("Preeemptive_Worker";"Display_Message";"Hello world!”)
>
>
> Not a flaw… don’t do this… you know you are not supposed to, I was told it
> will produce a runtime error
>
> This is the same as
>
> C_LONGINT(myVar)
> EXECUTE FORMULA(“myVar:=\”Hello\””)
>
> It will compile just fine, but throw a runtime error.
>
>
> --
> Neil Dennis
> 4D Developer since 1990
>
> GreaText - Designing Software for the Way You Work
> 716 East 1850 N
> North Ogden, UT 84414
>
> mailto:npden...@greatext.com <npden...@greatext.com>
> http://www.greatext.com/
>
>
>
**********************************************************************
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**********************************************************************

Reply via email to