Re: Clonedigger for C#

47 views
Skip to first unread message

Samuel

unread,
May 11, 2009, 4:23:55 PM5/11/09
to Peter Bulychev, clonedigg...@googlegroups.com
Hello Peter,

Thanks for the links.
What kind of C# projects are you thinking about ? I suppose you would like some projects with clones and other similar code blocks. But to they need to have certain characteristics like containing as much language specific statements like if, switch, loops, try...catch, ... 
Or are you just looking for existing C# open source projects to run ?

Best regards,

Samuel

On Fri, May 8, 2009 at 9:48 PM, Peter Bulychev <peter.b...@gmail.com> wrote:
Hello, Samuel.

I'm glad to hear that you like the tool.

I'm also interested in extending Clone Digger to other programming languages, so we can collaborate.

I've found ANTLR grammar for C# with Java target:
http://deftproject.svn.sourceforge.net/viewvc/deftproject/depth/com.comarch.depth.antlrcsharp/CSharp.g?revision=41
(I found a link to this grammar here: http://markmail.org/message/326geuooz2s227j5?q=list:antlr+C%23+grammar&page=12)

Can you create C# corpora, i.e. a set of C# projects?

I'll check this grammar on your corpora and if it is good enough, we'll integrate it to Clone Digger.
I can do this integration, you can do it also (there are instructions here: http://groups.google.com/group/clonedigger_general/browse_thread/thread/568a4f140d70a6de).

Than we will tune default thresholds (minimum clone size and maximal amount of differences), it is the easiest part :)

It's better to continue discussion in public mail list.
So, if you don't mind, please CC your answer to clonedigg...@googlegroups.com .

(http://groups.google.com/group/clonedigger_general/browse_thread/thread/568a4f140d70a6de)

2009/5/8 Samuel <samuel...@gmail.com>

Hello,

First I really want to thank you for CloneDigger. I've used it on a python project and I especially liked the way the clones are shown in the output file.

But most of the time I'm developing in C# and I tested simian but I didn't like the output it gave me and it only showed obvious clones.

Is there any effort on the way to make Clonedigger search for clones in C# ? And can I help out ?

I am 26 years young/old GIS consultant. I've got a master in geography but since I graduated I worked as a programmer for a consulting firm.
I mostly programmed in C# but I've also done some projects in Python (sadly way to less). And I finally want to give something back to the community. I also recently started a blog (gissolved.blogspot.com) but I want to do more.

Kind regards an greetings from Belgium,

Samuel Bosch



--
Best regards,
  Peter Bulychev.

Peter Bulychev

unread,
May 12, 2009, 2:15:39 AM5/12/09
to Samuel, clonedigg...@googlegroups.com
Hello Samuel.

2009/5/12 Samuel <samuel...@gmail.com>

Hello Peter,

Thanks for the links.
What kind of C# projects are you thinking about ? I suppose you would like some projects with clones and other similar code blocks. But to they need to have certain characteristics like containing as much language specific statements like if, switch, loops, try...catch, ... 
Or are you just looking for existing C# open source projects to run ?
I guess it would be nice to have about 3 open source projects of different sizes, i.e. small, medium size (10000 LOC) and large (up to 100000 LOC).
Later we'll use the same projects to measure the performance of the tool, thus we need projects of different sizes.
Yes, we can check if all the specific C# statement exists in those projects.
I don't think we should look for projects with preexisting clones, because all the projects I've seen so far contain some duplicated code.


Samuel

unread,
May 15, 2009, 4:53:09 AM5/15/09
to Peter Bulychev, clonedigg...@googlegroups.com
Hello,

I identified some open source projects that could be used for testing CloneDigger on C# code.

110107 firefx2-rc3-src

99217 umbraco 4.0.1 source

17200 irony-20817

5839 SharpGPS-v0.5-6030

1593 duplifinder-19086

The numbers are from a small Python script that I wrote to count the numbers of non empty lines in .cs files.

I wanted to attach the sources but they where blocked by gmail so you'll have to download them.

Best regards,

Samuel
Reply all
Reply to author
Forward
0 new messages