@malloydata/malloy 0.0.86-dev230921221205 → 0.0.86-dev230922233440
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.
- package/dist/lang/ast/field-space/query-spaces.js +3 -0
- package/dist/lang/ast/query-items/field-references.d.ts +1 -0
- package/dist/lang/ast/query-items/field-references.js +1 -0
- package/dist/lang/lib/Malloy/MalloyParser.d.ts +29 -12
- package/dist/lang/lib/Malloy/MalloyParser.js +1457 -1332
- package/dist/lang/lib/Malloy/MalloyParserListener.d.ts +11 -0
- package/dist/lang/lib/Malloy/MalloyParserVisitor.d.ts +7 -0
- package/dist/lang/malloy-to-ast.js +9 -5
- package/dist/lang/test/query.spec.js +14 -16
- package/package.json +1 -1
|
@@ -142,6 +142,9 @@ class QuerySpace extends refined_space_1.RefinedSpace {
|
|
|
142
142
|
}
|
|
143
143
|
const dialect = this.dialectObj();
|
|
144
144
|
for (const [name, entry] of current.entries()) {
|
|
145
|
+
if (wild.except.has(name)) {
|
|
146
|
+
continue;
|
|
147
|
+
}
|
|
145
148
|
if (this.entry(name)) {
|
|
146
149
|
const conflict = (_a = this.expandedWild[name]) === null || _a === void 0 ? void 0 : _a.join('.');
|
|
147
150
|
wild.log(`Cannot expand '${name}' in '${wild.refString}' because a field with that name already exists${conflict ? ` (conflicts with ${conflict})` : ''}`);
|
|
@@ -66,6 +66,7 @@ export declare class WildcardFieldReference extends MalloyElement implements Not
|
|
|
66
66
|
note?: Annotation;
|
|
67
67
|
readonly isNoteableObj = true;
|
|
68
68
|
extendNote: typeof extendNoteMethod;
|
|
69
|
+
except: Set<string>;
|
|
69
70
|
constructor(joinPath: FieldReference | undefined);
|
|
70
71
|
getFieldDef(): FieldDef;
|
|
71
72
|
get refString(): string;
|
|
@@ -183,6 +183,7 @@ class WildcardFieldReference extends malloy_element_1.MalloyElement {
|
|
|
183
183
|
this.elementType = 'wildcardFieldReference';
|
|
184
184
|
this.isNoteableObj = true;
|
|
185
185
|
this.extendNote = noteable_1.extendNoteMethod;
|
|
186
|
+
this.except = new Set();
|
|
186
187
|
this.has({ joinPath: joinPath });
|
|
187
188
|
}
|
|
188
189
|
getFieldDef() {
|
|
@@ -278,16 +278,17 @@ export declare class MalloyParser extends Parser {
|
|
|
278
278
|
static readonly RULE_fieldNameList = 115;
|
|
279
279
|
static readonly RULE_fieldCollection = 116;
|
|
280
280
|
static readonly RULE_collectionWildCard = 117;
|
|
281
|
-
static readonly
|
|
282
|
-
static readonly
|
|
283
|
-
static readonly
|
|
284
|
-
static readonly
|
|
285
|
-
static readonly
|
|
286
|
-
static readonly
|
|
287
|
-
static readonly
|
|
288
|
-
static readonly
|
|
289
|
-
static readonly
|
|
290
|
-
static readonly
|
|
281
|
+
static readonly RULE_starQualified = 118;
|
|
282
|
+
static readonly RULE_taggedRef = 119;
|
|
283
|
+
static readonly RULE_refExpr = 120;
|
|
284
|
+
static readonly RULE_collectionMember = 121;
|
|
285
|
+
static readonly RULE_fieldPath = 122;
|
|
286
|
+
static readonly RULE_joinName = 123;
|
|
287
|
+
static readonly RULE_fieldName = 124;
|
|
288
|
+
static readonly RULE_justExpr = 125;
|
|
289
|
+
static readonly RULE_sqlExploreNameRef = 126;
|
|
290
|
+
static readonly RULE_nameSQLBlock = 127;
|
|
291
|
+
static readonly RULE_connectionName = 128;
|
|
291
292
|
static readonly ruleNames: string[];
|
|
292
293
|
private static readonly _LITERAL_NAMES;
|
|
293
294
|
private static readonly _SYMBOLIC_NAMES;
|
|
@@ -417,6 +418,7 @@ export declare class MalloyParser extends Parser {
|
|
|
417
418
|
fieldNameList(): FieldNameListContext;
|
|
418
419
|
fieldCollection(): FieldCollectionContext;
|
|
419
420
|
collectionWildCard(): CollectionWildCardContext;
|
|
421
|
+
starQualified(): StarQualifiedContext;
|
|
420
422
|
taggedRef(): TaggedRefContext;
|
|
421
423
|
refExpr(): RefExprContext;
|
|
422
424
|
collectionMember(): CollectionMemberContext;
|
|
@@ -771,9 +773,8 @@ export declare class QueryByNameContext extends RefinableQueryContext {
|
|
|
771
773
|
}
|
|
772
774
|
export declare class QueryByTurtleNameContext extends RefinableQueryContext {
|
|
773
775
|
unextendableSource(): UnextendableSourceContext;
|
|
776
|
+
ARROW(): TerminalNode;
|
|
774
777
|
id(): IdContext;
|
|
775
|
-
ARROW(): TerminalNode | undefined;
|
|
776
|
-
DOT(): TerminalNode | undefined;
|
|
777
778
|
constructor(ctx: RefinableQueryContext);
|
|
778
779
|
enterRule(listener: MalloyParserListener): void;
|
|
779
780
|
exitRule(listener: MalloyParserListener): void;
|
|
@@ -2279,6 +2280,22 @@ export declare class CollectionWildCardContext extends ParserRuleContext {
|
|
|
2279
2280
|
STAR(): TerminalNode;
|
|
2280
2281
|
fieldPath(): FieldPathContext | undefined;
|
|
2281
2282
|
DOT(): TerminalNode | undefined;
|
|
2283
|
+
starQualified(): StarQualifiedContext | undefined;
|
|
2284
|
+
constructor(parent: ParserRuleContext | undefined, invokingState: number);
|
|
2285
|
+
get ruleIndex(): number;
|
|
2286
|
+
enterRule(listener: MalloyParserListener): void;
|
|
2287
|
+
exitRule(listener: MalloyParserListener): void;
|
|
2288
|
+
accept<Result>(visitor: MalloyParserVisitor<Result>): Result;
|
|
2289
|
+
}
|
|
2290
|
+
export declare class StarQualifiedContext extends ParserRuleContext {
|
|
2291
|
+
OCURLY(): TerminalNode;
|
|
2292
|
+
CCURLY(): TerminalNode;
|
|
2293
|
+
COMMA(): TerminalNode[];
|
|
2294
|
+
COMMA(i: number): TerminalNode;
|
|
2295
|
+
EXCEPT(): TerminalNode[];
|
|
2296
|
+
EXCEPT(i: number): TerminalNode;
|
|
2297
|
+
fieldNameList(): FieldNameListContext[];
|
|
2298
|
+
fieldNameList(i: number): FieldNameListContext;
|
|
2282
2299
|
constructor(parent: ParserRuleContext | undefined, invokingState: number);
|
|
2283
2300
|
get ruleIndex(): number;
|
|
2284
2301
|
enterRule(listener: MalloyParserListener): void;
|