You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@velocity.apache.org by "Will Glass-Husain (JIRA)" <ji...@apache.org> on 2005/09/19 07:38:55 UTC
[jira] Updated: (VELOCITY-50) RFE: invalid parameters for #if directive should be a parse error?
[ http://issues.apache.org/jira/browse/VELOCITY-50?page=all ]
Will Glass-Husain updated VELOCITY-50:
--------------------------------------
Bugzilla Id: (was: 7386)
Fix Version: 1.6
Description:
The 3 lines below will print two No-s and one Yes:
#if('foo') Yes #else No #end
#if(1) Yes #else
No #end
#if(true) Yes #else No #end
while the 4 lines bellow will print two Yes-es as
expected:
#set($x = 'foo')
#if($x) Yes #else No #end
#set($x = 1)
#if($x) Yes #else No
#end
Also, the 2 lines below will print false:
#set($x = 'x' && true)
$x
(Please
ignore possible false line breaks inserted by bugzilla.)
Tried with 1.2 Stable and 1.3
Nightly 22/03
was:
The 3 lines below will print two No-s and one Yes:
#if('foo') Yes #else No #end
#if(1) Yes #else
No #end
#if(true) Yes #else No #end
while the 4 lines bellow will print two Yes-es as
expected:
#set($x = 'foo')
#if($x) Yes #else No #end
#set($x = 1)
#if($x) Yes #else No
#end
Also, the 2 lines below will print false:
#set($x = 'x' && true)
$x
(Please
ignore possible false line breaks inserted by bugzilla.)
Tried with 1.2 Stable and 1.3
Nightly 22/03
Environment:
Operating System: All
Platform: PC
was:
Operating System: All
Platform: PC
Assign To: (was: Velocity-Dev List)
I like the idea of adding a log message. Setting for v1.6
> RFE: invalid parameters for #if directive should be a parse error?
> ------------------------------------------------------------------
>
> Key: VELOCITY-50
> URL: http://issues.apache.org/jira/browse/VELOCITY-50
> Project: Velocity
> Type: Improvement
> Components: Source
> Versions: 1.5
> Environment: Operating System: All
> Platform: PC
> Reporter: Daniel Dekany
> Priority: Minor
> Fix For: 1.6
>
> The 3 lines below will print two No-s and one Yes:
> #if('foo') Yes #else No #end
> #if(1) Yes #else
> No #end
> #if(true) Yes #else No #end
> while the 4 lines bellow will print two Yes-es as
> expected:
> #set($x = 'foo')
> #if($x) Yes #else No #end
> #set($x = 1)
> #if($x) Yes #else No
> #end
> Also, the 2 lines below will print false:
> #set($x = 'x' && true)
> $x
> (Please
> ignore possible false line breaks inserted by bugzilla.)
> Tried with 1.2 Stable and 1.3
> Nightly 22/03
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: velocity-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: velocity-dev-help@jakarta.apache.org