As outlined by Dan in [1] subs marked IMMEDIATE are run during compilation, as soon as the compiler (in pbc.c) sees the end of that subroutine.
There are a lot of caveats, nothing is checked currently: if that sub does load_bytecode you'll have much fun ...


In that thread I also asked:

> POSTCOMP subs are executed as soon as compilation is done, once again
> with no parameters. Whether they do a whole lot is up in the air, but
> that's not my problem, and it'll be useful for compile-and-go systems.

Can that not be achieved by either MAIN or LOAD?

--
So what is actually the difference between POSTCOMP and LOAD?

leo

[1]
Subject: Loading bytecode at runtime
Date: Feb 2004



Reply via email to