-
Notifications
You must be signed in to change notification settings - Fork 6
Fix handling of continuing unclosed multiline comments #6
Copy link
Copy link
Open
Labels
bugSomething isn't workingSomething isn't workingchallengeWill take some extra thought or workWill take some extra thought or workhelp wantedExtra attention is neededExtra attention is needed
Description
Quoting from the README:
Filling a paragraph in an unterminated multi-line comment (starting with
/*but with no matching*/), or inserting a newline to continue the comment causes Emacs to use/*as the fill prefix rather than the intended*. This can be fixed by adding the closing*/.
So if you have a buffer with this content, and the cursor at |:
/**
* This is a multi-line comment which hasn't finished yet|
Running M-x comment-indent-and-newline currently (in Emacs 28.1) produces:
/**
* This is a multi-line comment which hasn't finished yet
/**|
Instead of
/**
* This is a multi-line comment which hasn't finished yet
* |
This task is about fixing this behaviour without requiring that someone closes the comment proactively.
NOTE: This may not be possible, this bug is apparent in other major modes (tested with rust-mode, cc-mode).
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workingchallengeWill take some extra thought or workWill take some extra thought or workhelp wantedExtra attention is neededExtra attention is needed