reindenting a region does move whole region to correct level
Bug #1093026 reported by
Benjamin Peterson
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
python-mode.el |
Fix Released
|
Wishlist
|
Andreas Roehler |
Bug Description
If I have code like:
v = 4
if cond:
v += 9
invoke()
And I remove the "if":
v = 4
v += 9
invoke()
selecting the whole segment of code and hitting tab doesn't fix the indentation of the 2 last lines.
Changed in python-mode: | |
milestone: | none → 6.1.1 |
assignee: | nobody → Andreas Roehler (a-roehler) |
importance: | Undecided → Medium |
Changed in python-mode: | |
importance: | Medium → Wishlist |
Changed in python-mode: | |
status: | Fix Committed → New |
Changed in python-mode: | |
status: | New → Fix Committed |
Changed in python-mode: | |
status: | Fix Committed → Fix Released |
To post a comment you must log in.
Could implement a new function py-indent- line-or- region, which would work on an active region.
TAB then would call that instead of just py-indent-line.
OTOH indent-region already exists and is bound to C-M-\
It's not hard to write a py-indent- line-or- region, however note sure if we need this.
WDYT?
Would be nice if Barry or others comment too.
Andreas