ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 6033] - [PATCH] Boolean attributes should accept "1" as "true"
Date Fri, 25 Jan 2002 19:35:12 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=6033>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=6033

[PATCH] Boolean attributes should accept "1" as "true"





------- Additional Comments From steve_l@iseran.com  2002-01-25 19:35 -------
C/C++ do not actually view "1" as true; their rules are. (using ==> to mean 
implies and <==> as declarative equivalence, cos I can't put the Z fontset in 
a bugrep)

0 <==> false
!false <==> true

so 1=>true ; but also 3=> true, -23555 => true. 

ant's rules are

"true" ==> true
"yes" ==> true
!true <==> false

so adding "1" to true a) changes ant's logic, b) isnt consistent with the 
C/C++ logic either, which would need to say that anything other than "0" is 
true, which definately breaks existing builds big time.

And that we do not want. So no, it wont go to later either, because it is a 
fundamental re-interpretation of what consitutues falsehood and truth. 

Sorry. We'd like to thank for your submission anyway, because it not only 
shows pent up need for mapping numbers to truth and falsehood, but because it 
shows you are willing to fiddle with the source and submit changes. We like 
that.

If you do want to map from numbers to booleans, consider adding a new 
condition test; these are easy to do and wont break any existing builds. 

Something like <numericequals arg1="${property}" arg2="1" /> for example.

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


Mime
View raw message