This project's goal is to create a tool that will fix misuse of both space/tab for both alignment/indentation in source code (primarily for C).


March 2012: Currently I have a lot of other things with higher priority, so this project will see little or no progress until later this year, but at least it is now officially started.

I have a simple perl script that does correctly converts spaces used for indentation to tab as well as converting tabs not used for indentation into spaces. It works well but has one short comming, it will treat all space at the beginning of the line as indentation (and convert to tabs), but some of it might actually be alignment, for instance in the following example

	printf("The values of x, y and z are %d, %d, %d\n",
	                                      x,  y,  z);

spaces from under the 'p' character up til 'x' should be left as is. I am working with an idea (and has started prototyping) for a C program that will properly handle this, so that the tool can be run over and over again on source code without ruining it.

For a one time fix the perl script works ok, no program will ever be able to convert 100% in any case and manual inspection/correction is always needed. I will eventually get around to make a release of this as an interim solution.