in reply to Re^30: aXML vs TT2
in thread aXML vs TT2

Safely returning a "<" from a plugin.

To be safe, a plugin needs to look like

sub plugin_name { my $text_to_return = ...; $text_to_return =~ s{<}{<post_include>path/to/lt</post_include>}g; return $text_to_return; }

Even then, that's not enough to make a reusable plugin because it hardcodes the path to a template.

By the way, since every plugin (except <post_include>) returns template code, this design is slow because there are soooo many templates to process, and none of them can be precompiled.

Replies are listed 'Best First'.
Re^32: aXML vs TT2
by Logicus (Initiate) on Oct 23, 2011 at 15:38 UTC

    To be honest I think your attempting to constrict the dynamism of aXML because your not yet fully comfortable with it. The ability for tags to output tags or fragments of tags is something which I use frequently and is imho one of the coolest properties of aXML.

    On the subject of compiling templates, Corion mentioned that a while ago, and I did have a go at writing a compiler but it didn't work out well. Basically I know very little, well nothing really, about compilers so if anyone out there is into compilers and feels like having a bash at it be my guest.

    In the meantime it really isn't as slow as you probably think it is, especially on modern hardware.

      To be honest I think your attempting to constrict the dynamism of aXML because your not yet fully comfortable with it.

      Wow! Not only do you lie about what I do, you make up reasons for why I must have done it!

      I've done nothing but help fix the very broken aspects of aXML, yet you accuse me of tying to break aXML. I didn't suggest anything that would limit the dynamism of aXML. I didn't make any suggestions whatsoever, actually! I just showed what code is required for aXML to work bug free to show how hard it is to use aXML correctly.

      On the subject of compiling templates, Corion mentioned that a while ago, and I did have a go at writing a compiler but it didn't work out well.

      In response to me saying it cannot be compiled, you ask for assistance in writing a compiler?

      You picked your name in irony, right?

      In the meantime it really isn't as slow as you probably think it is, especially on modern hardware.

      I don't know or care how slow or fast it is. But you do. Did you forget your own goals that you posted about 10,000 times?

      One, you want it to be fast for a long time, so it's totally irrelevant how it performs on modern hardware.

      Two, you want it to be faster than other template systems.

      Not being able to compile the templates greatly hinders both of those goals.

        I've done nothing but help fix the very broken aspects of aXML

        I appreciate your attempts to help, however you have not actually caused any change in aXML at all so far other than the inclusion of two new special chars which I've never needed and I've included merely so you can bend the way it's used to suit you. aXML is NOT broken, it works perfectly well as it is doing what it does.

        On the subject of the compilers, I told Corion about 3 months ago that I believed aXML could not be compiled, he insisted it could, now your telling me it cannot, one of the 3 of us must be wrong.

        As for performance I only care about that in so far as it matters to keeping my server bill under control. I am fully aware after having played with aXML on some IBM big iron, that the processing overhead for it is infact miniscule compared to the vast amounts of processing power available if you have enough money to pay for it.

        I don't care how it performs relative to any other language / template system. It is what it is, it works the way it works. Clearly you don't like the way it works and that's why your trying to "fix" it when it is not broken.

        Your efforts are appreciated, if however misguided.

        I've done nothing but help fix the very broken aspects of aXML

        I appreciate your attempts to help, however you have not actually caused any change in aXML at all so far other than the inclusion of two new special chars which I've never needed and I've included merely so you can bend the way it's used to suit you. aXML is NOT broken, it works perfectly well as it is doing what it does.

        On the subject of the compilers, I told Corion about 3 months ago that I believed aXML could not be compiled, he insisted it could, now your telling me it cannot, one of the 3 of us must be wrong.

        As for performance I only care about that in so far as it matters to keeping my server bill under control. I am fully aware after having played with aXML on some IBM big iron, that the processing overhead for it is infact miniscule compared to the vast amounts of processing power available if you have enough money to pay for it.

        I don't care how it performs relative to any other language / template system. It is what it is, it works the way it works. Clearly you don't like the way it works and that's why your trying to "fix" it when it is not broken.

        Your efforts are appreciated, if however misguided.