You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ant.apache.org by Peter Reilly <pe...@corvil.com> on 2004/05/28 16:56:54 UTC

Re: cvs commit: ant/src/main/org/apache/tools/ant/taskdefs Define r.java

Dominique Devienne wrote:

>>-----Original Message-----
>>From: peterreilly@apache.org [mailto:peterreilly@apache.org]
>>
>>peterreilly    2004/05/28 01:20:22
>>
>>  Modified:    src/main/org/apache/tools/ant/taskdefs Definer.java
>>  Log:
>>  typedef: check for recursive loading of xml
>>           files/resources (aka antlibs)
>>[...]
>>  +  log("Warning: Attempting to recursively load " + url
>>  +      + " at " + getLocation(), Project.MSG_WARN);
>>    
>>
>
>Perhaps it's because I'm not a native English speaker, but the
>'Attempting ...' message (like the 'Overriding reference ...' one)
>always makes me wonder whether the load (or override) actually
>take place.
>
>Could the message somehow make it more explicit it's ignored? Like:
>
>	"Warning: Recursively load of " + url +
>	" at " + getLocation() + " IGNORED";
>  
>
Ok,
                        log("Warning: Recursive loading of " + url
                            + " ignored"
                            + " at " + getLocation(),

>Also, to troubleshoot these problems, knowing where the first import
>was done would help I would guess.
>  
>
True, but not done at the moment.

>Just suggestion guys, nothing more. I probably just need to learn
>English or something ;-)
>
>--DD
>
>PS: Is it a recursive import or a circular import?
>  
>
I suppose it could be seen as circular loading of an antlib resource.

>PPS: Shouldn't this message go to verbose mode only (MSG_VERBOSE)?
>     Circular includes of C/C++ headers is silently ignored.
>  
>
This could be the case for <import>, but this code is for <typedef 
file="x.xml"/> and
<typedef resource="x/y/z.xml"/>, which is possibly more likely to be an 
error to
have circular loading.

<nitpicking>circular includes of  c/c++ headers are not silently ignored 
- one
gets for gcc the following  "#include nested too deeply", one avoids
this by doing the #ifdef trick</nitpicking>

Cheers,

Peter


>---------------------------------------------------------------------
>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