Skip to content

Commit 9df2010

Browse files
observerwCopilot
andauthored
Update src/lsp_client/capability/request/inlay_hint.py
Co-authored-by: Copilot <[email protected]>
1 parent 3cc1099 commit 9df2010

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

src/lsp_client/capability/request/inlay_hint.py

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,21 @@ async def request_inlay_hint(
7979
range: lsp_type.Range,
8080
resolve: bool = False,
8181
) -> Sequence[lsp_type.InlayHint] | None:
82+
"""
83+
Request inlay hints for a given file and range.
84+
85+
This sends a `textDocument/inlayHint` request for the specified document range.
86+
If ``resolve`` is True, each returned inlay hint is further resolved using
87+
:meth:`request_inlay_hint_resolve` to populate optional properties such as
88+
tooltip, locations, and text edits.
89+
90+
:param file_path: Path to the file for which inlay hints are requested.
91+
:param range: LSP range within the document to compute inlay hints for.
92+
:param resolve: Whether to resolve each returned inlay hint for additional
93+
details supported by the server.
94+
:return: A sequence of :class:`lsp_type.InlayHint` instances if the server
95+
returns hints, or ``None`` if no hints are provided.
96+
"""
8297
hints = await self.file_request(
8398
lsp_type.InlayHintRequest(
8499
id=jsonrpc_uuid(),

0 commit comments

Comments
 (0)