mirror of
https://github.com/neovim/neovim.git
synced 2026-02-05 12:01:22 +10:00
**Problem:** `is_ancestor()` uses a slow, bottom-up parent lookup which has performance pitfalls detailed in #28512. **Solution:** Take `is_ancestor()` from $O(n^2)$ to $O(n)$ by incorporating the use of the `child_containing_descendant()` function
1.5 KiB
1.5 KiB