Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re: Using DateTime together with Template::Toolkit

by mdillon (Priest)
on Mar 01, 2005 at 06:59 UTC ( #435296=note: print w/ replies, xml ) Need Help??


in reply to Using DateTime together with Template::Toolkit

If you were using the XS Stash, I don't think this would be a problem.

If you really have a reason to use the non-XS stash, you can patch TT. The fix is to change the code that creates the $atroot variable in the _dotop method. It is described in this post to the TT mailing list. There is similar code in _assign that could probably stand to be patched as well.

Note: The change in question adds a dependency on the Scalar::Util module, which should work on whatever version of Perl you can run TT on.


Comment on Re: Using DateTime together with Template::Toolkit
Replies are listed 'Best First'.
Re^2: Using DateTime together with Template::Toolkit
by Corion (Pope) on Mar 01, 2005 at 07:27 UTC

    I don't know resp. didn't check if the XS Stash is active or not, but it sure sounds like if it isn't. The patch you mentioned sounds promising - I will try that!

    Of course, there shouldn't be a difference between the XS version and the Pure Perl version of Template::Stash.

      I agree that they should work the same, but in this case, there is a discrepency.

      I only suggested using the XS Stash instead since it seems to work correctly. Also, that message was posted to the TT mailing list a few months ago (in response to a message from the maintainer, so he's obviously aware of it) and there hasn't been a release containing the fix yet. That makes me think that waiting for the pure Perl Stash to work may take a while.

      Why not? They do different things ...

      Being right, does not endow the right to be rude; politeness costs nothing.
      Being unknowing, is not the same as being stupid.
      Expressing a contrary opinion, whether to the individual or the group, is more often a sign of deeper thought than of cantankerous belligerence.
      Do not mistake your goals as the only goals; your opinion as the only opinion; your confidence as correctness. Saying you know better is not the same as explaining you know better.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://435296]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others lurking in the Monastery: (16)
As of 2015-07-07 17:39 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (93 votes), past polls