I agree with Lars-Inge: there is no magic tool that will rate your code and
detect bad algorithms or bugs automatically. If there was such a program, it
would be a real star. But there won't be one because there are some
theoretical issues here: for example, no program will ever be able to
analyze *any* algorithm and say if it terminates or not (some programs may
be able to give answers in special cases, but no program will be able to
give an answer in all cases -- this is called the "halting problem").
On the other hand, there are some tools that will help you:
* For easy stuff like unused variables, you don't need any special tool
because the compiler does it if you turn on the appropriate warning level.
* You should not worry too much about memory leaks in the "classical" sense
because the memory is managed automatically. On the other hand, you may
encounter situations where memory is not released because objects are
maintained alive through some references that you have difficulty tracking
down. In this case, a memory profiler like Borland's OptimizeIt may be
helpful (Rational has some tools in this area too). Note: you don't need to
worry about memory corruption (buffer overruns) in managed languages like
Java or C#.
* A tool like FxCop (
http://www.gotdotnet.com/team/fxcop) may be interesting
if you want to enforce the Microsoft coding conventions in your libraries.
Unfortunately, some of these rules clash with the Java conventions, and the
J# compiler does not always emit code that keeps FxCop happy. So, this tool
works better with C# than with J#, but you can give it a try.
And the best tool is probably you: read good books, learn about good
programming practices (use assertions, write small methods, use clear and
consistent naming, etc.). Don't rely too much on tools, rely on good coding
practices in the first place.
Bruno.
"Abc" <anonymous@discussions.microsoft.com> a écrit dans le message de
news:05af01c3cf50$f7b28130$a401280a@phx.gbl...
[quoted text, click to view] > Check altogether quality of code.
> It may be algorithms,or programming errors etc.
>
> In short given an input file , it should give the quality
> of code like if any unused variables or memory leaks etc.
>
> Thanks,
>
>
> >-----Original Message-----
> >
> >Test what kind of code (algorithms?) ?
> >
> >Do you have any tool samples for any other languages so
> we know what to look
> >for?
> >
> >
> >Lars-Inge
> >
> >"Abc" <anonymous@discussions.microsoft.com> wrote in
> message
> >news:036401c3ced2$b4864be0$a001280a@phx.gbl...
> >> Hi,
> >>
> >> Is there any tool which tests the j# code quality?
> >> If anybody knows please help me out.
> >>
> >> Thanks
> >>
> >
> >
> >.
> >