mirror of
https://github.com/neovim/neovim.git
synced 2025-09-08 20:38:18 +00:00
Fix append() without line argument
We want to switch include_start/end when the index is positive or negative.
This commit is contained in:
@@ -467,7 +467,8 @@ void buffer_insert(Buffer buffer,
|
|||||||
ArrayOf(String) lines,
|
ArrayOf(String) lines,
|
||||||
Error *err)
|
Error *err)
|
||||||
{
|
{
|
||||||
buffer_set_line_slice(buffer, lnum, lnum, true, false, lines, err);
|
bool end_start = lnum < 0;
|
||||||
|
buffer_set_line_slice(buffer, lnum, lnum, !end_start, end_start, lines, err);
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Return a tuple (row,col) representing the position of the named mark
|
/// Return a tuple (row,col) representing the position of the named mark
|
||||||
|
Reference in New Issue
Block a user