in reply to Re^2: rough start of an axml compiler
in thread rough start of an axml compiler

Just as a throw-it-out-there, how about adding markup (or detecting, depending on how sophisticated you want to be) that delineates the "definitely dynamic" and "for-sure static" portions of a page? You could pre-build whatever was invariant (I seem to be using that word a lot lately...) and reserve the slower dynamic stuff for just the part(s) that needed it.

Replies are listed 'Best First'.
Re^4: rough start of an axml compiler
by Logicus (Initiate) on Jul 22, 2011 at 06:42 UTC

    That's exactly what the sortofcompileit function does! if you run that code, you will find it spits out a bunch of print statements interspersed with print axml statements, which would call a subroutine called axml to compute the dynamic aXML bits.

    The approach would work, and it would save server time, but I just feel that given how fast servers are these days I'd rather keep my own version completely dynamic, and retain the more funky plugins which exploit the way the existing parser works rather than accept limitations on it and how it works and by setting syntax in stone for the benefit of the compiler stage. (which debates in CB seem to have concluded to be required)

    That is not to say that anyone who wants to isn't free to do exactly whatever they please with aXML, be that file it in the rubbish bin, or write their own faster/better/more efficient version or whatever, it doesn't matter to me, I let go of controlling where aXML goes the moment I decided to opensource the code and concept to the world.