Code Hygiene; Unused Imports

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Code Hygiene; Unused Imports

Ernst, Matthias
Hi,

as a user of IntelliJ I've become used to check the code analyzer
"traffic light" and want to let you know that a number of files in j.u.c
(1.5.0_06) had warnings on them ("unchecked" warnings aside):

Delayed, Semaphore, ScheduledExecutorService, ExecutorService,
CountdownLatch, ConcurrentHashMap, LockSupport, ReentrantLock,
ReentrantReadWriteLock have unnecessary imports. DelayQueue#take
declares an unused local "tl".

As a relatively new part of J2SE the code should set an example in
cleanliness :-)
I haven't looked into Mustang.

Cheers
Matthias

--
Matthias Ernst
Software Engineer
 
tel +49.40.32 55 87.503
fax +49.40.32 55 87.999
[hidden email]

_______________________________________________
Concurrency-interest mailing list
[hidden email]
http://altair.cs.oswego.edu/mailman/listinfo/concurrency-interest
Reply | Threaded
Open this post in threaded view
|

RE: Code Hygiene; Unused Imports

David Holmes-3
Matthias,

I haven't checked in detail but many of the "unused" imports are/were
actually needed to workaround a javadoc bug - ie we needed the import for
javadoc, not javac.

Not sure of the current state of the world there.

Cheers,
David Holmes

> -----Original Message-----
> From: [hidden email]
> [mailto:[hidden email]]On Behalf Of Ernst,
> Matthias
> Sent: Tuesday, 14 March 2006 9:24 PM
> To: [hidden email]
> Subject: [concurrency-interest] Code Hygiene; Unused Imports
>
>
> Hi,
>
> as a user of IntelliJ I've become used to check the code analyzer
> "traffic light" and want to let you know that a number of files in j.u.c
> (1.5.0_06) had warnings on them ("unchecked" warnings aside):
>
> Delayed, Semaphore, ScheduledExecutorService, ExecutorService,
> CountdownLatch, ConcurrentHashMap, LockSupport, ReentrantLock,
> ReentrantReadWriteLock have unnecessary imports. DelayQueue#take
> declares an unused local "tl".
>
> As a relatively new part of J2SE the code should set an example in
> cleanliness :-)
> I haven't looked into Mustang.
>
> Cheers
> Matthias
>
> --
> Matthias Ernst
> Software Engineer
>
> tel +49.40.32 55 87.503
> fax +49.40.32 55 87.999
> [hidden email]
>
> _______________________________________________
> Concurrency-interest mailing list
> [hidden email]
> http://altair.cs.oswego.edu/mailman/listinfo/concurrency-interest

_______________________________________________
Concurrency-interest mailing list
[hidden email]
http://altair.cs.oswego.edu/mailman/listinfo/concurrency-interest