Yes, "will no longer compile" is advantage for me too. I found ".*" ans "short" package names are better to use in practice, but I do not believe it is possible to find "the best way".
----- Original Message ----- From: "Alex Chaffee / Purple Technology" <[EMAIL PROTECTED]> To: "Jakarta Commons Developers List" <[EMAIL PROTECTED]> Sent: Thursday, April 03, 2003 2:45 AM Subject: Re: import * vs explicit debate > On Wed, Apr 02, 2003 at 06:52:26PM -0500, __matthewHawthorne wrote: > > > > But later on, if the class org.apache.Thing is created, the code will no > > longer compile, right? > > Right. > > > Isn't this an untouchable reason for using explicit imports? > > No; it's a reason for doing a full clean build and unit test run > before checking in any changes. > > This way whoever added org.apache.Thing, or updated the library that > added it, is responsible for not breaking everyone else's build. > > In this case causing a compiler error is good; the error will mention > the name of the class that was just added; and the adder will say "oh, > duh" and know what to do to fix it. More troublesome are interface > changes that are silently absorbed but cause semantic changes. > > -- > Alex Chaffee mailto:[EMAIL PROTECTED] > Purple Technology - Code and Consulting http://www.purpletech.com/ > jGuru - Java News and FAQs http://www.jguru.com/alex/ > Gamelan - the Original Java site http://www.gamelan.com/ > Stinky - Art and Angst http://www.stinky.com/ > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
