ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dominique Devienne" <>
Subject RE: local properties note WAS PropertySet use in macro
Date Wed, 01 Sep 2004 23:04:13 GMT
> From: Dick, Brian E. []
> I don't think <local> is the solution either, because that provides
> local scope for properties SET in the macro. I don't want to set any
> properties. I just want to access the properties in a given
> And if there is a mapper specified, I want to access the properties by
> their mapped name.

This time I'm with Matt. You do in fact want to set properties within
scope of the macro: but that I mean that you want to set all the
from a propertyset as new properties (with the name changed according to
an optional mapper), just so you can access them within the macro as

This is can live with, because this time it's using propertyset to
inject or 'pass in' (in a way) these properties to the macro, where
they are used as regular properties (possibly shadowing similarly
named properties from the context in which the macro executes), which
is the intended purpose (at least originally) of propertyset.

I still cannot think of a situation where I'd use such a feature,
but it doesn't sound like a hack anymore, only like just one more
thing to stump the heck out of most users ;-)

But of course, as Matt points out, <macrodef> currently has no
scope. I fully support adding scoping to <macrodef> to be able
to use internal, temporary properties to the macro that would
not propagate outside that macro; OTOH I see less value in injecting
internal/temporary/scoped properties from the outside in to the
macro, but I'm not against it.

Whether limited and explicit <macrodef> scoping is implemented
with <local> or not is not really a concern to me. --DD

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message