ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Peter Reilly <peterrei...@apache.org>
Subject Re: local properties
Date Mon, 10 Jan 2005 18:28:02 GMT
Jose Alberto Fernandez wrote:

>We left it nowhere.
>  
>
Is true.

> 
>I still think my simple <let/> addition to <macrodef/> will solve 90% of the
use cases
>with very low impact across the code. But as anything, people will have to understand
>when to use it properly and so on.
> 
>The patch is there in bugzilla, but I will not apply it unless there is some support for
it
>(I have not have the need for local properties myself, so it is not a problem for me).
> 
>As per other approaches to local properties, unless we go and define a real semantic
>for them (like any other well design programming language out there) I see they creating
>more problems than solutions, in particular in our BC constrained world.
>  
>
I do not think that the problems are too bad (but I would say that!).

I would like to have the thread-local property implementation, however
there was a lot of discussions about syntax.

As the main use case for local properties is <macrodef> we
could just implement them for macrodefs, and if necessary
extend them later to be the free style properties.

So the syntax would be:
<macrodef name="show_length">
  <attribute name="filename">
  <local-property name="local-prop"/>
  <sequential>
     <length file="@{filename}" property="${local-prop}"/>
     <echo>The length of file '@{filename}' is ${local-prop}</echo>
  </sequential>
</macrodef>


We could implement this as a trial in ant cvs and pull it if there are 
too many issues.

Peter

> 
>Jose Alberto
>
>________________________________
>
>From: Matt Benson [mailto:gudnabrsam@yahoo.com]
>Sent: Fri 07/01/2005 15:26
>To: Ant Developers List
>Subject: local properties
>
>
>
>Does anyone recall where we left off on this
>discussion?    I think we need these, what do we need
>to resolve to get them in?
>
>-Matt
>
>
>               
>__________________________________
>Do you Yahoo!?
>Yahoo! Mail - Helps protect you from nasty viruses.
>http://promotions.yahoo.com/new_mail
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
>For additional commands, e-mail: dev-help@ant.apache.org
>
>
>
>
>  
>
>------------------------------------------------------------------------
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
>For additional commands, e-mail: dev-help@ant.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
For additional commands, e-mail: dev-help@ant.apache.org


Mime
View raw message