problems with new escape method

"georgeandhelenwilliams" <[email protected]> Fri, 08 Feb 2008 23:57:24 -0000
Newsgroups gmane.text.clearsilver.general
Message-ID <[email protected]>
Hi

I have ported clearsilver (well all the CS and HDF stuff, not the CGI 
stuff) to Windows, and am experiencing a problem. I do think that it 
is due to my port, but I'm not certain as I  dont have access to a 
unix box to check the behaviour of the original code. Please can 
someone comment on the problem before I go chasing it:

I can get the new escape method to work as I expect in the following 
constructs:

1. regular use of a variable:
<?cs escape: "html" ?><?cs var:data1 ?><?cs /escape ?>

2. around a variable in an if statement
<?cs if:data1 ?><?cs escape: "html" ?><?cs var:data1 ?><?cs /escape ?
><?cs else ?>nonsense<?cs /if ?>

but..there are couple of circumstances in which it doesn't work, 
where I would expect it to. 

1. regular use of an alt statement:
<?cs escape: "html" ?><?cs alt:data1 ?>nonsense<?cs /alt ?><?
cs /escape ?>

2. around a whole if statement
<?cs escape: "html" ?><?cs if:data1 ?><?cs var:data1 ?><?cs else ?
>nonsense<?cs /if ?><?cs /escape ?>

In both of these cases the varibale data1 is not escaped in html.

is this:
1. expected behaviour (my misunderstanding of how it should work)
2. a bug I introduced in my port to windows
3. a bug in the existing code

if anyone can comment, then I'll know where to look.

Thanks in advance
George Williams