diff options
| author | Justin M. Keyes <justinkz@gmail.com> | 2026-03-29 11:56:37 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-03-29 11:56:37 -0400 |
| commit | d9d3822a7b1bbfb3604819cece4cd664f4bc8dfd (patch) | |
| tree | 2bbaf02d7e735a5780ac78956c1fc71116a9ed08 /runtime/lua/vim/range.lua | |
| parent | 7d97de27cf90205079497f72f655ece2f706a665 (diff) | |
docs: misc #38532
Close #38431
Close #38521
Close #38530
Co-authored-by: tayheau <thopsore@pasteur.fr>
Co-authored-by: zeertzjq <zeertzjq@outlook.com>
Co-authored-by: Olivia Kinnear <git@superatomic.dev>
Diffstat (limited to 'runtime/lua/vim/range.lua')
| -rw-r--r-- | runtime/lua/vim/range.lua | 18 |
1 files changed, 7 insertions, 11 deletions
diff --git a/runtime/lua/vim/range.lua b/runtime/lua/vim/range.lua index 78e201e3fd..5613d3d789 100644 --- a/runtime/lua/vim/range.lua +++ b/runtime/lua/vim/range.lua @@ -1,8 +1,7 @@ ---@brief --- ---- EXPERIMENTAL: This API may change in the future. Its semantics are not yet finalized. ---- Subscribe to https://github.com/neovim/neovim/issues/25509 ---- to stay updated or contribute to its development. +--- EXPERIMENTAL: This API is unstable, do not use it. Its semantics are not yet finalized. +--- Subscribe to this issue to stay updated: https://github.com/neovim/neovim/issues/25509 --- --- Provides operations to compare, calculate, and convert ranges represented by |vim.Range| --- objects. @@ -10,11 +9,12 @@ local validate = vim.validate local api = vim.api ---- Represents a well-defined range. +--- Represents a range. Call `vim.range()` to create a new range. --- ---- A |vim.Range| object contains a {start} and a {end_} position(see |vim.Pos|). ---- Note that the {end_} position is exclusive. ---- To create a new |vim.Range| object, call `vim.range()`. +--- A range contains a start and end position (see |vim.Pos|). The end position is exclusive. +--- Positions must have the same optional fields. +--- +--- May include optional fields that enable additional capabilities, such as format conversions. --- --- Example: --- ```lua @@ -36,10 +36,6 @@ local api = vim.api --- end --- ``` --- ---- It may include optional fields that enable additional capabilities, ---- such as format conversions. Note that the {start} and {end_} positions ---- need to have the same optional fields. ---- ---@class vim.Range ---@field start_row integer 0-based byte index. ---@field start_col integer 0-based byte index. |
