• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

favorite duplicate code tool?

 
author & internet detective
Posts: 41878
909
Eclipse IDE VI Editor Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Does anyone have a favorite tool for finding duplicate (copy/pasted) code? Preferably one that is Eclipse based or runs through Ant.

I'm aware that there are a number of tools out there for finding duplicate code, but sometimes finding out what people are really using is more valuable. Your opinions helped greatly when picking a code coverage tool.
 
Rancher
Posts: 43081
77
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The only one I've used is CPD -which is part of PMD- and it does have an Ant task (not sure about Eclipse integration).
 
author
Posts: 14112
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I've tried a view, but I didn't really use any of them regularly. I think it's because I don't find much value in refactoring code that I don't currently touch anyway, and than I typically spot the duplication without the use of a tool.

Another thing is that those tools can only spot syntactic duplication. Most often, it's the semantic duplication that's killing me - two parts of code that are doing the same thing in slightly different ways...
 
Jeanne Boyarsky
author & internet detective
Posts: 41878
909
Eclipse IDE VI Editor Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Interesting. Thanks guys.

Ilja: Thanks for adding something about the tools that I didn't think about
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic