Skip to content

Commit 02b286d

Browse files
authored
fix(tolk/settings): fix inlay hints disabling (#31)
1 parent 485edeb commit 02b286d

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

server/src/languages/tolk/completion/ReferenceCompletionProcessor.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -310,7 +310,7 @@ export class ReferenceCompletionProcessor implements ScopeProcessor {
310310
}
311311

312312
private needSemicolon(node: SyntaxNode): boolean {
313-
if (this.ctx.beforeSemicolon) {
313+
if (this.ctx.beforeSemicolon || this.ctx.beforeParen) {
314314
return false
315315
}
316316

server/src/languages/tolk/inlays/index.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,12 +17,13 @@ import {Expression} from "@server/languages/tolk/psi/TolkNode"
1717
export function collectTolkInlays(
1818
file: TolkFile,
1919
hints: {
20+
disable: boolean
2021
parameters: boolean
2122
types: boolean
2223
showMethodId: boolean
2324
},
2425
): lsp.InlayHint[] | null {
25-
if (!hints.parameters) return []
26+
if (hints.disable) return []
2627

2728
const result: lsp.InlayHint[] = []
2829

0 commit comments

Comments
 (0)