If option kill-whole-line is non-nil, then this command kills the whole line including its terminating newline, when used at the beginning of a line with no argument.
The "at the beginning of a line" is the important bit here. kill-line ensures this by checking (and kill-whole-line (bolp)), while puni-kill-line only checks kill-whole-line itself. This seems like a mistake (though I can't be sure, hence this is an issue rather than a pull request), and results—in my opinion—in surprising results; let | be the cursor:
This |is a line.
This is another line.
;; kill-line
This
This is another line.
;; puni-kill-line
This This is another line.
I'm happy to open a PR if this is unintentional, or you can make the change yourself; whatever you prefer.
Quoting from the documentation of
kill-line
:The "at the beginning of a line" is the important bit here.
kill-line
ensures this by checking(and kill-whole-line (bolp))
, whilepuni-kill-line
only checkskill-whole-line
itself. This seems like a mistake (though I can't be sure, hence this is an issue rather than a pull request), and results—in my opinion—in surprising results; let|
be the cursor:I'm happy to open a PR if this is unintentional, or you can make the change yourself; whatever you prefer.