My diff-lcs PR was merged, but I think we should merge the rest of this, as it still applies, this chunk can be discarded if you'd like (I actually brought it across from @samphippen's branch).