Skip to content

Commit 4a4cc82

Browse files
More tests
1 parent 1633e9e commit 4a4cc82

File tree

3 files changed

+14
-6
lines changed

3 files changed

+14
-6
lines changed
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
{ aaa: 123, bbb: 456}
2+
---
3+
4+
[Range] =
5+
[Domain] = 0:1-0:20
6+
>-------------------<
7+
0| { aaa: 123, bbb: 456}

packages/common/src/scopeSupportFacets/python.ts

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -110,8 +110,9 @@ export const pythonScopeSupport: LanguageScopeSupportFacetMap = {
110110
"condition.ternary": supported,
111111
"condition.while": supported,
112112

113-
ifStatement: supported,
114113
"key.mapPair": supported,
114+
"key.mapPair.iteration": supported,
115+
115116
list: supported,
116117
map: supported,
117118

@@ -124,6 +125,7 @@ export const pythonScopeSupport: LanguageScopeSupportFacetMap = {
124125
"textFragment.string.multiLine": supported,
125126
"textFragment.string.singleLine": supported,
126127

128+
ifStatement: supported,
127129
statement: supported,
128130
"statement.class": supported,
129131
"statement.iteration.block": supported,
@@ -142,19 +144,18 @@ export const pythonScopeSupport: LanguageScopeSupportFacetMap = {
142144

143145
"namedFunction.iteration": unsupported,
144146
"functionName.iteration": unsupported,
147+
"class.iteration.block": unsupported,
148+
"className.iteration.block": unsupported,
145149

146150
// Not applicable
147151

148-
"class.iteration.block": notApplicable,
149-
"className.iteration.block": notApplicable,
150152
"comment.block": notApplicable,
151153
"condition.doWhile": notApplicable,
152154
"condition.for": notApplicable,
153155
"interior.cell": notApplicable,
154156
"interior.command": notApplicable,
155157
"interior.element": notApplicable,
156158
"key.attribute": notApplicable,
157-
"key.mapPair.iteration": notApplicable,
158159
"section.iteration.document": notApplicable,
159160
"section.iteration.parent": notApplicable,
160161
"textFragment.comment.block": notApplicable,

queries/python.scm

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -341,8 +341,8 @@
341341
;;!! {"a": 1, "b": 2, "c": 3}
342342
;;! **********************
343343
(dictionary
344-
"{" @value.iteration.start.endOf
345-
"}" @value.iteration.end.startOf
344+
"{" @collectionKey.iteration.start.endOf @value.iteration.start.endOf
345+
"}" @collectionKey.iteration.end.startOf @value.iteration.end.startOf
346346
)
347347

348348
;;!! def func(a=0, b=1):

0 commit comments

Comments
 (0)