Skip to content

Commit a5788c2

Browse files
authored
Clarify measurement unit in CompletionsRequest.column (#320)
Fixes #285
1 parent 25fc7f2 commit a5788c2

File tree

2 files changed

+25
-22
lines changed

2 files changed

+25
-22
lines changed

changelog.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,9 @@ sectionid: changelog
66

77
#### All notable changes to the specification will be documented in this file.
88

9+
* 1.58.X:
10+
* Specify the measurement unit of various `column` and "character positions" properties to be "UTF-16 code units".
11+
912
* 1.57.X:
1013
* Add the `argsCanBeInterpretedByShell` property to the `RunInTerminalRequest`
1114

debugAdapterProtocol.json

Lines changed: 22 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -386,7 +386,7 @@
386386
},
387387
"column": {
388388
"type": "integer",
389-
"description": "The source location's column where the output was produced."
389+
"description": "The position in `line` where the output was produced. It is measured in UTF-16 code units and the client capability `columnsStartAt1` determines whether it is 0- or 1-based."
390390
},
391391
"data": {
392392
"type": [ "array", "boolean", "integer", "null", "number" , "object", "string" ],
@@ -1145,15 +1145,15 @@
11451145
},
11461146
"column": {
11471147
"type": "integer",
1148-
"description": "Start column of range to search possible breakpoint locations in. If no start column is given, the first column in the start line is assumed."
1148+
"description": "Start position within `line` to search possible breakpoint locations in. It is measured in UTF-16 code units and the client capability `columnsStartAt1` determines whether it is 0- or 1-based. If no column is given, the first position in the start line is assumed."
11491149
},
11501150
"endLine": {
11511151
"type": "integer",
11521152
"description": "End line of range to search possible breakpoint locations in. If no end line is given, then the end line is assumed to be the start line."
11531153
},
11541154
"endColumn": {
11551155
"type": "integer",
1156-
"description": "End column of range to search possible breakpoint locations in. If no end column is given, then it is assumed to be in the last column of the end line."
1156+
"description": "End position within `endLine` to search possible breakpoint locations in. It is measured in UTF-16 code units and the client capability `columnsStartAt1` determines whether it is 0- or 1-based. If no end column is given, the last position in the end line is assumed."
11571157
}
11581158
},
11591159
"required": [ "source", "line" ]
@@ -2645,7 +2645,7 @@
26452645
},
26462646
"column": {
26472647
"type": "integer",
2648-
"description": "A column location for which the goto targets are determined."
2648+
"description": "The position within `line` for which the goto targets are determined. It is measured in UTF-16 code units and the client capability `columnsStartAt1` determines whether it is 0- or 1-based."
26492649
}
26502650
},
26512651
"required": [ "source", "line" ]
@@ -2699,11 +2699,11 @@
26992699
},
27002700
"text": {
27012701
"type": "string",
2702-
"description": "One or more source lines. Typically this is the text a user has typed into the debug console before he asked for completion."
2702+
"description": "One or more source lines. Typically this is the text users have typed into the debug console before they asked for completion."
27032703
},
27042704
"column": {
27052705
"type": "integer",
2706-
"description": "The character position for which to determine the completion proposals."
2706+
"description": "The position within `text` for which to determine the completion proposals. It is measured in UTF-16 code units and the client capability `columnsStartAt1` determines whether it is 0- or 1-based."
27072707
},
27082708
"line": {
27092709
"type": "integer",
@@ -3405,15 +3405,15 @@
34053405
},
34063406
"column": {
34073407
"type": "integer",
3408-
"description": "The column within the line. If source attribute is missing or doesn't exist, `column` is 0 and should be ignored by the client."
3408+
"description": "Start position of the range covered by the stack frame. It is measured in UTF-16 code units and the client capability `columnsStartAt1` determines whether it is 0- or 1-based. If attribute `source` is missing or doesn't exist, `column` is 0 and should be ignored by the client."
34093409
},
34103410
"endLine": {
34113411
"type": "integer",
34123412
"description": "The end line of the range covered by the stack frame."
34133413
},
34143414
"endColumn": {
34153415
"type": "integer",
3416-
"description": "The end column of the range covered by the stack frame."
3416+
"description": "End position of the range covered by the stack frame. It is measured in UTF-16 code units and the client capability `columnsStartAt1` determines whether it is 0- or 1-based."
34173417
},
34183418
"canRestart": {
34193419
"type": "boolean",
@@ -3480,15 +3480,15 @@
34803480
},
34813481
"column": {
34823482
"type": "integer",
3483-
"description": "The start column of the range covered by this scope."
3483+
"description": "Start position of the range covered by the scope. It is measured in UTF-16 code units and the client capability `columnsStartAt1` determines whether it is 0- or 1-based."
34843484
},
34853485
"endLine": {
34863486
"type": "integer",
34873487
"description": "The end line of the range covered by this scope."
34883488
},
34893489
"endColumn": {
34903490
"type": "integer",
3491-
"description": "The end column of the range covered by this scope."
3491+
"description": "End position of the range covered by the scope. It is measured in UTF-16 code units and the client capability `columnsStartAt1` determines whether it is 0- or 1-based."
34923492
}
34933493
},
34943494
"required": [ "name", "variablesReference", "expensive" ]
@@ -3600,15 +3600,15 @@
36003600
},
36013601
"column": {
36023602
"type": "integer",
3603-
"description": "The start column of breakpoint location."
3603+
"description": "The start position of a breakpoint location. Position is measured in UTF-16 code units and the client capability `columnsStartAt1` determines whether it is 0- or 1-based."
36043604
},
36053605
"endLine": {
36063606
"type": "integer",
36073607
"description": "The end line of breakpoint location if the location covers a range."
36083608
},
36093609
"endColumn": {
36103610
"type": "integer",
3611-
"description": "The end column of breakpoint location if the location covers a range."
3611+
"description": "The end position of a breakpoint location (if the location covers a range). Position is measured in UTF-16 code units and the client capability `columnsStartAt1` determines whether it is 0- or 1-based."
36123612
}
36133613
},
36143614
"required": [ "line" ]
@@ -3624,7 +3624,7 @@
36243624
},
36253625
"column": {
36263626
"type": "integer",
3627-
"description": "The source column of the breakpoint."
3627+
"description": "Start position within source line of the breakpoint or logpoint. It is measured in UTF-16 code units and the client capability `columnsStartAt1` determines whether it is 0- or 1-based."
36283628
},
36293629
"condition": {
36303630
"type": "string",
@@ -3742,15 +3742,15 @@
37423742
},
37433743
"column": {
37443744
"type": "integer",
3745-
"description": "The start column of the actual range covered by the breakpoint."
3745+
"description": "Start position of the source range covered by the breakpoint. It is measured in UTF-16 code units and the client capability `columnsStartAt1` determines whether it is 0- or 1-based."
37463746
},
37473747
"endLine": {
37483748
"type": "integer",
37493749
"description": "The end line of the actual range covered by the breakpoint."
37503750
},
37513751
"endColumn": {
37523752
"type": "integer",
3753-
"description": "The end column of the actual range covered by the breakpoint.\nIf no end line is given, then the end column is assumed to be in the start line."
3753+
"description": "End position of the source range covered by the breakpoint. It is measured in UTF-16 code units and the client capability `columnsStartAt1` determines whether it is 0- or 1-based.\nIf no end line is given, then the end column is assumed to be in the start line."
37543754
},
37553755
"instructionReference": {
37563756
"type": "string",
@@ -3777,7 +3777,7 @@
37773777

37783778
"StepInTarget": {
37793779
"type": "object",
3780-
"description": "A `StepInTarget` can be used in the `stepIn` request and determines into which single target the stepIn request should step.",
3780+
"description": "A `StepInTarget` can be used in the `stepIn` request and determines into which single target the `stepIn` request should step.",
37813781
"properties": {
37823782
"id": {
37833783
"type": "integer",
@@ -3793,15 +3793,15 @@
37933793
},
37943794
"column": {
37953795
"type": "integer",
3796-
"description": "The column of the step-in target."
3796+
"description": "Start position of the range covered by the step in target. It is measured in UTF-16 code units and the client capability `columnsStartAt1` determines whether it is 0- or 1-based."
37973797
},
37983798
"endLine": {
37993799
"type": "integer",
38003800
"description": "The end line of the range covered by the step-in target."
38013801
},
38023802
"endColumn": {
38033803
"type": "integer",
3804-
"description": "The end column of the range covered by the step-in target."
3804+
"description": "End position of the range covered by the step in target. It is measured in UTF-16 code units and the client capability `columnsStartAt1` determines whether it is 0- or 1-based."
38053805
}
38063806
},
38073807
"required": [ "id", "label" ]
@@ -3869,19 +3869,19 @@
38693869
},
38703870
"start": {
38713871
"type": "integer",
3872-
"description": "This value determines the location (in the `completions` request's `text` attribute) where the completion text is added.\nIf missing the text is added at the location specified by the `completions` request's `column` attribute."
3872+
"description": "Start position (within the `text` attribute of the `completions` request) where the completion text is added. The position is measured in UTF-16 code units and the client capability `columnsStartAt1` determines whether it is 0- or 1-based. If the start position is omitted the text is added at the location specified by the `column` attribute of the `completions` request."
38733873
},
38743874
"length": {
38753875
"type": "integer",
3876-
"description": "This value determines how many characters are overwritten by the completion text.\nIf missing the value 0 is assumed which results in the completion text being inserted."
3876+
"description": "Length determines how many characters are overwritten by the completion text and it is measured in UTF-16 code units. If missing the value 0 is assumed which results in the completion text being inserted."
38773877
},
38783878
"selectionStart": {
38793879
"type": "integer",
3880-
"description": "Determines the start of the new selection after the text has been inserted (or replaced).\nThe start position must be in the range 0 and length of the completion text.\nIf omitted the selection starts at the end of the completion text."
3880+
"description": "Determines the start of the new selection after the text has been inserted (or replaced). `selectionStart` is measured in UTF-16 code units and must be in the range 0 and length of the completion text. If omitted the selection starts at the end of the completion text."
38813881
},
38823882
"selectionLength": {
38833883
"type": "integer",
3884-
"description": "Determines the length of the new selection after the text has been inserted (or replaced).\nThe selection can not extend beyond the bounds of the completion text.\nIf omitted the length is assumed to be 0."
3884+
"description": "Determines the length of the new selection after the text has been inserted (or replaced) and it is measured in UTF-16 code units. The selection can not extend beyond the bounds of the completion text. If omitted the length is assumed to be 0."
38853885
}
38863886
},
38873887
"required": [ "label" ]

0 commit comments

Comments
 (0)