summaryrefslogtreecommitdiffstats
path: root/Misc
diff options
context:
space:
mode:
authorBarry Warsaw <barry@python.org>1996-07-23 15:03:16 (GMT)
committerBarry Warsaw <barry@python.org>1996-07-23 15:03:16 (GMT)
commit71e315b9d90aca5b5b74ca6cf78abf6f7be744b7 (patch)
tree4b698da3a9a3f4ebf07338cf59e2744f03f20d98 /Misc
parentd3876d33d3bd958699b2e8de3258b4d0f1bc33e4 (diff)
downloadcpython-71e315b9d90aca5b5b74ca6cf78abf6f7be744b7.zip
cpython-71e315b9d90aca5b5b74ca6cf78abf6f7be744b7.tar.gz
cpython-71e315b9d90aca5b5b74ca6cf78abf6f7be744b7.tar.bz2
(py-shift-region-left): When checking for left edged code, watch for
blank lines.
Diffstat (limited to 'Misc')
-rw-r--r--Misc/python-mode.el3
1 files changed, 2 insertions, 1 deletions
diff --git a/Misc/python-mode.el b/Misc/python-mode.el
index 229ba4e..80cc0f5 100644
--- a/Misc/python-mode.el
+++ b/Misc/python-mode.el
@@ -963,7 +963,8 @@ You cannot outdent the region if any line is already at column zero."
(goto-char start)
(while (< (point) end)
(back-to-indentation)
- (if (zerop (current-column))
+ (if (and (zerop (current-column))
+ (not (looking-at "\\s *$")))
(error "Region is at left edge."))
(forward-line 1)))
(py-shift-region start end (- (prefix-numeric-value