Home All Groups Group Topic Archive Search About

PP: Identifying list of unwanted USINGs

Author
10 Mar 2006 4:40 AM
prabhupr
Hi Folks

In CS project, we use "using" statement to make reference to other
namespaces. For example:
using System;
using System.Data;
using System.Configuration;


At times, there a is a chance that few of them get added by mistake or
must have got added for some need and developers must have forgotten to

remove them back when not required :)


Question:
1. Is there any easy way (may be some tool) to identify if any of these

namespaces are orphan (not relevant to that CS file) and can be removed

2. What are the dis-advntages of leaving them there as it is.  Any
performance issues?

Author
10 Mar 2006 5:23 AM
Michael Nemtsev
Hello prabh***@hotmail.com,

For looking the unused "using" I recomend ReSharper tool (www.jetbrains.com)

Show quoteHide quote
> In CS project, we use "using" statement to make reference to other
> namespaces. For example:
> using System;
> using System.Data;
> using System.Configuration;
> At times, there a is a chance that few of them get added by mistake or
> must have got added for some need and developers must have forgotten
> to
>
> remove them back when not required :)
>
> Question:
> 1. Is there any easy way (may be some tool) to identify if any of
> these
> namespaces are orphan (not relevant to that CS file) and can be
> removed
>
> 2. What are the dis-advntages of leaving them there as it is.  Any
> performance issues?
>
---
WBR,
Michael  Nemtsev :: blog: http://spaces.msn.com/laflour

"At times one remains faithful to a cause only because its opponents do not
cease to be insipid." (c) Friedrich Nietzsche
Are all your drivers up to date? click for free checkup

Author
10 Mar 2006 5:37 AM
Daniel O'Connell [C# MVP]
>
> 2. What are the dis-advntages of leaving them there as it is.  Any
> performance issues?

No. They are nothing but compiler instructions.
Show quoteHide quote
>

Bookmark and Share