[Date Index][Thread Index]
[Date Prev][Date Next][Thread Prev][Thread Next]

Nested ePerl tags implementation



Hello!

I found the following problem when using <perl... tags defined in std/tags.wml
(I am sorry if this is a known issue): (the funny) nesting ePerl tags
construction sometimes does not work. An example

#use wml::std::tags
<define-tag nesting endtag=required whitespace=delete>
<perl>
    <perl:assign:sq $body>%body</perl:assign:sq>
    <perl:print: $body>
</perl>
</define-tag>
<nesting><nesting>ABC</nesting></nesting>
<nesting>D<nesting>E</nesting>F</nesting>


This script produces:
ABC

I found the reason for such a behaviour. Here is the diff:

181,182c181
<    $perl_var<substract <get-var __perl:level /> 1 /> .= <<"EPERL_EOT";
< <perl:var />\
---
>    $perl_var<substract <get-var __perl:level /> 1 /> .= <perl:var /> . <<"EPERL_EOT";

It works. In particular, with the new version of tags.wml the example above
produces:
ABC
DEF

Hope, this will be helpful for somebody.
With best regards,
Petr Andreyev

______________________________________________________________________
Website META Language (WML)                www.engelschall.com/sw/wml/
Official Support Mailing List                   sw-wml@engelschall.com
Automated List Manager                       majordomo@engelschall.com