[
https://issues.apache.org/jira/browse/VELOCITY-614?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12632362#action_12632362
]
Nathan Bubna commented on VELOCITY-614:
---------------------------------------
This won't be fixable without postponing exceptions for bad arguments to
runtime-defined macros until runtime. If #something is already a known macro,
it's easy enough to still throw the parse exception as currently happens. But
if we want #something(Stuff) to work when it is just schmoo (i.e. there is
never a #something macro), then we have to postpone the decision to render it
as-is or throw a bad argument exception. We can't tell for sure at parse-time.
I think postponing the error until runtime is acceptable, and better than the
alternative of not requiring the #set( $H = '#' )${H}something(Stuff)
workaround for outputting javadoc.
any thoughts?
> Impossible to escape '#' if followed by text and parenthesis(
> "\#something(Stuff)" renders with the '\')
> --------------------------------------------------------------------------------------------------------
>
> Key: VELOCITY-614
> URL: https://issues.apache.org/jira/browse/VELOCITY-614
> Project: Velocity
> Issue Type: Bug
> Affects Versions: 1.6
> Environment: I don't think it is relevant but still: CPU Intel
> Pentium D, windows XP SP3, JRE 1.6.0_07, Velocity 1.6-beta1
> Reporter: Guillaume Polet
> Priority: Minor
> Attachments: Velocity614TestCase.java
>
>
> "#something(Stuff)" in your templates (without the double quotes) causes a
> parse error.
> "\#something(Stuff)" in your template (without the double quotes) renders as
> "\#something(Stuff)"
> Either the first line should go through just fine, or the next one should not
> render the '\'
> This typically happens when you try to generate JavaDoc for overriding
> methods.
> Don't hesitate to contact me if this is not clear enough or if you are unable
> to reproduce this issue.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]