You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@velocity.apache.org by bu...@apache.org on 2005/07/14 16:11:29 UTC
DO NOT REPLY [Bug 35738] New: -
Semantics of escaping unclear
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=35738>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.
http://issues.apache.org/bugzilla/show_bug.cgi?id=35738
Summary: Semantics of escaping unclear
Product: Velocity
Version: 1.3.1
Platform: PC
OS/Version: Windows 2000
Status: NEW
Severity: normal
Priority: P2
Component: Source
AssignedTo: velocity-dev@jakarta.apache.org
ReportedBy: frank.fischer.mail@web.de
I think the semantics of the escaping operator \ (backslash) are not documented
clearly. Especially I miss this ones:
Why generates
\$foo ==> $foo
but
\${foo} ==> \${foo}
this seems inconsistent to me. I expect
\${foo} ==> ${foo}
I understand that
${foo:bar}
raises an error since there are no : (colons)
allowed in a variable-name.
But why raises
\${foo:bar}
also an error? I would expect that \$ disables the function of $
as an operator, so that the following {..} will not be parsed as
a variable name.
There should be a simple way to generate something like
${foo:bar}
or even
${not a variable name at all &%$}
The workaround
#set($D='$')
${D}{foo:bar}
is undocumented and REALLY ugly.
--
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
---------------------------------------------------------------------
To unsubscribe, e-mail: velocity-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: velocity-dev-help@jakarta.apache.org