Skip to content
Discussion options

You must be logged in to vote

Hey @cdietrich,

Likely a bug somewhere in the type inference. I believe as a workaround, StructTypeDefinition and SimpleTypeDefinition could be interfaces that add visibility?: ... and props: MetadataPropertyAssignment[]. AFAIK that should work as expected:

ModelContent: (('@metadata' '{' (props+=MetadataPropertyAssignment)* '}')? (
    {StructTypeDefinition} StructTypeDefinitionRule | ...;

interface StructTypeDefinition {
    visibility?: 'private' | 'internal' | 'public';
    props?: MetadataPropertyAssignment[];
    name: string;
    baseType?: string;
    content: StructTypeMember[];
}

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by cdietrich
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants