Refactor the code

Problems compiling? Don't understand the source code? Don't know how to code your feature? Post here.

Moderator: Moderators

Guitarm
Forum Moderator
Posts: 385
Joined: 2004-01-18 20:38

Refactor the code

Post by Guitarm » 2005-11-20 14:04

Since there's some duplicate code here and there in the DC++ source I've been thinking about refactoring.
Would it be possible to reorganize some of the common code to reach a higher level of DYI (Don't Repeat Yourself) kind of style?.
Like the HubFrame - PrivateFrame for example. They seem to share a bit of code.
Does anyone of you know of any tool (except for Diff) for comparing files and show what could be moved to a BaseClass?

/Regards
"Nothing really happens fast. Everything happens at such a rate that by the time it happens, it all seems normal."

PseudonympH
Forum Moderator
Posts: 366
Joined: 2004-03-06 07:46

Post by PseudonympH » 2005-11-20 18:46

I fail to see how DYI stands for Don't Repeat Yourself. :)

Guitarm
Forum Moderator
Posts: 385
Joined: 2004-01-18 20:38

Post by Guitarm » 2005-11-20 22:06

Ugh....DRY, happy? :)
"Nothing really happens fast. Everything happens at such a rate that by the time it happens, it all seems normal."

Pothead
Posts: 223
Joined: 2005-01-15 11:55

Post by Pothead » 2005-11-21 10:47

I use winmerge for comparing stuff and finding changes. You could probably use it to find common code. :)

Who is online

Users browsing this forum: Google [Bot] and 0 guests