Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Code revision comparison utility sans formatting

Status
Not open for further replies.

steve4king

IS-IT--Management
Feb 6, 2007
154
0
0
US
I tried posting this earlier today (and it apparently didn't take??) So my apologies if it appears twice.

I have utilities to compare different code revisions, which is really handy if a new bug is introduced while adding a feature or fixing another bug. However, one of my programmers is fond of fixing bad formatting as he comes across it.. which is good.. but it makes code comparisons very difficult.

Do any of you know of a tool that is able to display differences between code while ignoring formatting differences?

I'm working in Delphi, Borland, C builder, and C#

Thanks!
-Stephen
 
some diff tools have an option to ignore whitespace.
another option is to agree upon formatting.
finally keep checkins small and frequent. you can then check the comments to see if it's a real change, or just formatting.

that's a start anyway. I don't think there is a way to "ignore formatting" though. that's the point or diffs. compare what changed. not how it changed.

Jason Meckley
Programmer

faq855-7190
faq732-7259
 
That actually helped a lot.
Thanks guys.

Shame there isn't a compile time comparison utility (compiler has to break it down anyway..) Java apparently has some level of this built in, but it would be nice to see the other compilers follow suit.
 
Hi!

You can always use ILDASM to disassemble into IL and compare it.

ILDASM /OUT:<YourFileName>.IL <YourFileName>.EXE

Regards
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top