This PR improves the message of `unusedVariables` linter, by replacing potentially confusing "unused variable `x`" message with "Variable name `x` is not explicitly referenced. The binding can be removed (if unused) or named `_` (if used implicitly)." Related issue: https://github.com/leanprover/lean4/issues/13269
107 lines
1.6 KiB
Text
107 lines
1.6 KiB
Text
{"version": 1,
|
|
"uri": "file:///semanticTokens.lean",
|
|
"isIncremental": false,
|
|
"diagnostics":
|
|
[{"source": "Lean 4",
|
|
"severity": 3,
|
|
"range":
|
|
{"start": {"line": 2, "character": 0}, "end": {"line": 3, "character": 0}},
|
|
"message": "Goals accomplished!",
|
|
"leanTags": [2],
|
|
"isSilent": true,
|
|
"fullRange":
|
|
{"start": {"line": 2, "character": 0}, "end": {"line": 4, "character": 12}}},
|
|
{"tags": [1],
|
|
"source": "Lean 4",
|
|
"severity": 2,
|
|
"range":
|
|
{"start": {"line": 3, "character": 6}, "end": {"line": 3, "character": 7}},
|
|
"message":
|
|
"Variable name `y` is not explicitly referenced.\n\nThe binding can be removed (if unused) or named `_` (if used implicitly).\n\nNote: This linter can be disabled with `set_option linter.unusedVariables false`",
|
|
"fullRange":
|
|
{"start": {"line": 3, "character": 6}, "end": {"line": 3, "character": 7}}},
|
|
{"source": "Lean 4",
|
|
"severity": 3,
|
|
"range":
|
|
{"start": {"line": 6, "character": 0}, "end": {"line": 6, "character": 5}},
|
|
"message": "1",
|
|
"fullRange":
|
|
{"start": {"line": 6, "character": 0}, "end": {"line": 6, "character": 5}}}]}
|
|
{"textDocument": {"uri": "file:///semanticTokens.lean"},
|
|
"position": {"line": 6, "character": 2}}
|
|
{"data":
|
|
[0,
|
|
0,
|
|
3,
|
|
0,
|
|
0,
|
|
0,
|
|
10,
|
|
1,
|
|
1,
|
|
0,
|
|
0,
|
|
12,
|
|
1,
|
|
1,
|
|
0,
|
|
0,
|
|
2,
|
|
4,
|
|
2,
|
|
0,
|
|
1,
|
|
0,
|
|
3,
|
|
0,
|
|
0,
|
|
0,
|
|
10,
|
|
1,
|
|
1,
|
|
0,
|
|
0,
|
|
12,
|
|
1,
|
|
1,
|
|
0,
|
|
0,
|
|
5,
|
|
4,
|
|
2,
|
|
0,
|
|
1,
|
|
0,
|
|
7,
|
|
0,
|
|
0,
|
|
0,
|
|
14,
|
|
1,
|
|
1,
|
|
0,
|
|
1,
|
|
2,
|
|
3,
|
|
0,
|
|
0,
|
|
0,
|
|
4,
|
|
1,
|
|
1,
|
|
0,
|
|
0,
|
|
5,
|
|
1,
|
|
1,
|
|
0,
|
|
0,
|
|
2,
|
|
4,
|
|
2,
|
|
0,
|
|
3,
|
|
0,
|
|
5,
|
|
0,
|
|
0]}
|