Skip to content

Commit 8d68a42

Browse files
authored
feat: intermediate type computer (#600)
Closes partially #541. ### Summary of Changes Port almost the entire functionality of the Xtext type computer to Langium. Only the following tasks are still missing for feature parity, but they require work in other areas of the language first: * Elvis operator with nullable left side (**needs type checker**) * Parameters of block lambdas passed as arguments (**needs scoping**) * Parameters of expression lambdas passed as arguments (**needs scoping**)
1 parent 6ae387a commit 8d68a42

File tree

106 files changed

+1924
-913
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

106 files changed

+1924
-913
lines changed

src/language/formatting/safe-ds-formatter.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -313,7 +313,7 @@ export class SafeDsFormatter extends AbstractFormatter {
313313
const formatter = this.getNodeFormatter(node);
314314

315315
if (annotationCallsOrEmpty(node).length > 0) {
316-
if (node.static) {
316+
if (node.isStatic) {
317317
formatter.keyword('static').prepend(newLine());
318318
} else {
319319
formatter.keyword('attr').prepend(newLine());
@@ -421,7 +421,7 @@ export class SafeDsFormatter extends AbstractFormatter {
421421
const formatter = this.getNodeFormatter(node);
422422

423423
if (annotationCallsOrEmpty(node).length > 0) {
424-
if (node.static) {
424+
if (node.isStatic) {
425425
formatter.keyword('static').prepend(newLine());
426426
} else {
427427
formatter.keyword('fun').prepend(newLine());
@@ -550,7 +550,7 @@ export class SafeDsFormatter extends AbstractFormatter {
550550
const formatter = this.getNodeFormatter(node);
551551

552552
if (annotationCallsOrEmpty(node).length === 0) {
553-
if (node.variadic) {
553+
if (node.isVariadic) {
554554
formatter.property('name').prepend(oneSpace());
555555
}
556556
} else {

0 commit comments

Comments
 (0)