Re: Incorrect newline counters

Antony Dovgal <[email protected]>
Newsgroups gmane.comp.php.smarty.devel
Message-ID <[email protected]>
On Sat, 29 May 2004 23:39:49 +0400
Dmitry Koteroff <[email protected]> wrote:

> Hello.
> 
> Smarty do not preserve line numbers while compiling the template.
> When an error occurs, PHP shows line number in compiled file, and
> it does not correspond line number in the source template.
> 
><skipped>
>
> and  $a  is undefined, I get notice not in line 8, but in other.
> Resulting template contains:
> a) superfluous  \n's  - in the headder comments /* compiled from
>    ...*/, and after plugins require_once's;
> b) insufficient spaces - {strip} processed incorrectly, it glues
>    its body, replacing \n by '', but not by <?php\n?>
> 
> What do you thing about all that? If I write the patch which will
> correct line numbers, will you include it in production version?

Imho a patch, which will allow to handle correctly all mismatched Smarty
tags would be better, than a patch, which will add/remove new lines in
compiled template.

-- 
Wbr, 
Antony Dovgal aka tony2001
[email protected] || [email protected]

-- 
Smarty Development Mailing List (http://smarty.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.