Change algorithm used to adjust positions for undo in region
authorBarry O'Reilly <gundaetiapo@gmail.com>
Thu, 1 May 2014 23:25:28 +0000 (19:25 -0400)
committerBarry O'Reilly <gundaetiapo@gmail.com>
Thu, 1 May 2014 23:25:28 +0000 (19:25 -0400)
commit4807c7eb90073c60996fe2224c2e9e1c2072624d
treea114af9783f36dca823d9b7873e73f99d56e7a73
parent17a873c585321b47bcbf46612902245c49c422de
Change algorithm used to adjust positions for undo in region

* simple.el (undo-make-selective-list): New algorithm fixes
incorrectness of position adjustments when undoing in region.
(Bug#17235)
(undo-elt-crosses-region): Make obsolete.
(undo-adjust-elt, undo-adjust-beg-end, undo-adjust-pos): New
functions to adjust positions using undo-deltas.
* automated/undo-tests.el (undo-test-region-deletion): New test to
demonstrate bug#17235.
(undo-test-region-example): New test to verify example given in
comments for undo-make-selective-list.

Fixes: debbugs:17325
lisp/ChangeLog
lisp/simple.el
test/ChangeLog
test/automated/undo-tests.el