()
| 894 | } |
| 895 | |
| 896 | deleteToLineEnd(): { cursor: Cursor; killed: string } { |
| 897 | // If cursor is on a newline character, delete just that character |
| 898 | if (this.text[this.offset] === '\n') { |
| 899 | return { cursor: this.modifyText(this.right()), killed: '\n' } |
| 900 | } |
| 901 | |
| 902 | const endCursor = this.endOfLine() |
| 903 | const killed = this.text.slice(this.offset, endCursor.offset) |
| 904 | return { cursor: this.modifyText(endCursor), killed } |
| 905 | } |
| 906 | |
| 907 | deleteToLogicalLineEnd(): Cursor { |
| 908 | // If cursor is on a newline character, delete just that character |
no test coverage detected