Skip to content

Commit 782bfe6

Browse files
committed
fix(langserver): some correction at line and file endings for signature help
1 parent 3ebe9f1 commit 782bfe6

File tree

1 file changed

+4
-2
lines changed
  • packages/language_server/src/robotcode/language_server/robotframework/parts

1 file changed

+4
-2
lines changed

packages/language_server/src/robotcode/language_server/robotframework/parts/signature_help.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,9 @@ def _find_method(self, cls: Type[Any]) -> Optional[_SignatureHelpMethod]:
7373
async def collect(
7474
self, sender: Any, document: TextDocument, position: Position, context: Optional[SignatureHelpContext] = None
7575
) -> Optional[SignatureHelp]:
76-
result_node = await get_node_at_position(await self.parent.documents_cache.get_model(document, False), position)
76+
result_node = await get_node_at_position(
77+
await self.parent.documents_cache.get_model(document, False), position, include_end=True
78+
)
7779
if result_node is None:
7880
return None
7981

@@ -95,7 +97,7 @@ async def _signature_help_KeywordCall_or_Fixture( # noqa: N802
9597

9698
kw_node = cast(Statement, node)
9799

98-
tokens_at_position = get_tokens_at_position(kw_node, position)
100+
tokens_at_position = get_tokens_at_position(kw_node, position, include_end=True)
99101

100102
if not tokens_at_position:
101103
return None

0 commit comments

Comments
 (0)