Commit cd6d305e authored by Karl Heuer's avatar Karl Heuer

(indent-line-to): Fix off-by-one bug when deciding

whether to delete the existing spaces.
parent 3ec18f3f
......@@ -84,7 +84,7 @@ only if necessary. It leaves point at end of indentation."
(back-to-indentation)
(let ((cur-col (current-column)))
(cond ((< cur-col column)
(if (> (- column (* (/ cur-col tab-width) tab-width)) tab-width)
(if (>= (- column (* (/ cur-col tab-width) tab-width)) tab-width)
(delete-region (point)
(progn (skip-chars-backward " ") (point))))
(indent-to column))
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment