[Date Index][Thread Index]
[Date Prev][Date Next][Thread Prev][Thread Next]
Re: Bug in wml?
- From: Denis Barbier <nospam@thanx>
- Date: Sat, 29 Dec 2001 02:28:33 +0100
On Mon, Dec 24, 2001 at 04:55:46PM +0530, raj@creato.org wrote:
>
> Hi all,
>
> The following piece of WML gives a compilation error whenever the body of
> the "bid" tag matches the Perl regexp \d.*. Is that a bug in wml or
> am I doing something wrong?
>
> Thanks,
> RG
>
>
> <define-tag bid>
> <:
> $bid = %body;
> #Some other piece of code that is irrelevant
> :>
> </define-tag>
>
> #Gives a compilation error if the argument to "bid" is of form
> #"\d.*"
> <bid 2C>
>
> Output of wml after running "wml filename" on this file:
>
> ePerl:Error: Perl parsing error (interpreter rc=255)
>
> ---- Contents of STDERR channel: ---------
> Bareword found where operator expected at /tmp/wml.2639.tmp1.wml line 25,
> near "2C"
> (Missing operator before C?)
> syntax error at /tmp/wml.2639.tmp1.wml line 25, near "2C"
> Execution of /tmp/wml.2639.tmp1.wml aborted due to compilation errors.
> ------------------------------------------
> ** WML:Break: Error in Pass 3 (rc=74).
Hi,
there is no bug here. Type
wml -p12 filename
to see which input file is sent to ePerl. It looks like
<:
$bid = 2C;
:>
which is invalid Perl code, and causes this error. You have to add
quotes to fix this, e.g.
$bid = '%body';
or
$bid = q{%body};
or
$bid = <<'HERE'
%body
HERE
;
You have to choose a delimiter which cannot appear in %body.
--
Denis Barbier
WML Maintainer
______________________________________________________________________
Website META Language (WML) www.engelschall.com/sw/wml/
Official Support Mailing List sw-wml@engelschall.com
Automated List Manager majordomo@engelschall.com