You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@velocity.apache.org by "Nathan Bubna (JIRA)" <de...@velocity.apache.org> on 2010/08/26 16:01:54 UTC
[jira] Resolved: (VELOCITY-774) Provide #unset directive
[ https://issues.apache.org/jira/browse/VELOCITY-774?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Nathan Bubna resolved VELOCITY-774.
-----------------------------------
Resolution: Won't Fix
#set( $foo = $null )
or put your context into itself and do:
#set( $ignore = $!context.remove($foo) )
or in 1.7+ enable the particular explicit scope that you need:
macro.provide.scope.control = true
and then do:
$macro.foo = 'whatever'
and when the macro is gone, $macro.foo will be gone too.
> Provide #unset directive
> ------------------------
>
> Key: VELOCITY-774
> URL: https://issues.apache.org/jira/browse/VELOCITY-774
> Project: Velocity
> Issue Type: New Feature
> Components: Engine
> Affects Versions: 1.7-beta1
> Reporter: Michael Osipov
>
> Sometimes one wants to use a variable in a certain scope because the further existence might lead to errors. I declared var with #set should be unsettable. See VELOCITY-773 for a iuse case.
--
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: dev-unsubscribe@velocity.apache.org
For additional commands, e-mail: dev-help@velocity.apache.org