i dont think it would be too hard to make a script to do that. u would have to make it regex for all the variables and find shortest names possible, and then make it replace whitespace with a space or something. it would be hard but would be a cool script. i would use perl to do it if anything..
edit: i have NO clue how it would redo the actaul structure of the coding if u did something unnessicary.. unless u regex REALLY well and use a lot of diferent cases.. it would be real hard to do that. whitespace adn variables are easier and probably enough but the actaul coding would be hard to have optimized by a script that u make..