@malloydata/malloy 0.0.49-dev230626201111 → 0.0.49

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -52,8 +52,6 @@ class DocumentSymbolWalker {
52
52
  children: [],
53
53
  lensRange: this.blockRange,
54
54
  });
55
- }
56
- exitTopLevelQueryDefs(_pcx) {
57
55
  this.blockRange = undefined;
58
56
  }
59
57
  enterRunStatementDef(pcx) {
@@ -91,9 +89,6 @@ class DocumentSymbolWalker {
91
89
  this.blockRange = blockRange;
92
90
  }
93
91
  }
94
- exitDefineSourceStatement(_pcx) {
95
- this.blockRange = undefined;
96
- }
97
92
  enterSourceDefinition(pcx) {
98
93
  const range = this.translator.rangeFromContext(pcx);
99
94
  this.scopes.push({
@@ -103,6 +98,7 @@ class DocumentSymbolWalker {
103
98
  children: [],
104
99
  lensRange: this.blockRange,
105
100
  });
101
+ this.blockRange = undefined;
106
102
  }
107
103
  exitSourceDefinition(_pcx) {
108
104
  const scope = this.popScope();
@@ -130,13 +126,11 @@ class DocumentSymbolWalker {
130
126
  parent.children.push(symbol);
131
127
  }
132
128
  this.scopes.push(symbol);
129
+ this.blockRange = undefined;
133
130
  }
134
131
  exitExploreQueryDef(_pcx) {
135
132
  this.popScope();
136
133
  }
137
- exitDefExploreQuery(_pcx) {
138
- this.blockRange = undefined;
139
- }
140
134
  handleNestEntry(pcx) {
141
135
  const symbol = {
142
136
  range: this.translator.rangeFromContext(pcx),
@@ -173,4 +173,11 @@ test('run lenses go before block annotations', () => {
173
173
  # tag3
174
174
  flights -> by_carrier`}`, [0]);
175
175
  });
176
+ test('(regression) query does not use source block range', () => {
177
+ testLens((0, test_translator_1.markSource) `source: a is table('b') {
178
+ query:
179
+ ${'x is {project: *}'}
180
+ y is {project: *}
181
+ }`, [0, 0]);
182
+ });
176
183
  //# sourceMappingURL=document-symbol-walker.spec.js.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@malloydata/malloy",
3
- "version": "0.0.49-dev230626201111",
3
+ "version": "0.0.49",
4
4
  "license": "MIT",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",