ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stefan Bodewig <>
Subject Re: [PATCH] allowing filters to resolve properties before substituting
Date Fri, 27 Apr 2001 11:19:16 GMT
John D. Casey <> wrote:

> This patch allows the user to OPTIONALLY specify that filters
> containing property names in the standard reference syntax (
> ${} ) will be resolved to actual values before
> substitution.

Hmm, if you define filters with the filter task and their token or
value attribute contains a ${reference}, this one is going to be
expanded at the point the filter gets defined.

This is what happens in all other tasks as well.

Your patch would apply to cases, where you define a filter containing
property references before you define the corresponding property.  Why
would you do that?

> Because I recognized that properties may change during the course of
> a build, and ideally the resolution of a filter should take place at
> the time of substitution, to get the most up-to-date property value.

This is the only reason for setting filters before defining properties
I could come up with.  Actually, I feel a bit uncomfortable with this,
as we would give token filters some "special" ability other data
structures don't have (patterns containing references for example).

It seems we are going to change the whole copy/filter stuff for Ant2
and I'm hesitant to change it now (this is why I wouldn't like to
commit Michael's filterset patch either), unless I knew the behavior
wouldn't be radically different in Ant2.  IMHO it doesn't make sense
to let the users adopt something new now, that won't be in Ant2.


View raw message