Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
DiffChunks() with empty slices fails #10
Wow, yep there's a bug in there somewhere. I haven't immediately figured out where it is, though... the code was largely modeled on a research paper, and I made the mistake of using their totally-opaque names for everything, and have now forgotten most of how the implementation works. I'll try to get it fixed, but no promises on timeline.
The good news is that, for whatever reason, the algorithm seems to work fine for the usual cases that are called by the "pretty" package, so it's probably some degenerate case that's missing from the code. It could be as simple as hard-coding the "everything added" and "everything deleted" case, but I want to convince myself that the algorithm shouldn't be able to handle that first, before I do it.