So am I out of luck now?
What have you coded thus far? Maybe we can get back into it, it is an interesting problem.
I've got an idea! How about looking at the source code for GNU diff. Yea it's in C but you might be able to glean some info on how they do it and translate that into autolisp.