docs/lsp-spec.md
rustowl, is an LSP server which provides RustOwl information.
To display various types of decorations, RustOwl supports some custom methods from the client.
Here, we describe the specifications of those custom methods.
Here, we describe the types we will use in this document.
OprType"lifetime" | "definitely_live" | "maybe_initialized"
| "imm_borrow" | "mut_borrow" | "move" | "call"
| "outlive" | "shared_mut"
definitely_live and maybe_initialized are derived from a CFG-based liveness analysis:
definitely_live covers ranges where the local is provably initialized on every path that reaches the location (state is exactly {Initialized}).maybe_initialized covers ranges where the local is initialized on at least one path but may also have been moved, dropped, or be uninitialized on others (state contains Initialized together with other variants). Useful for spotting conditional drops and other resource-management ambiguity.lifetime is retained for backward compatibility; clients should treat definitely_live as the replacement for the previous "actual lifetime" decoration.
Decorationoverlapped field indicates that the decoration is overlapped and should be hidden.
We describe the custom methods used in RustOwl.
rustowl/cursor