You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
From my point of view, the types of the $container properties could be more precise, i.e. only Student for OneValue and only Teacher for TwoValues.
The current $container types are not wrong, but as a user of Langium, I would expect the following types, since the grammar clearly shows, that these types are enough:
The following simple and artificial example uses guard conditions in order to switch between different cases (excerpt):
(The whole grammar with an instance can be found in the playground.)
For this grammar, Langium generates the following types in the
ast.ts
(excerpt):From my point of view, the types of the
$container
properties could be more precise, i.e. onlyStudent
forOneValue
and onlyTeacher
forTwoValues
.The current
$container
types are not wrong, but as a user of Langium, I would expect the following types, since the grammar clearly shows, that these types are enough:The text was updated successfully, but these errors were encountered: