M-x uncomment-region not sufficient.
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
haskell-mode (Debian) |
Fix Released
|
Unknown
|
|||
haskell-mode (Ubuntu) |
Confirmed
|
Undecided
|
Unassigned |
Bug Description
M-x uncomment-region is not inverse of M-x comment-region
Reproduce
1) Write some haskell code in emacs.
2) Mark a region of code
3) use M-x comment-region
4) Code now has "-- " (3 characters) prepended to each line
5) mark same region
6) use M-x uncomment-region
7) only "--" (2 characters) was removed at beginning of each line and code now begins with a space
8) Use tab cutton to autoindent the line. This says current indentation (initial space) is "sole indentation"
Note: The indentation arrived at after (7) is apparently wrong because ghci gets a parse error on that line, that is avoided by removing the initial space.
Suggestion: If line begins with "-- ", then uncomment-region should remove all three characters, otherwise only "--".
For the indentation in step (8) I know too little to have an opinion on what behaviour is desirable.
Thanks
Johan
Changed in haskell-mode: | |
status: | Unconfirmed → Confirmed |
Changed in haskell-mode: | |
status: | Unknown → Confirmed |
Changed in haskell-mode (Debian): | |
status: | Confirmed → Fix Released |
tags 229468 +upstream