Repository: neovim
Issue: Assertion `seen` failure on marktree
Labels: needs:repro,has:backtrace,bug-crash,marks

### Problem

```cpp
#0  __pthread_kill_implementation (threadid=<optimized out>, signo=signo@entry=6, no_tid=no_tid@entry=0) at ./nptl/pthread_kill.c:44
#1  0x00007ff667f5315f in __pthread_kill_internal (signo=6, threadid=<optimized out>) at ./nptl/pthread_kill.c:78
#2  0x00007ff667f05472 in __GI_raise (sig=sig@entry=6) at ../sysdeps/posix/raise.c:26
#3  0x00007ff667eef4b2 in __GI_abort () at ./stdlib/abort.c:79
#4  0x00007ff667eef3d5 in __assert_fail_base (fmt=0x7ff668063dc8 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", assertion=assertion@entry=0x55da9372964d "seen",
    file=file@entry=0x55da9374a730 ".../src/nvim/marktree.c", line=line@entry=375, function=function@entry=0x55da936f8a40 <__PRETTY_FUNCTION__.19> "unintersect_node") at ./assert/assert.c:92
#5  0x00007ff667efe3a2 in __assert_fail (assertion=assertion@entry=0x55da9372964d "seen", file=file@entry=0x55da9374a730 ".../src/nvim/marktree.c", line=line@entry=375,
    function=function@entry=0x55da936f8a40 <__PRETTY_FUNCTION__.19> "unintersect_node") at ./assert/assert.c:101
#6  0x000055da934a12b6 in unintersect_node (b=b@entry=0x55da93f147e0, x=0x55da958a7590, id=id@entry=8589935750, strict=strict@entry=true) at .../src/nvim/marktree.c:375
#7  0x000055da934a32cf in marktree_intersect_pair (b=b@entry=0x55da93f147e0, id=id@entry=8589935750, itr=itr@entry=0x7ffc8a862090, end_itr=end_itr@entry=0x7ffc8a861fb0, delete=delete@entry=true)
    at .../src/nvim/marktree.c:427
#8  0x000055da934a9b58 in marktree_splice (b=0x55da93f147e0, start_line=<optimized out>, start_col=<optimized out>, old_extent_line=<optimized out>, old_extent_col=<optimized out>, new_extent_line=<optimized out>, new_extent_col=0)
    at .../src/nvim/marktree.c:2085
#9  0x000055da9345085e in extmark_splice_impl (buf=buf@entry=0x55da93f11850, start_row=start_row@entry=91, start_col=start_col@entry=0, start_byte=2408, old_row=old_row@entry=1, old_col=old_col@entry=0, old_byte=49, new_row=1, new_col=0,
    new_byte=52, undo=kExtmarkUndo) at .../src/nvim/extmark.c:530
#10 0x000055da93450c0c in extmark_splice (buf=0x55da93f11850, start_row=91, start_col=0, old_row=1, old_col=0, old_byte=49, new_row=1, new_col=0, new_byte=52, undo=kExtmarkUndo) at .../src/nvim/extmark.c:498
#11 0x000055da933726e0 in nvim_buf_set_lines (channel_id=<optimized out>, buffer=<optimized out>, start=92, end=93, strict_indexing=<optimized out>, replacement=..., err=0x7ffc8a8625b0)
    at .../src/nvim/api/buffer.c:461
#12 0x000055da9335c00a in nlua_api_nvim_buf_set_lines (lstate=0x7ff667ea7380) at .../build/src/nvim/auto/lua_api_c_bindings.generated.c:574
#13 0x000055da93662256 in lj_BC_FUNCC ()
#14 0x000055da9364e4d5 in lua_pcall (L=L@entry=0x7ff667ea7380, nargs=nargs@entry=0, nresults=nresults@entry=1, errfunc=errfunc@entry=-2) at lj_api.c:1121
#15 0x000055da93481769 in nlua_pcall (lstate=lstate@entry=0x7ff667ea7380, nargs=nargs@entry=0, nresults=nresults@entry=1) at .../src/nvim/lua/executor.c:172
#16 0x000055da93486bff in nlua_call_ref (ref=<optimized out>, name=<optimized out>, args=..., retval=false, err=0x7ffc8a862790) at .../src/nvim/lua/executor.c:1610
#17 0x000055da934659c4 in map_execute_lua (may_repeat=true) at .../src/nvim/getchar.c:3030
#18 0x000055da934d9d9b in nv_colon (cap=0x7ffc8a8628d0) at .../src/nvim/normal.c:3220
#19 0x000055da934d440b in normal_execute (state=0x7ffc8a862860, key=<optimized out>) at .../src/nvim/normal.c:1227
#20 0x000055da9357533a in state_enter (s=0x7ffc8a862860) at .../src/nvim/state.c:101
#21 0x000055da934d1594 in normal_enter (cmdwin=<optimized out>, noexmode=<optimized out>) at .../src/nvim/normal.c:516
--Type <RET> for more, q to quit, c to continue without paging--
#22 0x000055da934963d9 in main (argc=3, argv=<optimized out>) at .../src/nvim/main.c:651
```

@bfredl @luukvbaal could you look?

### Steps to reproduce

I have no idea how to reproduce it. This happened while deleting (or maybe commenting out) line in lua file (with luals). 
- `statuscol.nvim` plugin on `0.10` branch


### Expected behavior

No crash

### Neovim version (nvim -v)

v0.10.0-dev-2196+g1e0996b57

### Vim (not Nvim) behaves the same?

-

### Operating system/version

Debian Sid

### Terminal name/version

alacritty 0.13.1

### $TERM environment variable

alacritty

### Installation

from repo